demo_menu.py
changeset 42 0224ce40792f
parent 41 37b7dfc3eae6
child 45 43b2279b06e1
equal deleted inserted replaced
41:37b7dfc3eae6 42:0224ce40792f
     2 # -*- coding: utf-8 -*-
     2 # -*- coding: utf-8 -*-
     3 
     3 
     4 import locale
     4 import locale
     5 locale.setlocale(locale.LC_ALL, '')
     5 locale.setlocale(locale.LC_ALL, '')
     6 
     6 
     7 from tuikit import *
     7 from tuikit import Application, MenuBar, Menu, Window, VerticalLayout
     8 
     8 
     9 
     9 
    10 class MyApplication(Application):
    10 class MyApplication(Application):
    11     def __init__(self):
    11     def __init__(self):
    12         Application.__init__(self)
    12         Application.__init__(self)
    46             ('File', filemenu),
    46             ('File', filemenu),
    47             ('Edit', editmenu),
    47             ('Edit', editmenu),
    48             ('Help', helpmenu),
    48             ('Help', helpmenu),
    49             ])
    49             ])
    50 
    50 
    51         vert = VerticalLayout()
    51         self.top.layout = VerticalLayout()
    52         self.top.layout(vert)
       
    53 
    52 
    54 
    53 
    55         #button = Button('click!')
    54         #button = Button('click!')
    56         #win.add(button)
    55         #win.add(button)
    57         #button.x = 10
    56         #button.x = 10