summaryrefslogtreecommitdiffstats
path: root/subprojects/libhandy/examples/hdy-demo-preferences-window.ui
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 14:36:24 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 14:36:24 +0000
commit9b6d8e63db85c30007b463e91f91a791969fa83f (patch)
tree0899af51d73c1bf986f73ae39a03c4436083018a /subprojects/libhandy/examples/hdy-demo-preferences-window.ui
parentInitial commit. (diff)
downloadgnome-control-center-upstream.tar.xz
gnome-control-center-upstream.zip
Adding upstream version 1:3.38.4.upstream/1%3.38.4upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'subprojects/libhandy/examples/hdy-demo-preferences-window.ui')
-rw-r--r--subprojects/libhandy/examples/hdy-demo-preferences-window.ui256
1 files changed, 256 insertions, 0 deletions
diff --git a/subprojects/libhandy/examples/hdy-demo-preferences-window.ui b/subprojects/libhandy/examples/hdy-demo-preferences-window.ui
new file mode 100644
index 0000000..83c83a9
--- /dev/null
+++ b/subprojects/libhandy/examples/hdy-demo-preferences-window.ui
@@ -0,0 +1,256 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <requires lib="gtk+" version="3.0"/>
+ <template class="HdyDemoPreferencesWindow" parent="HdyPreferencesWindow">
+ <property name="can-swipe-back">True</property>
+ <child>
+ <object class="HdyPreferencesPage">
+ <property name="icon_name">edit-select-all-symbolic</property>
+ <property name="title">Layout</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyPreferencesGroup">
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyPreferencesRow">
+ <property name="title" bind-source="welcome_label" bind-property="label" bind-flags="sync-create"/>
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkLabel" id="welcome_label">
+ <property name="ellipsize">end</property>
+ <property name="label" translatable="yes">This is a preferences window</property>
+ <property name="margin">12</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="HdyPreferencesGroup">
+ <property name="description" translatable="yes">Preferences are organized in pages, this example has the following pages:</property>
+ <property name="title" translatable="yes">Pages</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Layout</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Search</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="HdyPreferencesGroup">
+ <property name="description" translatable="yes">Preferences are grouped together, a group can have a tile and a description. Descriptions will be wrapped if they are too long. This page has the following groups:</property>
+ <property name="title" translatable="yes">Groups</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">An untitled group</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Pages</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Groups</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Preferences</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="HdyPreferencesGroup">
+ <property name="title" translatable="yes">Preferences</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Preferences rows are appended to the list box</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkBox">
+ <property name="visible">True</property>
+ <style>
+ <class name="inline-toolbar"/>
+ </style>
+ <child>
+ <object class="GtkLabel">
+ <property name="ellipsize">end</property>
+ <property name="label" translatable="yes">Other widgets are appended after the list box</property>
+ <property name="margin">12</property>
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="HdyPreferencesGroup">
+ <property name="description" translatable="yes">Preferences windows can have subpages.</property>
+ <property name="title" translatable="yes">Subpages</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Go to a subpage</property>
+ <property name="visible">True</property>
+ <property name="activatable">True</property>
+ <signal name="activated" handler="subpage1_activated_cb" swapped="yes"/>
+ <child>
+ <object class="GtkImage">
+ <property name="icon_name">go-next-symbolic</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Go to another subpage</property>
+ <property name="visible">True</property>
+ <property name="activatable">True</property>
+ <signal name="activated" handler="subpage2_activated_cb" swapped="yes"/>
+ <child>
+ <object class="GtkImage">
+ <property name="icon_name">go-next-symbolic</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="HdyPreferencesPage">
+ <property name="icon_name">edit-find-symbolic</property>
+ <property name="title">Search</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyPreferencesGroup">
+ <property name="description">Preferences can be searched, do so using one of the following ways:</property>
+ <property name="title">Searching</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Activate the search button</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ <child>
+ <object class="HdyPreferencesRow">
+ <property name="title" translatable="yes">Ctrl + F</property>
+ <property name="visible">True</property>
+ <child>
+ <object class="GtkShortcutLabel">
+ <property name="accelerator">&lt;ctrl&gt;f</property>
+ <property name="margin">12</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ <child>
+ <object class="HdyActionRow">
+ <property name="title" translatable="yes">Directly type your search</property>
+ <property name="visible">True</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </template>
+ <object class="GtkBox" id="subpage1">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="can_focus">False</property>
+ <property name="halign">center</property>
+ <property name="valign">center</property>
+ <property name="vexpand">True</property>
+ <property name="hexpand">True</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">This is a subpage</property>
+ <property name="justify">center</property>
+ <property name="wrap">True</property>
+ <property name="opacity">0.5</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ <attribute name="scale" value="2"/>
+ </attributes>
+ </object>
+ </child>
+ <child>
+ <object class="GtkButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Return to the preferences</property>
+ <signal name="clicked" handler="return_to_preferences_cb" swapped="yes"/>
+ <style>
+ <class name="suggested-action"/>
+ </style>
+ </object>
+ </child>
+ </object>
+ <object class="GtkBox" id="subpage2">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <property name="can_focus">False</property>
+ <property name="halign">center</property>
+ <property name="valign">center</property>
+ <property name="vexpand">True</property>
+ <property name="hexpand">True</property>
+ <property name="spacing">24</property>
+ <child>
+ <object class="GtkLabel">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">This is another subpage</property>
+ <property name="justify">center</property>
+ <property name="wrap">True</property>
+ <property name="opacity">0.5</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ <attribute name="scale" value="2"/>
+ </attributes>
+ </object>
+ </child>
+ <child>
+ <object class="GtkButton">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Return to the preferences</property>
+ <signal name="clicked" handler="return_to_preferences_cb" swapped="yes"/>
+ <style>
+ <class name="suggested-action"/>
+ </style>
+ </object>
+ </child>
+ </object>
+</interface>