WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=585a56abfd2a74fff867060a701ae99c38d39bb9

commit 585a56abfd2a74fff867060a701ae99c38d39bb9
Author: thomasg <tho...@gstaedtner.net>
Date:   Fri May 22 09:20:02 2020 -0700

    Wiki page hello-world-gui.md changed with summary [adapt to API changes 
(lots of API changes...)] by thomasg
---
 pages/develop/tutorials/c/hello-world-gui.md.txt | 50 ++++++++++++------------
 1 file changed, 25 insertions(+), 25 deletions(-)

diff --git a/pages/develop/tutorials/c/hello-world-gui.md.txt 
b/pages/develop/tutorials/c/hello-world-gui.md.txt
index 5f3ee7c74..dd6c89bf9 100644
--- a/pages/develop/tutorials/c/hello-world-gui.md.txt
+++ b/pages/develop/tutorials/c/hello-world-gui.md.txt
@@ -191,11 +191,11 @@ Next create the box object and add it to the window:
 [...]
    box = efl_add(EFL_UI_BOX_CLASS, win,
          efl_content_set(win, efl_added),
-         efl_gfx_size_hint_min_set(efl_added, EINA_SIZE2D(360, 240)));
+         efl_gfx_hint_size_min_set(efl_added, EINA_SIZE2D(360, 240)));
 [...]
 ```
 
-As with the ``EFL_UI_WIN_CLASS`` you saw in the ``win`` creation block, 
[``EFL_UI_BOX_CLASS``](macros.md##Box) is a macro which establishes that this 
object will be a box object. The next parameter tells your application what 
object the box has to go into : in this case inside the ``win`` window you 
created earlier. The ``efl_content_set()`` function activates the text box 
within the window. Until you call this function the box will not be visible. 
The ``efl_gfx_size_hint_min_set()`` fun [...]
+As with the ``EFL_UI_WIN_CLASS`` you saw in the ``win`` creation block, 
[``EFL_UI_BOX_CLASS``](macros.md##Box) is a macro which establishes that this 
object will be a box object. The next parameter tells your application what 
object the box has to go into : in this case inside the ``win`` window you 
created earlier. The ``efl_content_set()`` function activates the text box 
within the window. Until you call this function the box will not be visible. 
The ``efl_gfx_hint_size_min_set()`` fun [...]
 
 Your program should now look like this:
 
@@ -226,7 +226,7 @@ _gui_setup()
 
    box = efl_add(EFL_UI_BOX_CLASS, win,
          efl_content_set(win, efl_added),
-         efl_gfx_size_hint_min_set(efl_added, EINA_SIZE2D(360, 240)));
+         efl_gfx_hint_size_min_set(efl_added, EINA_SIZE2D(360, 240)));
 }
 
 EAPI_MAIN void
@@ -245,11 +245,11 @@ If you compile and run this program you should see 
something like what's shown b
 
 The next step is to add the text box and button widgets. 
 
-You can add a text box widget using the ``EFL_UI_TEXT_CLASS`` and insert into 
your ``box`` object. Insert the following code in your ``_gui_setup()`` 
function:
+You can add a text box widget using the ``EFL_UI_TEXTBOX_CLASS`` and insert 
into your ``box`` object. Insert the following code in your ``_gui_setup()`` 
function:
 
 ```c
 [...]
-  efl_add(EFL_UI_TEXT_CLASS, box,
+  efl_add(EFL_UI_TEXTBOX_CLASS, box,
            efl_text_markup_set(efl_added, "Hello World. This is an 
<b>Efl.Ui</b> application!"),
            efl_text_interactive_selection_allowed_set(efl_added, EINA_FALSE),
            efl_pack(box, efl_added));
@@ -265,12 +265,12 @@ To add a button use the following code:
    efl_add(EFL_UI_BUTTON_CLASS, box,
            efl_text_set(efl_added, "Quit"),
            efl_pack(box, efl_added),
-           efl_event_callback_add(efl_added, EFL_UI_EVENT_CLICKED,
+           efl_event_callback_add(efl_added, EFL_INPUT_EVENT_CLICKED,
                                   _gui_quit_cb, efl_added));
 [...]
 ```
 
-The ``efl_text_set()`` adds a *Quit* label to the button and 
``efl_event_callback_add()`` defines what event will trigger the button, in 
this case, being clicked (``EFL_UI_EVENT_CLICKED``). You'll also define what to 
do if the event is indeed triggered. Here, the program quits by calling the 
``_gui_quit_cb()`` callback function you defined earlier.
+The ``efl_text_set()`` adds a *Quit* label to the button and 
``efl_event_callback_add()`` defines what event will trigger the button, in 
this case, being clicked (``EFL_INPUT_EVENT_CLICKED``). You'll also define what 
to do if the event is indeed triggered. Here, the program quits by calling the 
``_gui_quit_cb()`` callback function you defined earlier.
 
 Notice how you're using ``efl_pack()`` once again to define how much space the 
button will take up. Without including any more information EFL shares the 
available space equally between all widgets. This means that if you compile and 
run the program you should see something like this:
 
@@ -282,32 +282,32 @@ As you can see the text box takes up one half of the 
space and button takes up t
 
 The layout of your window is slightly skewed. In this section you'll learn how 
to change the space assigned by default to each widget to make your app look 
better. You'll also discover how to change the alignment of the text in the 
text box.
 
-To change how much relative space each widget takes up, you use *weight 
hinting*: in other words you can assign a how much proportional space each 
widget should take up relative to each other and the overall space available in 
the container. For example you can add an ``efl_gfx_size_hint_weight_set()`` 
function to your text box and button like so:
+To change how much relative space each widget takes up, you use *weight 
hinting*: in other words you can assign a how much proportional space each 
widget should take up relative to each other and the overall space available in 
the container. For example you can add an ``efl_gfx_hint_weight_set()`` 
function to your text box and button like so:
 
 ```c
 [...]
-   efl_add(EFL_UI_TEXT_CLASS, box,
+   efl_add(EFL_UI_TEXTBOX_CLASS, box,
            efl_text_markup_set(efl_added, "Hello World.<br>This is an 
<b>Efl.Ui</b> application!"),
            efl_text_interactive_selection_allowed_set(efl_added, EINA_FALSE),
-           efl_gfx_size_hint_weight_set(efl_added, 1.0, 1.0),
+           efl_gfx_hint_weight_set(efl_added, 1.0, 1.0),
            efl_pack(box, efl_added));
 
    efl_add(EFL_UI_BUTTON_CLASS, box,
            efl_text_set(efl_added, "Quit"),
-           efl_gfx_size_hint_weight_set(efl_added, 1.0, 1.0),
+           efl_gfx_hint_weight_set(efl_added, 1.0, 1.0),
            efl_pack(box, efl_added),
-           efl_event_callback_add(efl_added, EFL_UI_EVENT_CLICKED,
+           efl_event_callback_add(efl_added, EFL_INPUT_EVENT_CLICKED,
                                   _gui_quit_cb, efl_added));
 [...]
 ```
 
 The ``1.0, 1.0`` parameters in both the functions tell Enlightenment to assign 
the maximum available space on the horizontal and vertical axis. This means 
they each get 50% of the space and the window looks like what you see above.
 
-However if you change ``efl_gfx_size_hint_weight_set()`` for the text box to:
+However if you change ``efl_gfx_hint_weight_set()`` for the text box to:
 
 ```c
 [...]
-           efl_gfx_size_hint_weight_set(efl_added, 1.0, 0.9),
+           efl_gfx_hint_weight_set(efl_added, 1.0, 0.9),
 [...]
 ```
 
@@ -315,7 +315,7 @@ then change the function for the button to:
 
 ```c
 [...]
-           efl_gfx_size_hint_weight_set(efl_added, 1.0, 0.1),
+           efl_gfx_hint_weight_set(efl_added, 1.0, 0.1),
 [...]
 ```
 
@@ -323,11 +323,11 @@ Enlightenment assigns approximately 90% of the vertical 
space to the text box an
 
 Changing horizontal weights will not change the look of the widgets. As there 
are no two widgets in your application along the same horizontal axis, both 
will expand to the maximum available space regardless of the values you assign 
them.
 
-To change the alignment of the text in the text box use an 
``efl_gfx_size_hint_align_set()`` function with it. For example:
+To change the alignment of the text in the text box use an 
``efl_gfx_hint_align_set()`` function with it. For example:
 
 ```c
 [...]
-    efl_gfx_size_hint_align_set(efl_added, 0.0, 1.0),
+    efl_gfx_hint_align_set(efl_added, 0.0, 1.0),
 [...]
 ```
 
@@ -337,7 +337,7 @@ Changing the parameters to the following aligns the text to 
the right as you can
 
 ```c
 [...]
-    efl_gfx_size_hint_align_set(efl_added, 1.0, 0.0),
+    efl_gfx_hint_align_set(efl_added, 1.0, 0.0),
 [...]
 ```
 
@@ -374,20 +374,20 @@ _gui_setup()
 
    box = efl_add(EFL_UI_BOX_CLASS, win,
                 efl_content_set(win, efl_added),
-                efl_gfx_size_hint_min_set(efl_added, EINA_SIZE2D(360, 240)));
+                efl_gfx_hint_size_min_set(efl_added, EINA_SIZE2D(360, 240)));
 
-   efl_add(EFL_UI_TEXT_CLASS, box,
+   efl_add(EFL_UI_TEXTBOX_CLASS, box,
            efl_text_markup_set(efl_added, "Hello World. This is an 
<b>Efl.Ui</b> application!"),
            efl_text_interactive_selection_allowed_set(efl_added, EINA_FALSE),
-           efl_gfx_size_hint_weight_set(efl_added, 1.0, 0.9),
-           efl_gfx_size_hint_align_set(efl_added, 0.5, 0.5),
+           efl_gfx_hint_weight_set(efl_added, 1.0, 0.9),
+           efl_gfx_hint_align_set(efl_added, 0.5, 0.5),
            efl_pack(box, efl_added));
 
    efl_add(EFL_UI_BUTTON_CLASS, box,
            efl_text_set(efl_added, "Quit"),
-           efl_gfx_size_hint_weight_set(efl_added, 1.0, 0.1),
+           efl_gfx_hint_weight_set(efl_added, 1.0, 0.1),
            efl_pack(box, efl_added),
-           efl_event_callback_add(efl_added, EFL_UI_EVENT_CLICKED,
+           efl_event_callback_add(efl_added, EFL_INPUT_EVENT_CLICKED,
                                   _gui_quit_cb, efl_added));
 }
 
@@ -425,7 +425,7 @@ Try adding more widgets such as an *About* button to your 
program. Experiment wi
 In this tutorial you have learned:
 
 * How to create a graphical window with ``efl_add()`` and ``EFL_UI_WIN_CLASS``.
-* How to add and position widgets in a window with ``efl_add()``, 
``efl_gfx_size_hint_align_set()`` and ``efl_gfx_size_hint_weight_set()``.
+* How to add and position widgets in a window with ``efl_add()``, 
``efl_gfx_hint_align_set()`` and ``efl_gfx_hint_weight_set()``.
 * How to exit an application that uses windows cleanly with ``efl_quit()``.
 
 ## Troubleshooting ##

-- 


Reply via email to