1Gtk2::Toolbar(3)      User Contributed Perl Documentation     Gtk2::Toolbar(3)
2
3
4

NAME

6       Gtk2::Toolbar - wrapper for GtkToolbar
7

HIERARCHY

9         Glib::Object
10         +----Glib::InitiallyUnowned
11              +----Gtk2::Object
12                   +----Gtk2::Widget
13                        +----Gtk2::Container
14                             +----Gtk2::Toolbar
15

INTERFACES

17         Glib::Object::_Unregistered::AtkImplementorIface
18         Gtk2::Buildable
19         Gtk2::ToolShell
20         Gtk2::Orientable
21

METHODS

23   widget = Gtk2::Toolbar->new
24   widget = $toolbar->append_element ($type, $widget, $text, $tooltip_text,
25       $tooltip_private_text, $icon, $callback=undef, $user_data=undef)
26       •   $type (Gtk2::ToolbarChildType)
27
28       •   $widget (Gtk2::Widget or undef)
29
30       •   $text (string)
31
32       •   $tooltip_text (string or undef)
33
34       •   $tooltip_private_text (string or undef)
35
36       •   $icon (Gtk2::Widget or undef)
37
38       •   $callback (subroutine)
39
40       •   $user_data (scalar)
41
42   widget = $toolbar->append_item ($text, $tooltip_text,
43       $tooltip_private_text, $icon, $callback=undef, $user_data=undef)
44       •   $text (string)
45
46       •   $tooltip_text (string or undef)
47
48       •   $tooltip_private_text (string or undef)
49
50       •   $icon (Gtk2::Widget or undef)
51
52       •   $callback (subroutine)
53
54       •   $user_data (scalar)
55
56   $toolbar->append_space
57   $toolbar->append_widget ($widget, $tooltip_text, $tooltip_private_text)
58       •   $widget (Gtk2::Widget)
59
60       •   $tooltip_text (string or undef)
61
62       •   $tooltip_private_text (string or undef)
63
64   $toolbar->set_drop_highlight_item ($tool_item, $index)
65       •   $tool_item (Gtk2::ToolItem or undef)
66
67       •   $index (integer)
68
69       Since: gtk+ 2.4
70
71   integer = $toolbar->get_drop_index ($x, $y)
72       •   $x (integer)
73
74       •   $y (integer)
75
76       Since: gtk+ 2.4
77
78   iconsize = $toolbar->get_icon_size
79   $toolbar->set_icon_size ($icon_size)
80       •   $icon_size (Gtk2::IconSize)
81
82   $toolbar->insert ($item, $pos)
83       •   $item (Gtk2::ToolItem)
84
85       •   $pos (integer)
86
87       Since: gtk+ 2.4
88
89   widget = $toolbar->insert_element ($type, $widget, $text, $tooltip_text,
90       $tooltip_private_text, $icon, $callback, $user_data, $position)
91       •   $type (Gtk2::ToolbarChildType)
92
93       •   $widget (Gtk2::Widget or undef)
94
95       •   $text (string)
96
97       •   $tooltip_text (string or undef)
98
99       •   $tooltip_private_text (string or undef)
100
101       •   $icon (Gtk2::Widget or undef)
102
103       •   $callback (subroutine)
104
105       •   $user_data (scalar)
106
107       •   $position (integer)
108
109   widget = $toolbar->insert_item ($text, $tooltip_text,
110       $tooltip_private_text, $icon, $callback, $user_data, $position)
111       •   $text (string)
112
113       •   $tooltip_text (string or undef)
114
115       •   $tooltip_private_text (string or undef)
116
117       •   $icon (Gtk2::Widget or undef)
118
119       •   $callback (subroutine)
120
121       •   $user_data (scalar)
122
123       •   $position (integer)
124
125   $toolbar->insert_space ($position)
126       •   $position (integer)
127
128   widget = $toolbar->insert_stock ($stock_id, $tooltip_text,
129       $tooltip_private_text, $callback, $user_data, $position)
130       •   $stock_id (string)
131
132       •   $tooltip_text (string or undef)
133
134       •   $tooltip_private_text (string or undef)
135
136       •   $callback (subroutine)
137
138       •   $user_data (scalar)
139
140       •   $position (integer)
141
142   $toolbar->insert_widget ($widget, $tooltip_text, $tooltip_private_text,
143       $position)
144       •   $widget (Gtk2::Widget)
145
146       •   $tooltip_text (string or undef)
147
148       •   $tooltip_private_text (string or undef)
149
150       •   $position (integer)
151
152   integer = $toolbar->get_item_index ($item)
153       •   $item (Gtk2::ToolItem)
154
155       Since: gtk+ 2.4
156
157   integer = $toolbar->get_n_items
158       Since: gtk+ 2.4
159
160   toolitem or undef = $toolbar->get_nth_item ($n)
161       •   $n (integer)
162
163       Since: gtk+ 2.4
164
165   orientation = $toolbar->get_orientation
166   $toolbar->set_orientation ($orientation)
167       •   $orientation (Gtk2::Orientation)
168
169   widget = $toolbar->prepend_element ($type, $widget, $text, $tooltip_text,
170       $tooltip_private_text, $icon, $callback=undef, $user_data=undef)
171       •   $type (Gtk2::ToolbarChildType)
172
173       •   $widget (Gtk2::Widget or undef)
174
175       •   $text (string)
176
177       •   $tooltip_text (string or undef)
178
179       •   $tooltip_private_text (string or undef)
180
181       •   $icon (Gtk2::Widget or undef)
182
183       •   $callback (subroutine)
184
185       •   $user_data (scalar)
186
187   widget = $toolbar->prepend_item ($text, $tooltip_text,
188       $tooltip_private_text, $icon, $callback=undef, $user_data=undef)
189       •   $text (string)
190
191       •   $tooltip_text (string or undef)
192
193       •   $tooltip_private_text (string or undef)
194
195       •   $icon (Gtk2::Widget or undef)
196
197       •   $callback (subroutine)
198
199       •   $user_data (scalar)
200
201   $toolbar->prepend_space
202   $toolbar->prepend_widget ($widget, $tooltip_text, $tooltip_private_text)
203       •   $widget (Gtk2::Widget)
204
205       •   $tooltip_text (string or undef)
206
207       •   $tooltip_private_text (string or undef)
208
209   reliefstyle = $toolbar->get_relief_style
210       Since: gtk+ 2.4
211
212   $toolbar->remove_space ($position)
213       •   $position (integer)
214
215   boolean = $toolbar->get_show_arrow
216       Since: gtk+ 2.4
217
218   $toolbar->set_show_arrow ($show_arrow)
219       •   $show_arrow (boolean)
220
221       Since: gtk+ 2.4
222
223   toolbarstyle = $toolbar->get_style
224   $toolbar->set_style ($style)
225       •   $style (Gtk2::ToolbarStyle)
226
227   boolean = $toolbar->get_tooltips
228   $toolbar->set_tooltips ($enable)
229       •   $enable (boolean)
230
231   $toolbar->unset_icon_size
232   $toolbar->unset_style

PROPERTIES

234       'icon-size' (integer : default 3 : readable / writable / private /
235       static-nick / static-blurb)
236           Size of icons in this toolbar
237
238       'icon-size-set' (boolean : default false : readable / writable /
239       private / static-nick / static-blurb)
240           Whether the icon-size property has been set
241
242       'show-arrow' (boolean : default true : readable / writable / private /
243       static-nick / static-blurb)
244           If an arrow should be shown if the toolbar doesn't fit
245
246       'toolbar-style' (Gtk2::ToolbarStyle : default "both" : readable /
247       writable / private / static-nick / static-blurb)
248           How to draw the toolbar
249
250       'tooltips' (boolean : default true : readable / writable / private /
251       static-nick / static-blurb)
252           If the tooltips of the toolbar should be active or not
253

CHILD PROPERTIES

255       'expand' (boolean : default false : readable / writable / private /
256       static-nick / static-blurb)
257           Whether the item should receive extra space when the toolbar grows
258
259       'homogeneous' (boolean : default false : readable / writable / private
260       / static-nick / static-blurb)
261           Whether the item should be the same size as other homogeneous items
262

STYLE PROPERTIES

264       'button-relief' (Gtk2::ReliefStyle : default "none" : readable /
265       private / static-nick / static-blurb)
266           Type of bevel around toolbar buttons
267
268       'internal-padding' (integer : default 0 : readable / private / static-
269       nick / static-blurb)
270           Amount of border space between the toolbar shadow and the buttons
271
272       'max-child-expand' (integer : default INT_MAX : readable / private /
273       static-nick / static-blurb)
274           Maximum amount of space an expandable item will be given
275
276       'shadow-type' (Gtk2::ShadowType : default "out" : readable / private /
277       static-nick / static-blurb)
278           Style of bevel around the toolbar
279
280       'space-size' (integer : default 12 : readable / private / static-nick /
281       static-blurb)
282           Size of spacers
283
284       'space-style' (Gtk2::ToolbarSpaceStyle : default "line" : readable /
285       private / static-nick / static-blurb)
286           Whether spacers are vertical lines or just blank
287

SIGNALS

289       boolean = focus-home-or-end (Gtk2::Toolbar, boolean)
290       orientation-changed (Gtk2::Toolbar, Gtk2::Orientation)
291       boolean = popup-context-menu (Gtk2::Toolbar, integer, integer, integer)
292       style-changed (Gtk2::Toolbar, Gtk2::ToolbarStyle)
293

ENUMS AND FLAGS

295   enum Gtk2::IconSize
296       •   'invalid' / 'GTK_ICON_SIZE_INVALID'
297
298       •   'menu' / 'GTK_ICON_SIZE_MENU'
299
300       •   'small-toolbar' / 'GTK_ICON_SIZE_SMALL_TOOLBAR'
301
302       •   'large-toolbar' / 'GTK_ICON_SIZE_LARGE_TOOLBAR'
303
304       •   'button' / 'GTK_ICON_SIZE_BUTTON'
305
306       •   'dnd' / 'GTK_ICON_SIZE_DND'
307
308       •   'dialog' / 'GTK_ICON_SIZE_DIALOG'
309
310   enum Gtk2::Orientation
311       •   'horizontal' / 'GTK_ORIENTATION_HORIZONTAL'
312
313       •   'vertical' / 'GTK_ORIENTATION_VERTICAL'
314
315   enum Gtk2::ReliefStyle
316       •   'normal' / 'GTK_RELIEF_NORMAL'
317
318       •   'half' / 'GTK_RELIEF_HALF'
319
320       •   'none' / 'GTK_RELIEF_NONE'
321
322   enum Gtk2::ToolbarChildType
323       •   'space' / 'GTK_TOOLBAR_CHILD_SPACE'
324
325       •   'button' / 'GTK_TOOLBAR_CHILD_BUTTON'
326
327       •   'togglebutton' / 'GTK_TOOLBAR_CHILD_TOGGLEBUTTON'
328
329       •   'radiobutton' / 'GTK_TOOLBAR_CHILD_RADIOBUTTON'
330
331       •   'widget' / 'GTK_TOOLBAR_CHILD_WIDGET'
332
333   enum Gtk2::ToolbarStyle
334       •   'icons' / 'GTK_TOOLBAR_ICONS'
335
336       •   'text' / 'GTK_TOOLBAR_TEXT'
337
338       •   'both' / 'GTK_TOOLBAR_BOTH'
339
340       •   'both-horiz' / 'GTK_TOOLBAR_BOTH_HORIZ'
341

SEE ALSO

343       Gtk2, Glib::Object, Glib::InitiallyUnowned, Gtk2::Object, Gtk2::Widget,
344       Gtk2::Container
345
347       Copyright (C) 2003-2011 by the gtk2-perl team.
348
349       This software is licensed under the LGPL.  See Gtk2 for a full notice.
350
351
352
353perl v5.38.0                      2023-07-20                  Gtk2::Toolbar(3)
Impressum