You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: documentation/piu/piu.md
+12-10Lines changed: 12 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -70,11 +70,6 @@ The graphical user interface elements of Piu applications are composed of a hier
70
70
71
71
Applications use constructors to define `content` and `container` objects. These objects are attached to the containment hierarchy using the `add`, `insert`, and `replace` functions, and are removed from the containment hierarchy using the `remove` and `replace` functions. See [Functions](#container-functions) in the section [Container Object](#container-object) for descriptions of these properties.
72
72
73
-
<!--
74
-
TO DO:
75
-
For more information about how `content` and `container` objects are used in applications, see the [Piu Containment Hierarchy document][29].
76
-
-->
77
-
78
73
#### Bound and Unbound Contents
79
74
80
75
Contents that are not attached to the containment hierarchy are called *unbound* contents; contents attached to the containment hierarchy, *bound* contents. Only objects that are part of the containment hierarchy appear on screen.
| `style` | `style` | The style to use to draw the string
2818
2813
| `x, y, width, height` | `number` | The local position and size of the area in which to draw, in pixels
2819
-
| `ellipsis` | `boolean` | [TO DO: figure out what this does]
2814
+
| `ellipsis` | `boolean` | If `true`, the string is truncated to fit the specified bounds. If `false`, the entire string is drawn, even if it extends beyond the specified bounds.
2820
2815
| `state` | `number` | The state of the style to draw. If the specified style has multiple fill colors, setting the state selects which color to use.
2821
2816
2822
2817
Draws a string with the style, position, and state speciied.
@@ -2834,8 +2829,8 @@ let samplePort = new Port(null, {
| `bottom` | `number` | This style's bottom margin, in pixels (setting the `bottom` property of the created instance, and `bottom` in the created instance's `margins` property)
3586
-
| `indentation` | `number` | This style's indentation--the indentation of the first line of a block, in pixels
3587
3581
| `leading` | `number` | This style's line height, or "leading"--the distance between lines of a block, in pixels. If 0 or unspecified, it is automatically calculated. Use a negative value to force a distance even if lines overlap.
3588
3582
| `left` | `number` | This style's left margin, in pixels (setting the `left` property of the created instance, and `left` in the created instance's `margins` property)
3589
3583
| `right` | `number` | This style's right margin, in pixels (setting the `right` property of the created instance, and `right` in the created instance's `margins` property)
3590
3584
3585
+
<!-- TO DO:
3586
+
| `indentation` | `number` | This style's indentation--the indentation of the first line of a block, in pixels
3587
+
-->
3588
+
3591
3589
##### Label styles only
3592
3590
3593
3591
| Parameter | Type | Description |
@@ -3617,7 +3615,6 @@ All properties of a `style` object are read-only, but you can change the style o
3617
3615
| `color` | `object` | `undefined` | This style's color(s), as an array of strings, or `undefined` if no color has been specified. The `state` property of the `content` object using the style determines the index of the array; if `state` is not an integer, colors from surrounding states are blended.
3618
3616
| `family` | `string` | | This style's font family
3619
3617
| `horizontal` | `string` | | This style's horizontal alignment, as `left`, `center` (the default), `right`, or `justify`
3620
-
| `indentation` | `number` | | This style's indentation--the indentation of the first line of a block, in pixels **TO DO: test this**
3621
3618
| `leading` | `number` | | This style's line height (or "leading")--the distance between lines of a block, in pixels. If `0` or unspecified, it is automatically calculated
3622
3619
| `left` | `number` | 0 | The left margin of this style
3623
3620
| `margins` | `object` | | This style's margins, as an object with `left`, `right`, `top`, and `bottom` number properties, specified in pixels
@@ -3628,6 +3625,11 @@ All properties of a `style` object are read-only, but you can change the style o
3628
3625
| `vertical` | `string` | | This style's vertical alignment, as `top`, `middle` (the default), or `bottom`, specified in pixels
3629
3626
| `weight` | `number` | | The weight of this style's font
3630
3627
3628
+
3629
+
<!-- TO DO:
3630
+
| `indentation` | `number` | | This style's indentation--the indentation of the first line of a block, in pixels
0 commit comments