summaryrefslogtreecommitdiff
path: root/src/lib/elementary/elm_widget.eo
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-10-12 18:16:42 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-10-12 19:33:04 +0900
commit72f1fbf4f1eddbc1cde4455081be4f3a9b8a1a44 (patch)
tree18778ad57844976c59a6c5576eb82eb003be6aab /src/lib/elementary/elm_widget.eo
parent19dff855194f2c4b411fc5d27b33d212ff26bcb0 (diff)
widget: Rename focus_region (EO)
This region has little to do with focus, as it's more of a region of interest within the widget, and not directly related to the highlight geometry, for instance. It's related to focus in the sense that only widgets with focus would really care about this region. I decided to change this name after talking with @bu5hm4n. Note that gengrid uses this but is also completely broken (the focus highlight floats around and you don't even see the focused item). Note: This is very close to show_region but I'm not sure those can be merged safely (since the default "focus_region" is NULL while the default "show_region" is the widget's geometry). Ref T5363
Diffstat (limited to 'src/lib/elementary/elm_widget.eo')
-rw-r--r--src/lib/elementary/elm_widget.eo39
1 files changed, 23 insertions, 16 deletions
diff --git a/src/lib/elementary/elm_widget.eo b/src/lib/elementary/elm_widget.eo
index a50b40af05..17f76d84b4 100644
--- a/src/lib/elementary/elm_widget.eo
+++ b/src/lib/elementary/elm_widget.eo
@@ -395,14 +395,14 @@ abstract Elm.Widget (Efl.Canvas.Group, Elm.Interface.Atspi_Accessible,
395 unchanged. 395 unchanged.
396 ]] 396 ]]
397 values { 397 values {
398 region: Eina.Rect; [[The region of interest.]] 398 region: Eina.Rect; [[The region to show.]]
399 force: bool; [[Set to $true to force show even if unchanged.]] 399 force: bool; [[Set to $true to force show even if unchanged.]]
400 } 400 }
401 } 401 }
402 get { 402 get {
403 [[Returns the current region of interest.]] 403 [[Returns the current region to show.]]
404 values { 404 values {
405 region: Eina.Rect; [[The region of interest.]] 405 region: Eina.Rect; [[The region to show.]]
406 } 406 }
407 } 407 }
408 } 408 }
@@ -422,10 +422,10 @@ abstract Elm.Widget (Efl.Canvas.Group, Elm.Interface.Atspi_Accessible,
422 [[Pop scroller freeze]] 422 [[Pop scroller freeze]]
423 } 423 }
424 424
425 /* FIXME: This is not 100% related to focus. This documentation needs 425 /* Region of interest */
426 * further fixing. */ 426 @property interest_region @protected {
427 @property focus_region @protected { 427 [[Region of interest inside this widget, that should be given
428 [[Region to show when focus changes within this widget. 428 priority to be visible inside a scroller.
429 429
430 When this widget or one of its subwidgets is given focus, this 430 When this widget or one of its subwidgets is given focus, this
431 region should be shown, which means any parent scroller should 431 region should be shown, which means any parent scroller should
@@ -439,9 +439,10 @@ abstract Elm.Widget (Efl.Canvas.Group, Elm.Interface.Atspi_Accessible,
439 widget. W,H must be greater or equal to 1 for this region to be 439 widget. W,H must be greater or equal to 1 for this region to be
440 taken into account, otherwise it is ignored. 440 taken into account, otherwise it is ignored.
441 441
442 See also @.focus_region_show. 442 See also @.interest_region_mode
443 ]] 443 ]]
444 get { 444 get {
445 legacy: elm_widget_focus_region_get;
445 } 446 }
446 values { 447 values {
447 region: Eina.Rect; 448 region: Eina.Rect;
@@ -449,19 +450,25 @@ abstract Elm.Widget (Efl.Canvas.Group, Elm.Interface.Atspi_Accessible,
449 will be ignored, and no action will be taken.]] 450 will be ignored, and no action will be taken.]]
450 } 451 }
451 } 452 }
452 focus_region_show @protected { 453 @property interest_region_mode {
453 [[Show the region of interest inside this widget. 454 [[Defines how @.show_region should be calculated.
454 455
455 See also @.focus_region. 456 It is up to the implementation of @.show_region.get to take this
457 value into account (or ignore it).
456 ]] 458 ]]
457 } 459 get {
458 @property focus_region_show_mode { 460 legacy: elm_widget_focus_region_show_mode_get;
459 [[Control the focus_region_show mode.]] 461 }
462 set {
463 legacy: elm_widget_focus_region_show_mode_set;
464 }
460 values { 465 values {
461 /* FIXME: This enum is in Elm namespace! */ 466 mode: Efl.Ui.Interest_Region_Mode;
462 mode: Elm.Focus.Region.Show_Mode; [[Focus region show mode]] 467 [[Whether to show a specific item or the widget as a whole.]]
463 } 468 }
464 } 469 }
470
471 /* Focus highlight (visual focus rectangle) properties */
465 @property focus_highlight_geometry @protected { 472 @property focus_highlight_geometry @protected {
466 [[The rectangle region to be highlighted on focus. 473 [[The rectangle region to be highlighted on focus.
467 474