[gtk/list-styles: 6/8] gtk-demo: Use style classes in the settings demo
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/list-styles: 6/8] gtk-demo: Use style classes in the settings demo
- Date: Sun, 9 Aug 2020 14:56:35 +0000 (UTC)
commit c5c30ab056aaf11e7517bb27dc826810fcddbde8
Author: Matthias Clasen <mclasen redhat com>
Date: Sun Aug 9 08:28:29 2020 -0400
gtk-demo: Use style classes in the settings demo
Use .navigation-sidebar on the left, and .data-table
on the right.
demos/gtk-demo/listview_settings.c | 4 ++++
demos/gtk-demo/listview_settings.ui | 6 ++++++
2 files changed, 10 insertions(+)
---
diff --git a/demos/gtk-demo/listview_settings.c b/demos/gtk-demo/listview_settings.c
index 3bb674117b..9e5b3029d7 100644
--- a/demos/gtk-demo/listview_settings.c
+++ b/demos/gtk-demo/listview_settings.c
@@ -5,6 +5,10 @@
* It demonstrates how to implement support for trees with GtkListView.
* It also shows how to set up sorting and filtering for columns in a
* GtkColumnView.
+ *
+ * It also demonstrates different styles of list. The tree on the left
+ * uses the .navigation-sidebar style class, the list on the right uses
+ * the .data-table style class.
*/
#include <gtk/gtk.h>
diff --git a/demos/gtk-demo/listview_settings.ui b/demos/gtk-demo/listview_settings.ui
index f428d6b4dd..35c3c79c98 100644
--- a/demos/gtk-demo/listview_settings.ui
+++ b/demos/gtk-demo/listview_settings.ui
@@ -20,6 +20,9 @@
<object class="GtkScrolledWindow">
<child>
<object class="GtkListView" id="listview">
+ <style>
+ <class name="navigation-sidebar"/>
+ </style>
<property name="factory">
<object class="GtkBuilderListItemFactory">
<property name="bytes"><![CDATA[
@@ -73,6 +76,9 @@
<property name="vexpand">1</property>
<child>
<object class="GtkColumnView" id="columnview">
+ <style>
+ <class name="data-table"/>
+ </style>
<child>
<object class="GtkColumnViewColumn" id="name_column">
<property name="title">Name</property>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]