Add accessibility properties

This commit is contained in:
James Westman 2021-11-12 00:26:23 -06:00
parent d511b3f1e3
commit b776163cd7
No known key found for this signature in database
GPG key ID: CE2DBA0ADB654EA6
20 changed files with 324 additions and 13 deletions

View file

@ -0,0 +1,10 @@
using Gtk 4.0;
Gtk.Widget {
accessibility {
label: _("Hello, world!");
labelled_by: my_label;
checked: true;
}
}
Gtk.Label my_label {}

View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<requires lib="gtk" version="4.0"/>
<object class="GtkWidget">
<accessibility>
<property name="label" translatable="true">Hello, world!</property>
<relation name="labelled_by">my_label</relation>
<state name="checked">true</state>
</accessibility>
</object>
<object class="GtkLabel" id="my_label"></object>
</interface>