1
  
2
  
3
  
4
  
5
  
6
  
7
  
8
  
9
  
10
  
11
  
12
  
13
  
14
  
15
  
16
  
17
  
18
  
19
  
20
  
21
  
22
  
23
  
24
  
25
  
26
  
27
  
28
  
29
  
30
  
31
  
32
  
33
  
34
  
35
  
36
  
37
  
38
  
39
  
40
  
41
  
42
  
43
  
44
  
45
  
46
  
47
  
48
  
49
  
50
  
51
  
52
  
53
  
54
  
55
  
56
  
57
  
58
  
59
  
60
  
61
  
62
  
63
  
64
  
65
  
66
  
67
  
68
  
69
  
70
  
71
  
72
  
73
  
74
  
75
  
76
  
77
  
78
  
79
  
80
  
81
  
82
  
83
  
84
  
85
  
86
  
87
  
88
  
89
  
90
  
91
  
92
  
93
  
94
  
95
  
96
  
97
  
98
  
99
  
100
  
101
  
102
  
103
  
104
  
105
  
106
  
107
  
108
  
109
  
110
  
111
  
112
  
113
  
114
  
115
  
116
  
117
  
118
  
119
  
120
  
121
  
122
  
123
  
124
  
125
  
126
  
127
  
128
  
129
  
130
  
131
  
132
  
133
  
134
  
135
  
136
  
137
  
138
  
139
  
140
  
141
  
142
  
143
  
144
  
145
  
146
  
147
  
148
  
149
  
150
  
151
  
152
  
153
  
154
  
155
  
156
  
157
  
158
  
159
  
160
  
161
  
162
  
163
  
164
  
165
  
166
  
167
  
168
  
169
  
170
  
171
  
172
  
173
  
174
  
175
  
176
  
177
  
178
  
179
  
180
  
181
  
182
  
183
  
184
  
185
  
186
  
187
  
188
  
189
  
190
  
191
  
192
  
193
  
194
  
195
  
196
  
197
  
198
  
199
  
200
  
201
  
202
  
203
  
204
  
205
  
206
  
207
  
208
  
209
  
210
  
211
  
212
  
213
  
214
  
215
  
216
  
217
  
218
  
219
  
220
  
221
  
222
  
223
  
224
  
225
  
226
  
227
  
228
  
229
  
230
  
231
  
232
  
233
  
234
  
235
  
236
  
237
  
238
  
239
  
240
  
241
  
242
  
243
  
244
  
245
  
246
  
247
  
248
  
249
  
250
  
251
  
252
  
253
  
254
  
255
  
256
  
257
  
258
  
259
  
260
  
261
  
262
  
263
  
264
  
265
  
266
  
267
  
268
  
269
  
270
  
271
  
272
  
273
  
274
  
275
  
276
  
277
  
278
  
279
  
//! The NoteBook Widget is a collection of 'pages' that overlap each 
//! other, each page contains different information. This widget has 
//! become more common lately in GUI programming, and it is a good way 
//! to show blocks similar information that warrant separation in their 
//! display. 
//! 
//!@expr{ GTK2.Notebook()->set_tab_pos(GTK2.POS_LEFT)->append_page(GTK2.Label("Page 1\nContents"),GTK2.Label("Page 1"))->append_page(GTK2.Label(""),GTK2.Label("Page 2"))->append_page(GTK2.Label("Page 3 contents\nare here!"),GTK2.Label("Page 3"))@} 
//!@xml{<image>../images/gtk2_notebook.png</image>@} 
//! 
//!@expr{ GTK2.Notebook()->set_tab_pos(GTK2.POS_TOP)->append_page(GTK2.Label("Page 1\nContents"),GTK2.Label("Page 1"))->append_page(GTK2.Label(""),GTK2.Label("Page 2"))->append_page(GTK2.Label("Page 3 contents\nare here!"),GTK2.Label("Page 3"))@} 
//!@xml{<image>../images/gtk2_notebook_2.png</image>@} 
//! 
//!@expr{ GTK2.Notebook()->set_tab_pos(GTK2.POS_RIGHT)->append_page(GTK2.Label("Page 1\nContents"),GTK2.Label("Page 1"))->append_page(GTK2.Label(""),GTK2.Label("Page 2"))->append_page(GTK2.Label("Page 3 contents\nare here!"),GTK2.Label("Page 3"))->next_page()->next_page()@} 
//!@xml{<image>../images/gtk2_notebook_3.png</image>@} 
//! 
//! Properties: 
//! int enable-popup 
//! int homogeneous 
//! int page 
//! int scrollable 
//! int show-border 
//! int show-tabs 
//! int tab-border 
//! int tab-hborder 
//! int tab-pos 
//! int tab-vborder 
//!  
//! Child properties: 
//! string menu-label 
//! int position 
//! int tab-expand 
//! int tab-fill 
//! string tab-label 
//! int tab-pack 
//!  
//! Style properties: 
//! int has-backward-stepper 
//! int has-forward-stepper 
//! int has-secondary-backward-stepper 
//! int has-secondary-forward-stepper 
//! int tab-curvature 
//! int tab-overlap 
//! 
//! 
//!  Signals: 
//! @b{change_current_page@} 
//! 
//! @b{focus_tab@} 
//! 
//! @b{move_focus_out@} 
//! 
//! @b{select_page@} 
//! 
//! @b{switch_page@} 
//! Called when a different page is selected 
//! 
//! 
 
inherit GTK2.Container; 
 
GTK2.Notebook append_page( GTK2.Widget contents, GTK2.Widget label ); 
//! Add a new 'page' to the notebook. The first argument is the contents of 
//! the page, the second argument is the label. 
//! 
//! 
 
GTK2.Notebook append_page_menu( GTK2.Widget contents, GTK2.Widget label, GTK2.Widget menu ); 
//! Add a new 'page' to the notebook. The first argument is the 
//! contents of the page, the second argument is the label, the third 
//! argument is a menu label widget. 
//! 
//! 
 
protected GTK2.Notebook create( mapping|void props ); 
//! Create a W(Notebook) widget with no pages. 
//! 
//! 
 
int get_current_page( ); 
//! Returns the index of the currently selected page 
//! 
//! 
 
int get_group_id( ); 
//! Gets the current group identifier. 
//! 
//! 
 
GTK2.Widget get_menu_label( GTK2.Widget page ); 
//! Return the menu label widget. 
//! 
//! 
 
string get_menu_label_text( GTK2.Widget child ); 
//! Retrieves the text of the menu label for the page containing child. 
//! 
//! 
 
int get_n_pages( ); 
//! Get the number of pages. 
//! 
//! 
 
GTK2.Widget get_nth_page( int index ); 
//!  Returns the page for the specified index 
//! 
//! 
 
int get_scrollable( ); 
//! Returns whether the tab label area has arrows for scrolling. 
//! 
//! 
 
int get_show_border( ); 
//! Returns whether a bevel will be drawn around the pages. 
//! 
//! 
 
int get_show_tabs( ); 
//! Returns whether the tabs of the notebook are shown. 
//! 
//! 
 
int get_tab_detachable( GTK2.Widget child ); 
//! Returns whether the tab contents can be detached. 
//! 
//! 
 
GTK2.Widget get_tab_label( GTK2.Widget page ); 
//! Returns the tab label widget. 
//! 
//! 
 
string get_tab_label_text( GTK2.Widget child ); 
//! Retrieves the text of the tab label for the page containing child. 
//! 
//! 
 
int get_tab_pos( ); 
//! Gets the edge at which the tabs are located. 
//! 
//! 
 
int get_tab_reorderable( GTK2.Widget child ); 
//! Gets whether the tab can be reordered via drag and drop or not. 
//! 
//! 
 
GTK2.Notebook insert_page( GTK2.Widget contents, GTK2.Widget label, int pos ); 
//! Insert a page at the specified location, arguments as for 
//! append_page, but an aditional integer specifies the location. 
//! 
//! 
 
GTK2.Notebook insert_page_menu( GTK2.Widget contents, GTK2.Widget label, GTK2.Widget menu, int pos ); 
//! Insert a page at the specified location, arguments as for 
//! append_page_menu, but an additional integer specifies the location. 
//! 
//! 
 
GTK2.Notebook next_page( ); 
//! Go to the next page 
//! 
//! 
 
int page_num( GTK2.Widget widget ); 
//! Returns the index for the specified page. 
//! 
//! 
 
GTK2.Notebook popup_disable( ); 
//! Disable the popup menu (set with insert_page_menu). 
//! 
//! 
 
GTK2.Notebook popup_enable( ); 
//! Enable the popup menu (set with insert_page_menu). 
//! 
//! 
 
GTK2.Notebook prepend_page( GTK2.Widget contents, GTK2.Widget label ); 
//! Add a page at the end of the list of pages. The first argument is 
//! the contents of the page, the second argument is the label. 
//! 
//! 
 
GTK2.Notebook prepend_page_menu( GTK2.Widget contents, GTK2.Widget label, GTK2.Widget menu ); 
//! Add a new 'page' at the end of the list of pages. The first 
//! argument is the contents of the page, the second argument is the 
//! label, the third argument is a menu label widget. 
//! 
//! 
 
GTK2.Notebook prev_page( ); 
//! Go to the previous page 
//! 
//! 
 
mapping query_tab_label_packing( GTK2.Widget page ); 
//! Returns ([ "expand":expandp, "fill":fillp, "pack_type":type ]) 
//! 
//! 
 
GTK2.Notebook remove_page( int pos ); 
//! Remove a page. 
//! 
//! 
 
GTK2.Notebook reorder_child( GTK2.Widget child, int position ); 
//! Reorders the page containing child, so that it appears at 
//! position. 
//! 
//! 
 
GTK2.Notebook set_current_page( int pos ); 
//! Go to the specified page 
//! 
//! 
 
GTK2.Notebook set_group_id( int id ); 
//! Sets an group identifier for notebook; notebooks sharing the same group 
//! identifier will be able to exchange tabs via drag and drop. A notebook 
//! with group identifier -1 will not be able to exchange tabs with any other 
//! notebook. 
//! 
//! 
 
GTK2.Notebook set_menu_label( GTK2.Widget child, GTK2.Widget label ); 
//! Changes the menu label for the page containing child. 
//! 
//! 
 
GTK2.Notebook set_menu_label_text( GTK2.Widget child, string label_text ); 
//! Creates a new label with label_text sets it as the menu label. 
//! 
//! 
 
GTK2.Notebook set_scrollable( int scrollablep ); 
//! If true, add scrollbars if necessary. 
//! 
//! 
 
GTK2.Notebook set_show_border( int showborderp ); 
//! If true, show the borders around the contents and tabs. 
//! 
//! 
 
GTK2.Notebook set_show_tabs( int showtabsp ); 
//! If supplied with a true value, the tabs will be shown. Otherwise 
//! they will not be shown. The user will not be able to select the 
//! pages without them, but you can add 'next' and 'previous' buttons 
//! to create a wizard-line interface. 
//! 
//! 
 
GTK2.Notebook set_tab_label( GTK2.Widget child, GTK2.Widget label ); 
//! Changes the tab label for child. 
//! 
//! 
 
GTK2.Notebook set_tab_label_packing( GTK2.Widget child, int expand, int fill, int type ); 
//! Sets the packing parameters for the tab label of the page child. 
//! 
//! 
 
GTK2.Notebook set_tab_label_text( GTK2.Widget child, string title ); 
//! Creates a new label and sets it as the tab label for the page 
//! containing child. 
//! 
//! 
 
GTK2.Notebook set_tab_pos( int pos ); 
//! Sets the edge at which the tabs for switching pages in the 
//! notebook are drawn. 
//! One of @[POS_BOTTOM], @[POS_LEFT], @[POS_RIGHT] and @[POS_TOP] 
//! 
//!