1Gtk2::TreeViewColumn(3)User Contributed Perl DocumentatioGntk2::TreeViewColumn(3)
2
3
4

NAME

6       Gtk2::TreeViewColumn
7

HIERARCHY

9         Glib::Object
10         +----Glib::InitiallyUnowned
11              +----Gtk2::Object
12                   +----Gtk2::TreeViewColumn
13

INTERFACES

15         Gtk2::CellLayout
16

METHODS

18       treeviewcolumn = Gtk2::TreeViewColumn->new
19
20       treeviewcolumn = Gtk2::TreeViewColumn->new_with_attributes ($title,
21       $cell, $attr1, $col1, ...)
22
23           * $title (string)
24           * $cell (Gtk2::CellRenderer)
25           * ... (list) pairs of attributes and columns
26           * $col1 (integer) the first column
27           * $attr1 (string) the first attribute
28
29       $tree_column->add_attribute ($cell_renderer, $attribute, $column)
30
31           * $cell_renderer (Gtk2::CellRenderer)
32           * $attribute (string)
33           * $column (integer)
34
35       double = $tree_column->get_alignment
36
37       $tree_column->set_alignment ($xalign)
38
39           * $xalign (double)
40
41       $tree_column->set_attributes ($cell_renderer, ..., $col1, $attr1)
42
43           * $cell_renderer (Gtk2::CellRenderer)
44           * ... (list) pairs of attributes and columns
45           * $col1 (integer) the first column
46           * $attr1 (string) the first attribute
47
48       $tree_column->set_cell_data_func ($cell_renderer, $func, $data=undef)
49
50           * $cell_renderer (Gtk2::CellRenderer)
51           * $func (subroutine)
52           * $data (scalar)
53
54           Install $func as the callback to be used whenever $column needs to
55           set up $cell to render a cell.  $func should look like this:
56
57             sub cell_data_func {
58               my ($column, $cell, $model, $iter, $func_data) = @_;
59             }
60
61           and should set whatever properties of $cell are required for it to
62           draw the data properly.  No return value is expected.
63
64       (start_pos, width) = $tree_column->cell_get_position ($cell_renderer)
65
66           * $cell_renderer (Gtk2::CellRenderer)
67
68       list = $tree_column->cell_get_size
69
70       boolean = $tree_column->cell_is_visible
71
72       list = $tree_column->get_cell_renderers
73
74           Returns a list of Gtk2::CellRenderer's.
75
76       $tree_column->cell_set_cell_data ($tree_model, $iter, $is_expander,
77       $is_expanded)
78
79           * $tree_model (Gtk2::TreeModel)
80           * $iter (Gtk2::TreeIter)
81           * $is_expander (boolean)
82           * $is_expanded (boolean)
83
84       $tree_column->clear
85
86       $tree_column->clear_attributes ($cell_renderer)
87
88           * $cell_renderer (Gtk2::CellRenderer)
89
90       boolean = $tree_column->get_clickable
91
92       $tree_column->set_clickable ($clickable)
93
94           * $clickable (boolean)
95
96       $tree_column->clicked
97
98       boolean = $tree_column->get_expand
99
100       $tree_column->set_expand ($expand)
101
102           * $expand (boolean)
103
104       integer = $tree_column->get_fixed_width
105
106       $tree_column->set_fixed_width ($fixed_width)
107
108           * $fixed_width (integer)
109
110       $tree_column->focus_cell ($cell)
111
112           * $cell (Gtk2::CellRenderer)
113
114       integer = $tree_column->get_max_width
115
116       $tree_column->set_max_width ($max_width)
117
118           * $max_width (integer)
119
120       integer = $tree_column->get_min_width
121
122       $tree_column->set_min_width ($min_width)
123
124           * $min_width (integer)
125
126       $tree_column->pack_end ($cell, $expand)
127
128           * $cell (Gtk2::CellRenderer)
129           * $expand (boolean)
130
131       $tree_column->pack_start ($cell, $expand)
132
133           * $cell (Gtk2::CellRenderer)
134           * $expand (boolean)
135
136       $tree_column->queue_resize
137
138       boolean = $tree_column->get_reorderable
139
140       $tree_column->set_reorderable ($reorderable)
141
142           * $reorderable (boolean)
143
144       boolean = $tree_column->get_resizable
145
146       $tree_column->set_resizable ($resizable)
147
148           * $resizable (boolean)
149
150       treeviewcolumnsizing = $tree_column->get_sizing
151
152       $tree_column->set_sizing ($type)
153
154           * $type (Gtk2::TreeViewColumnSizing)
155
156       integer = $tree_column->get_sort_column_id
157
158       $tree_column->set_sort_column_id ($sort_column_id)
159
160           * $sort_column_id (integer)
161
162       boolean = $tree_column->get_sort_indicator
163
164       $tree_column->set_sort_indicator ($setting)
165
166           * $setting (boolean)
167
168       sorttype = $tree_column->get_sort_order
169
170       $tree_column->set_sort_order ($order)
171
172           * $order (Gtk2::SortType)
173
174       integer = $tree_column->get_spacing
175
176       $tree_column->set_spacing ($spacing)
177
178           * $spacing (integer)
179
180       string = $tree_column->get_title
181
182       $tree_column->set_title ($title)
183
184           * $title (string)
185
186       boolean = $tree_column->get_visible
187
188       $tree_column->set_visible ($visible)
189
190           * $visible (boolean)
191
192       widget or undef = $tree_column->get_widget
193
194       $tree_column->set_widget ($widget)
195
196           * $widget (Gtk2::Widget or undef)
197
198       integer = $tree_column->get_width
199

PROPERTIES

201       'alignment' (Glib::Float : readable / writable / private)
202           X Alignment of the column header text or widget
203
204       'clickable' (boolean : readable / writable / private)
205           Whether the header can be clicked
206
207       'expand' (boolean : readable / writable / private)
208           Column gets share of extra width allocated to the widget
209
210       'fixed-width' (integer : readable / writable / private)
211           Current fixed width of the column
212
213       'max-width' (integer : readable / writable / private)
214           Maximum allowed width of the column
215
216       'min-width' (integer : readable / writable / private)
217           Minimum allowed width of the column
218
219       'reorderable' (boolean : readable / writable / private)
220           Whether the column can be reordered around the headers
221
222       'resizable' (boolean : readable / writable / private)
223           Column is user-resizable
224
225       'sizing' (Gtk2::TreeViewColumnSizing : readable / writable / private)
226           Resize mode of the column
227
228       'sort-indicator' (boolean : readable / writable / private)
229           Whether to show a sort indicator
230
231       'sort-order' (Gtk2::SortType : readable / writable / private)
232           Sort direction the sort indicator should indicate
233
234       'spacing' (integer : readable / writable / private)
235           Space which is inserted between cells
236
237       'title' (string : readable / writable / private)
238           Title to appear in column header
239
240       'visible' (boolean : readable / writable / private)
241           Whether to display the column
242
243       'widget' (Gtk2::Widget : readable / writable / private)
244           Widget to put in column header button instead of column title
245
246       'width' (integer : readable / private)
247           Current width of the column
248

SIGNALS

250       clicked (Gtk2::TreeViewColumn)
251

ENUMS AND FLAGS

253       enum Gtk2::SortType
254
255       * 'ascending' / 'GTK_SORT_ASCENDING'
256       * 'descending' / 'GTK_SORT_DESCENDING'
257
258       enum Gtk2::TreeViewColumnSizing
259
260       * 'grow-only' / 'GTK_TREE_VIEW_COLUMN_GROW_ONLY'
261       * 'autosize' / 'GTK_TREE_VIEW_COLUMN_AUTOSIZE'
262       * 'fixed' / 'GTK_TREE_VIEW_COLUMN_FIXED'
263

SEE ALSO

265       Gtk2, Glib::Object, Glib::InitiallyUnowned, Gtk2::Object
266
268       Copyright (C) 2003-2007 by the gtk2-perl team.
269
270       This software is licensed under the LGPL.  See Gtk2 for a full notice.
271
272
273
274perl v5.8.8                       2007-03-18           Gtk2::TreeViewColumn(3)
Impressum