PATH:
usr
/
lib64
/
python2.7
/
Demo
/
tkinter
/
ttk
"""Sample taken from: http://www.tkdocs.com/tutorial/morewidgets.html and converted to Python, mainly to demonstrate xscrollcommand option. grid [tk::listbox .l -yscrollcommand ".s set" -height 5] -column 0 -row 0 -sticky nwes grid [ttk::scrollbar .s -command ".l yview" -orient vertical] -column 1 -row 0 -sticky ns grid [ttk::label .stat -text "Status message here" -anchor w] -column 0 -row 1 -sticky we grid [ttk::sizegrip .sz] -column 1 -row 1 -sticky se grid columnconfigure . 0 -weight 1; grid rowconfigure . 0 -weight 1 for {set i 0} {$i<100} {incr i} { .l insert end "Line $i of 100" } """ import Tkinter import ttk root = Tkinter.Tk() l = Tkinter.Listbox(height=5) l.grid(column=0, row=0, sticky='nwes') s = ttk.Scrollbar(command=l.yview, orient='vertical') l['yscrollcommand'] = s.set s.grid(column=1, row=0, sticky="ns") stat = ttk.Label(text="Status message here", anchor='w') stat.grid(column=0, row=1, sticky='we') sz = ttk.Sizegrip() sz.grid(column=1, row=1, sticky='se') root.grid_columnconfigure(0, weight=1) root.grid_rowconfigure(0, weight=1) for i in range(100): l.insert('end', "Line %d of 100" % i) root.mainloop()
[-] plastik_theme.pyo
[edit]
[-] roundframe.pyo
[edit]
[-] mac_searchentry.pyc
[edit]
[+]
..
[-] plastik_theme.pyc
[edit]
[-] mac_searchentry.py
[edit]
[-] widget_state.pyc
[edit]
[+]
img
[-] dirbrowser.pyc
[edit]
[-] widget_state.py
[edit]
[-] theme_selector.pyo
[edit]
[-] plastik_theme.py
[edit]
[-] theme_selector.pyc
[edit]
[-] notebook_closebtn.py
[edit]
[-] treeview_multicolumn.pyo
[edit]
[-] combo_themes.pyc
[edit]
[-] theme_selector.py
[edit]
[-] widget_state.pyo
[edit]
[-] notebook_closebtn.pyc
[edit]
[-] notebook_closebtn.pyo
[edit]
[-] roundframe.pyc
[edit]
[-] listbox_scrollcmd.pyo
[edit]
[-] ttkcalendar.pyc
[edit]
[-] treeview_multicolumn.pyc
[edit]
[-] treeview_multicolumn.py
[edit]
[-] roundframe.py
[edit]
[-] combo_themes.py
[edit]
[-] listbox_scrollcmd.pyc
[edit]
[-] combo_themes.pyo
[edit]
[-] dirbrowser.py
[edit]
[-] ttkcalendar.py
[edit]
[-] mac_searchentry.pyo
[edit]
[-] ttkcalendar.pyo
[edit]
[-] listbox_scrollcmd.py
[edit]
[-] dirbrowser.pyo
[edit]