Gtk Notebook
GtkNotebook
-
Open up tutorial-3.glade and save as tutorial-5.glade. Now remove the label from the center of the vertical container and add a Notebook container.
Your project should look like this now.
-
Add a label to each tab in the notebook. If the tab is empty it will not show up when you run the program. Note you have to click on the edge of the tab to select the tab.
Your project should look like this now.
-
Now double click on File > New on your Menu Bar to select the gtk_new menu item. Change the Name: to gtk_new.
-
In the Signals tab add the on_gtk_new_activate signal handler to the activate signal and don’t forget to press the enter key after picking it in the drop down box. If you don’t see the drop down box you may have to scroll to the right a little.
Your project should look like this now.
-
Select the notebook and add the on_notebook1_switch_page signal handler.
Your project should look like this now.
Save the project as tutorial-5.glade and we are done with the glade part.
To ask questions about this tutorial use the Feedback Forum