diff --git a/tests/a11y/accessibility-dump.c b/tests/a11y/accessibility-dump.c index be0950b0b5..457b46173d 100644 --- a/tests/a11y/accessibility-dump.c +++ b/tests/a11y/accessibility-dump.c @@ -264,6 +264,36 @@ dump_text_attributes (GString *string, atk_attribute_set_free (attributes); } +extern GType atk_layer_get_type (void); + +static const gchar * +layer_name (AtkLayer layer) +{ + GEnumClass *class; + GEnumValue *value; + + class = g_type_class_ref (atk_layer_get_type ()); + value = g_enum_get_value (class, layer); + g_type_class_unref (class); + + return value->value_nick; +} + +static void +dump_atk_component (AtkComponent *atk_component, + guint depth, + GString *string) +{ + AtkLayer layer; + + g_string_append_printf (string, "%*s\n", depth, ""); + + layer = atk_component_get_layer (atk_component); + g_string_append_printf (string, "%*slayer: %s\n", depth, "", layer_name (layer)); + + g_string_append_printf (string, "%*salpha: %g\n", depth, "", atk_component_get_alpha (atk_component)); +} + static void dump_atk_text (AtkText *atk_text, guint depth, @@ -435,6 +465,9 @@ dump_accessible (AtkObject *accessible, dump_state_set (string, depth, atk_object_ref_state_set (accessible)); dump_attribute_set (string, depth, atk_object_get_attributes (accessible)); + if (ATK_IS_COMPONENT (accessible)) + dump_atk_component (ATK_COMPONENT (accessible), depth, string); + if (ATK_IS_TEXT (accessible)) dump_atk_text (ATK_TEXT (accessible), depth, string); diff --git a/tests/a11y/accessible-name.txt b/tests/a11y/accessible-name.txt index cc427fdf61..cd88807fd1 100644 --- a/tests/a11y/accessible-name.txt +++ b/tests/a11y/accessible-name.txt @@ -3,6 +3,9 @@ window1 index: 0 state: enabled resizable sensitive showing visible toolkit: gail + + layer: window + alpha: 1 button1 "push button" parent: window1 @@ -10,6 +13,9 @@ window1 name: Accessible name state: enabled focusable sensitive showing visible toolkit: gail + + layer: widget + alpha: 1 text: Hello World! character count: 12 diff --git a/tests/a11y/hello-world.txt b/tests/a11y/hello-world.txt index 1714b4a184..92fab61288 100644 --- a/tests/a11y/hello-world.txt +++ b/tests/a11y/hello-world.txt @@ -3,6 +3,9 @@ window1 index: 0 state: enabled resizable sensitive showing visible toolkit: gail + + layer: window + alpha: 1 button1 "push button" parent: window1 @@ -10,6 +13,9 @@ window1 name: Hello World! state: enabled focusable sensitive showing visible toolkit: gail + + layer: widget + alpha: 1 text: Hello World! character count: 12 diff --git a/tests/a11y/link.txt b/tests/a11y/link.txt index 7866eff1e3..629917afc8 100644 --- a/tests/a11y/link.txt +++ b/tests/a11y/link.txt @@ -3,6 +3,9 @@ window1 index: 0 state: enabled resizable sensitive showing visible toolkit: gail + + layer: window + alpha: 1 button1 "push button" parent: window1 @@ -10,6 +13,9 @@ window1 name: Hello World! state: enabled focusable sensitive showing visible toolkit: gail + + layer: widget + alpha: 1 text: Hello World! character count: 12 diff --git a/tests/a11y/mnemonic.txt b/tests/a11y/mnemonic.txt index ea5dc31bf7..ae3ff4c3ac 100644 --- a/tests/a11y/mnemonic.txt +++ b/tests/a11y/mnemonic.txt @@ -3,12 +3,18 @@ window1 index: 0 state: enabled resizable sensitive showing visible toolkit: gail + + layer: window + alpha: 1 box1 "filler" parent: window1 index: 0 state: enabled horizontal sensitive toolkit: gail + + layer: widget + alpha: 1 label1 "label" parent: box1 @@ -17,6 +23,9 @@ window1 label-for: entry1 state: enabled multi-line sensitive visible toolkit: gail + + layer: widget + alpha: 1 text: Entry: character count: 6 @@ -29,6 +38,9 @@ window1 labelled-by: label1 state: editable enabled focusable sensitive single-line visible toolkit: gail + + layer: widget + alpha: 1 text: text character count: 4 diff --git a/tests/a11y/notebook.txt b/tests/a11y/notebook.txt index 18258afcce..49eb9b0e34 100644 --- a/tests/a11y/notebook.txt +++ b/tests/a11y/notebook.txt @@ -3,12 +3,18 @@ window1 index: 0 state: enabled resizable sensitive showing visible toolkit: gail + + layer: window + alpha: 1 notebook1 "page tab list" parent: window1 index: 0 state: enabled focusable sensitive showing visible toolkit: gail + + layer: widget + alpha: 1 selection count: 1 selected children: 0 @@ -18,6 +24,9 @@ window1 index: 0 name: Tab 1 state: enabled multi-line selectable selected sensitive showing visible + + layer: widget + alpha: 1 text: Tab 1 character count: 5 @@ -29,6 +38,9 @@ window1 name: Yes state: enabled focusable sensitive showing visible toolkit: gail + + layer: widget + alpha: 1 text: Yes character count: 3 @@ -48,6 +60,9 @@ window1 index: 1 name: Tab 2 state: enabled multi-line selectable sensitive showing visible + + layer: widget + alpha: 1 text: Tab 2 character count: 5 @@ -59,6 +74,9 @@ window1 name: No state: enabled focusable sensitive visible toolkit: gail + + layer: widget + alpha: 1 text: No character count: 2 diff --git a/tests/a11y/range.txt b/tests/a11y/range.txt index 75e3939fc3..56007ad0a0 100644 --- a/tests/a11y/range.txt +++ b/tests/a11y/range.txt @@ -3,12 +3,18 @@ window1 index: 0 state: enabled resizable sensitive showing visible toolkit: gail + + layer: window + alpha: 1 scale1 "slider" parent: window1 index: 0 state: enabled focusable horizontal sensitive showing visible toolkit: gail + + layer: widget + alpha: 1 text: ‎45.5 character count: 5 diff --git a/tests/a11y/text.txt b/tests/a11y/text.txt index 8293910fd3..434bac80ea 100644 --- a/tests/a11y/text.txt +++ b/tests/a11y/text.txt @@ -3,12 +3,18 @@ window1 index: 0 state: enabled resizable sensitive showing visible toolkit: gail + + layer: window + alpha: 1 text1 "text" parent: window1 index: 0 state: editable enabled focusable multi-line sensitive showing visible toolkit: gail + + layer: widget + alpha: 1 text: Twas brillig, and the slithy toves Did gyre and gimple in the wabe