forked from AuroraMiddleware/gtk
gtk-demo: Use style classes in the settings demo
Use .navigation-sidebar on the left, and .data-table on the right.
This commit is contained in:
parent
a9858c6662
commit
d8753a9fa3
@ -5,6 +5,10 @@
|
|||||||
* It demonstrates how to implement support for trees with GtkListView.
|
* It demonstrates how to implement support for trees with GtkListView.
|
||||||
* It also shows how to set up sorting and filtering for columns in a
|
* It also shows how to set up sorting and filtering for columns in a
|
||||||
* GtkColumnView.
|
* 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>
|
#include <gtk/gtk.h>
|
||||||
|
@ -20,6 +20,9 @@
|
|||||||
<object class="GtkScrolledWindow">
|
<object class="GtkScrolledWindow">
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkListView" id="listview">
|
<object class="GtkListView" id="listview">
|
||||||
|
<style>
|
||||||
|
<class name="navigation-sidebar"/>
|
||||||
|
</style>
|
||||||
<property name="factory">
|
<property name="factory">
|
||||||
<object class="GtkBuilderListItemFactory">
|
<object class="GtkBuilderListItemFactory">
|
||||||
<property name="bytes"><![CDATA[
|
<property name="bytes"><![CDATA[
|
||||||
@ -73,6 +76,9 @@
|
|||||||
<property name="vexpand">1</property>
|
<property name="vexpand">1</property>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkColumnView" id="columnview">
|
<object class="GtkColumnView" id="columnview">
|
||||||
|
<style>
|
||||||
|
<class name="data-table"/>
|
||||||
|
</style>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkColumnViewColumn" id="name_column">
|
<object class="GtkColumnViewColumn" id="name_column">
|
||||||
<property name="title">Name</property>
|
<property name="title">Name</property>
|
||||||
|
Loading…
Reference in New Issue
Block a user