# -*- mode: python; fill-column: 75; tab-width: 8; coding: iso-latin-1-unix -*- # Wrapped from /disk/dos/k/Tixapps/src/Widgets/SelectValue.tcl import Tkinter, Tix, ObjTix class TIDESelectValue(ObjTix.Widget,ObjTix.DialogShell): def __repr__ (self): return "" % self._w def __init__(self, master, name='', cnf={}, **kw): self.master = master self.tk = master.tk self.tk.eval('if {[info commands TIDESelectValue] == ""} {auto_load TIDESelectValue}') if kw: cnf = Tkinter._cnfmerge((cnf, kw)) static = ['options'] # This should be staticOptions, but I don't see why # you would ever want to use configure during creation. for x in self.tk.split(self.tk.eval('set TIDESelectValue(options)')): static.append(x[1:]) ObjTix.Widget.__init__(self, master, 'TIDESelectValue', static, cnf) def vSelectCommand (self, args): retval = self.tk.call(self._w, 'vSelectCommand', args) return retval def run (self, msg, elts='', title='Configure Value'): retval = self.tk.call(self._w, 'run', msg, elts, title) return retval # For Python >= 2.2.1 __slots__ = ['cFindList'] if __name__ == '__main__': root = Tix.Tk() # Call your toplevel here