]> Pileus Git - ~andy/gtk/blob - docs/reference/gtk/tmpl/gtktreemodelfilter.sgml
bd6d1e31b0242790dc4112bd200767ec795673f1
[~andy/gtk] / docs / reference / gtk / tmpl / gtktreemodelfilter.sgml
1 <!-- ##### SECTION Title ##### -->
2 GtkTreeModelFilter
3
4 <!-- ##### SECTION Short_Description ##### -->
5 A GtkTreeModel which hides parts of an underlying tree model
6
7 <!-- ##### SECTION Long_Description ##### -->
8 <para>
9 A #GtkTreeModelFilter is a tree model which wraps another tree model,
10 and can do the following things:
11 <itemizedlist>
12 <listitem><para>
13 Filter specific rows, based on data from a "visible column", a column
14 storing booleans indicating whether the row should be filtered or not,
15 or based on the return value of a "visible function", which gets a
16 model, iter and user_data and returns a boolean indicating whether the
17 row should be filtered or not.
18 </para></listitem>
19 <listitem><para>
20 Modify the "appearance" of the model, using a modify function. 
21 This is extremely powerful and allows for just changing
22 some values and also for creating a completely different model based on
23 the given child model. 
24 </para></listitem>
25 <listitem><para>
26 Set a different root node, also known as a "virtual root". You can pass in 
27 a #GtkTreePath indicating the root node for the filter at construction time.
28 </para></listitem>
29 </itemizedlist>
30 </para>
31
32 <!-- ##### SECTION See_Also ##### -->
33 <para>
34 #GtkTreeModelSort
35 </para>
36
37 <!-- ##### SECTION Stability_Level ##### -->
38
39
40 <!-- ##### STRUCT GtkTreeModelFilter ##### -->
41 <para>
42 The GtkTreeModelFilter struct contains only private fields.
43 </para>
44
45
46 <!-- ##### ARG GtkTreeModelFilter:child-model ##### -->
47 <para>
48
49 </para>
50
51 <!-- ##### ARG GtkTreeModelFilter:virtual-root ##### -->
52 <para>
53
54 </para>
55
56 <!-- ##### USER_FUNCTION GtkTreeModelFilterVisibleFunc ##### -->
57 <para>
58 A function which decides whether the row indicated by @iter is visible.
59 </para>
60
61 @model: the child model of the #GtkTreeModelFilter
62 @iter: a #GtkTreeIter pointing to the row in @model whose visibility 
63    is determined
64 @data: user data given to gtk_tree_model_filter_set_visible_func()
65 @Returns: Whether the row indicated by @iter is visible.
66
67
68 <!-- ##### USER_FUNCTION GtkTreeModelFilterModifyFunc ##### -->
69 <para>
70 A function which calculates display values from raw values in the model.
71 It must fill @value with the display value for the column @column in the 
72 row indicated by @iter. 
73 </para>
74 <para>
75 Since this function is called for each data access, it's not a
76 particularly efficient operation.
77 </para>
78
79 @model: the #GtkTreeModelFilter
80 @iter: a #GtkTreeIter pointing to the row whose display values are determined
81 @value: A #GValue which is already initialized for with the correct type for 
82   the column @column.
83 @column: the column whose display value is determined
84 @data: user data given to gtk_tree_model_filter_set_modify_func()
85
86
87 <!-- ##### FUNCTION gtk_tree_model_filter_new ##### -->
88 <para>
89
90 </para>
91
92 @child_model: 
93 @root: 
94 @Returns: 
95
96
97 <!-- ##### FUNCTION gtk_tree_model_filter_set_visible_func ##### -->
98 <para>
99
100 </para>
101
102 @filter: 
103 @func: 
104 @data: 
105 @destroy: 
106
107
108 <!-- ##### FUNCTION gtk_tree_model_filter_set_modify_func ##### -->
109 <para>
110
111 </para>
112
113 @filter: 
114 @n_columns: 
115 @types: 
116 @func: 
117 @data: 
118 @destroy: 
119
120
121 <!-- ##### FUNCTION gtk_tree_model_filter_set_visible_column ##### -->
122 <para>
123
124 </para>
125
126 @filter: 
127 @column: 
128
129
130 <!-- ##### FUNCTION gtk_tree_model_filter_get_model ##### -->
131 <para>
132
133 </para>
134
135 @filter: 
136 @Returns: 
137
138
139 <!-- ##### FUNCTION gtk_tree_model_filter_convert_child_iter_to_iter ##### -->
140 <para>
141
142 </para>
143
144 @filter: 
145 @filter_iter: 
146 @child_iter: 
147 @Returns: 
148
149
150 <!-- ##### FUNCTION gtk_tree_model_filter_convert_iter_to_child_iter ##### -->
151 <para>
152
153 </para>
154
155 @filter: 
156 @child_iter: 
157 @filter_iter: 
158
159
160 <!-- ##### FUNCTION gtk_tree_model_filter_convert_child_path_to_path ##### -->
161 <para>
162
163 </para>
164
165 @filter: 
166 @child_path: 
167 @Returns: 
168
169
170 <!-- ##### FUNCTION gtk_tree_model_filter_convert_path_to_child_path ##### -->
171 <para>
172
173 </para>
174
175 @filter: 
176 @filter_path: 
177 @Returns: 
178
179
180 <!-- ##### FUNCTION gtk_tree_model_filter_refilter ##### -->
181 <para>
182
183 </para>
184
185 @filter: 
186
187
188 <!-- ##### FUNCTION gtk_tree_model_filter_clear_cache ##### -->
189 <para>
190
191 </para>
192
193 @filter: 
194
195