GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — Source-Code-from-Tutorials/PythonGTK/Examples/09_notebook.py at master · scibilo/Source-Code-from-Tutorials Expand file tree/ Copy path09_notebook.pyMore file actions 29 lines (22 loc) · 928 Bytes / Copy path09_notebook.pyFile metadata and controls29 lines (22 loc) · 928 Bytes 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 from gi.repository import Gtk class MainWindow(Gtk.Window): def __init__(self): Gtk.Window.__init__(self, title="Notebook Demo") self.set_border_width(10) self.notebook = Gtk.Notebook() self.add(self.notebook) # First regular tab self.page1 = Gtk.Box() self.page1.set_border_width(10) self.page1.add(Gtk.Label('Here is the content of the first section.')) self.notebook.append_page(self.page1, Gtk.Label('First Tab')) # Second star icon tab self.page2 = Gtk.Box() self.page2.set_border_width(10) self.page2.add(Gtk.Label('This is what you will see when you click the star.')) icon = Gtk.Image.new_from_icon_name("gnome-dev-cdrom-audio", Gtk.IconSize.MENU) self.notebook.append_page(self.page2, icon) window = MainWindow() window.connect("delete-event", Gtk.main_quit) window.show_all() Gtk.main() |
| You are visitor 01402792 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |