summaryrefslogtreecommitdiff
path: root/pages
diff options
context:
space:
mode:
authorXavi Artigas <xavierartigas@yahoo.es>2018-08-29 01:28:11 -0700
committerapache <apache@e5-web1.enlightenment.org>2018-08-29 01:28:11 -0700
commite6e87277c6538fc3f2c0a429a579894e48675130 (patch)
treef04d0466b891f438b16a217b7b49ac435df5d5bb /pages
parent8a98b1ec1765efd25e56faed3061bcc3c9e147f8 (diff)
Wiki page hello-world-gui-cs.md changed with summary [Corrected text alignment explanation] by Xavi Artigas
Diffstat (limited to 'pages')
-rw-r--r--pages/develop/tutorials/csharp/hello-world-gui-cs.md.txt7
1 files changed, 4 insertions, 3 deletions
diff --git a/pages/develop/tutorials/csharp/hello-world-gui-cs.md.txt b/pages/develop/tutorials/csharp/hello-world-gui-cs.md.txt
index 65214df47..6fe9e837a 100644
--- a/pages/develop/tutorials/csharp/hello-world-gui-cs.md.txt
+++ b/pages/develop/tutorials/csharp/hello-world-gui-cs.md.txt
@@ -196,14 +196,15 @@ This instantiates an `efl.ui.Text` object, as a child of the box container. Quit
196 196
197* `SetText()`: Specifies the text string to display in the widget. 197* `SetText()`: Specifies the text string to display in the widget.
198* `SetSelectionAllowed()`: This disables selecting the text (by dragging over it with the mouse, for example). Just to showcase a bit the EFL's capabilities. 198* `SetSelectionAllowed()`: This disables selecting the text (by dragging over it with the mouse, for example). Just to showcase a bit the EFL's capabilities.
199* `SetHintWeight()`: This one controls the widget's size, but, instead of setting it explicitly as `SetHintMin()` did, it does so indirectly by giving the widget a **weight**. The container holding this widget decides the size for all its held widgets according to their relative weights (If all widgets have the same weight, they all have the same size. If you double the weight of one of the widgets, its size will be double that of the other widgets). This is a complex topic explained in its own tutorial (coming soon). 199* `SetHintWeight()`: This one controls the widget's size, but, instead of setting it explicitly as `SetHintMin()` did, it does so indirectly by giving the widget a **weight**. The container holding this widget decides the size for all its held widgets according to their relative weights (If all widgets have the same weight, they all have the same size. If you double the weight of one of the widgets, its size will be double that of the other widgets). This is a complex topic explained in its own tutorial (*coming soon*).
200 200
201 In the code above, the text widget is given a weight of `1.0` in the horizontal direction and `0.9` in the vertical direction (both directions are treated separately). The effect of this on the final widget size depends on the other widgets' weights, so it is explained in the next section. 201 In the code above, the text widget is given a weight of `1.0` in the horizontal direction and `0.9` in the vertical direction (both directions are treated separately). The effect of this on the final widget size depends on the other widgets' weights, so it is explained in the next section.
202 202
203* `SetHintAlign()`: Once the container has allocated space for each widget according to its weight, if the actual widget is smaller, it has room to be aligned. This command controls horizontal and vertical alignment in this way: `0` means left (or top), `1` means right (or bottom), and intermediate values are possible, meaning intermediate positions. For example, `0.5` means centered, as used in the code. 203* `SetHintAlign()`: Once the container has allocated space for each widget according to its weight, if the actual widget is smaller, it has room to be aligned. This command controls horizontal and vertical alignment in this way: `0` means left (or top), `1` means right (or bottom), and intermediate values are possible, meaning intermediate positions. For example, `0.5` means centered, as used in the code.
204 204
205 > **NOTE**: 205 > **NOTE**: A vertical box fixes the vertical size of all its contained widgets (and likewise an horizontal box). This means that they cannot be vertically aligned using `SetHintAlign()` (only horizontally), because there is no room for movement in the vertical direction.
206 > There is currently an issue in EFL preventing correct vertical alignment of widgets inside vertical boxes (and horizontal alignment inside horizontal boxes). You can follow the resolution progress in ticket [T7352](https://phab.enlightenment.org/T7352). 206 >
207 > If you want to vertically align the text inside a vertical box, you have to align the text **inside** the text widget using `SetValign(0.5)` (or `SetHalign(0.5)`). This is a complex topic explained in it own tutorial (*coming soon*).
207 208
208* `Efl.ui.Box.DoPack()`: This adds the text widget to the box container. The order in which widgets are added to a container dictates the order in which they are placed on the screen. 209* `Efl.ui.Box.DoPack()`: This adds the text widget to the box container. The order in which widgets are added to a container dictates the order in which they are placed on the screen.
209 210