summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVitor Sousa <vitorsousasilva@gmail.com>2016-02-15 13:04:48 -0200
committerFelipe Magno de Almeida <felipe@expertisesolutions.com.br>2016-02-22 10:38:26 -0300
commit91944e192a9d02c0b8bd7ddf0c815d3ed6778901 (patch)
tree08590051b365faacc80feca7142637dec9e13d0f
parent2df608aca31cc415150726249810a4a7633ad73d (diff)
elm widget: add documentation from elm_focus.h to elm_widget.eo
-rw-r--r--src/lib/elm_widget.eo85
1 files changed, 73 insertions, 12 deletions
diff --git a/src/lib/elm_widget.eo b/src/lib/elm_widget.eo
index 69a70baa8..ce12a4aed 100644
--- a/src/lib/elm_widget.eo
+++ b/src/lib/elm_widget.eo
@@ -6,9 +6,23 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
6 data: Elm_Widget_Smart_Data; 6 data: Elm_Widget_Smart_Data;
7 methods { 7 methods {
8 @property focus { 8 @property focus {
9 [[Whether an Elementary object has the focus or not.
10
11 Note that when you set focus to this object, if it can handle focus,
12 it will take the focus away from the one who had it previously and will,
13 for now on, be the one receiving input events. Unsetting focus will remove
14 the focus from this object, passing it back to the previous element in the
15 focus chain list.
16
17 Warning: Only visible object can get a focus. Call @Evas.Object_Smart.show
18 before calling this API, if you want to give a focus to the evas object.]]
9 set { 19 set {
20 [[$true set the focus to the object,
21 $false unset the focus to the object.]]
10 } 22 }
11 get { 23 get {
24 [[Return $true if the object is focused,
25 and $false if not (and on errors).]]
12 } 26 }
13 values { 27 values {
14 focus: bool; 28 focus: bool;
@@ -26,21 +40,30 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
26 @property focus_highlight_style { 40 @property focus_highlight_style {
27 [[Control the widget focus highlight style.]] 41 [[Control the widget focus highlight style.]]
28 set { 42 set {
29 return: bool; 43 return: bool; [[$true on success, $false otherwise.]]
30 } 44 }
31 get { 45 get {
32 } 46 }
33 values { 47 values {
34 style: const(char)*; 48 style: const(char)*; [[The name of the focus highlight style.]]
35 } 49 }
36 } 50 }
37 @property tree_unfocusable { 51 @property tree_unfocusable {
52 [[Make the elementary object and its children to be unfocusable (or focusable).
53 If the tree is set as unfocusable, newest focused object which is not in
54 this tree will get focus.
55 This API can be helpful for an object to be deleted.
56 When an object will be deleted soon, it and its children may not want to
57 get focus (by focus reverting or by other focus controls).
58 Then, just use this API before deleting.]]
38 set { 59 set {
39 } 60 }
40 get { 61 get {
62 [[Return $true, if the tree is unfocusable,
63 $false otherwise (and on errors).]]
41 } 64 }
42 values { 65 values {
43 tree_unfocusable: bool; 66 tree_unfocusable: bool; [[$true for unfocusable, $false for focusable.]]
44 } 67 }
45 } 68 }
46 @property mirrored { 69 @property mirrored {
@@ -119,24 +142,44 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
119 } 142 }
120 } 143 }
121 @property focus_custom_chain { 144 @property focus_custom_chain {
145 [[A custom chain of objects to pass focus.
146
147 Note: On focus cycle, only will be evaluated children of this container.]]
122 set { 148 set {
149 [[This function overwrites any previous custom focus chain within
150 the list of objects. The previous list will be deleted and this list
151 will be managed by elementary. After it is set, don't modify it.]]
123 values { 152 values {
124 objs: list<Evas.Object*>*; 153 objs: list<Evas.Object*>*; [[Chain of objects to pass focus]]
125 } 154 }
126 } 155 }
127 get { 156 get {
128 values { 157 values {
129 objs: const(list<Evas.Object*>)*; 158 objs: const(list<Evas.Object*>)*; [[Chain of objects]]
130 } 159 }
131 } 160 }
132 } 161 }
133 @property can_focus { 162 @property can_focus {
163 [[The ability for an Elementary object to be focused.
164
165 Unfocusable objects do nothing when programmatically
166 focused, being the nearest focusable parent object the one
167 really getting focus. Also, when they receive mouse input, they
168 will get the event, but not take away the focus from where it
169 was previously.
170
171 Note: Objects which are meant to be interacted with by input
172 events are created able to be focused, by default. All the
173 others are not.]]
134 set { 174 set {
135 } 175 }
136 get { 176 get {
177 [[Return $true if the object is allowed to be focused,
178 $false if not (and on errors).]]
137 } 179 }
138 values { 180 values {
139 can_focus: bool; 181 can_focus: bool; [[$true if the object can be focused,
182 $false if not.]]
140 } 183 }
141 } 184 }
142 @property highlight_in_theme { 185 @property highlight_in_theme {
@@ -362,8 +405,9 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
362 } 405 }
363 } 406 }
364 @property focused_object { 407 @property focused_object {
408 [[Current focused object in object tree.]]
365 get { 409 get {
366 return: Evas.Object *; 410 return: Evas.Object *; [[Current focused or $null, if there is no focused object.]]
367 } 411 }
368 } 412 }
369 @property parent2 { 413 @property parent2 {
@@ -440,9 +484,15 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
440 focus_tree_unfocusable_handle { 484 focus_tree_unfocusable_handle {
441 } 485 }
442 focus_custom_chain_prepend { 486 focus_custom_chain_prepend {
487 [[Prepend object to custom focus chain.
488
489 Note: If @"relative_child" equal to $null or not in custom chain,
490 the object will be added in begin.
491
492 Note: On focus cycle, only will be evaluated children of this container.]]
443 params { 493 params {
444 @in child: Evas.Object *; 494 @in child: Evas.Object *; [[The child to be added in custom chain.]]
445 @in relative_child: Evas.Object * @optional; 495 @in relative_child: Evas.Object * @optional; [[The relative object to position the child.]]
446 } 496 }
447 } 497 }
448 part_text_translate { 498 part_text_translate {
@@ -533,8 +583,10 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
533 return: bool; 583 return: bool;
534 } 584 }
535 focus_cycle { 585 focus_cycle {
586 [[Give focus to next object with specific focus direction in
587 object tree.]]
536 params { 588 params {
537 @in dir: Elm.Focus_Direction; 589 @in dir: Elm.Focus_Direction; [[Direction to move the focus.]]
538 } 590 }
539 } 591 }
540 focus_direction { 592 focus_direction {
@@ -650,6 +702,9 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
650 scroll_freeze_push { 702 scroll_freeze_push {
651 } 703 }
652 focus_custom_chain_unset { 704 focus_custom_chain_unset {
705 [[Unset a custom focus chain on a given Elementary widget.
706
707 Any focus chain previously set is removed entirely after this call.]]
653 } 708 }
654 focus_steal { 709 focus_steal {
655 params { 710 params {
@@ -729,9 +784,15 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte
729 focus_disabled_handle { 784 focus_disabled_handle {
730 } 785 }
731 focus_custom_chain_append { 786 focus_custom_chain_append {
787 [[Append object to custom focus chain.
788
789 Note: If @"relative_child" equal to $null or not in custom chain,
790 the object will be added in end.
791
792 Note: On focus cycle, only will be evaluated children of this container.]]
732 params { 793 params {
733 @in child: Evas.Object *; 794 @in child: Evas.Object *; [[The child to be added in custom chain.]]
734 @in relative_child: Evas.Object * @optional; 795 @in relative_child: Evas.Object * @optional; [[The relative object to position the child.]]
735 } 796 }
736 } 797 }
737 @property focus_move_policy { 798 @property focus_move_policy {