]> SALOME platform Git repositories - tools/eficas.git/blob - Pmw/Pmw_1_2/demos/NoteBook_3.py
Salome HOME
Modif V6_4_°
[tools/eficas.git] / Pmw / Pmw_1_2 / demos / NoteBook_3.py
1 title = 'Pmw.NoteBook demonstration (with no tabs)'
2
3 # Import Pmw from this directory tree.
4 import sys
5 sys.path[:0] = ['../../..']
6
7 import Tkinter
8 import Pmw
9
10 # Reuse the NoteBook with tabs demo.
11 import NoteBook_2
12
13 class Demo(NoteBook_2.Demo):
14     def __init__(self, parent):
15         NoteBook_2.Demo.__init__(self, parent, withTabs = 0)
16
17 # Create demo in root window for testing.
18 if __name__ == '__main__':
19     root = Tkinter.Tk()
20     Pmw.initialise(root)
21     root.title(title)
22
23     widget = Demo(root)
24     exitButton = Tkinter.Button(root, text = 'Exit', command = root.destroy)
25     exitButton.pack()
26     root.mainloop()