Issue 1259434: Tix CheckList 'radio' option cannot be changed (original) (raw)
The 'radio' option to the Tix.CheckList widget cannot be set. Attempting to change the option during widget creation results in the following error:
_tkinter.TclError: cannot assigned to static variable "-radio"
The radio option is declared static in the Tix tcl library, and must be set at widget creation time. The radio option is not included in the list of static options passed to TixWidget.init from CheckList.init in file Tix.py.
Solution:
Add 'radio' to the list of static options passed to TixWidget.init in Tix.py. Output from diff -C 1:
*** 1562,1564 **** TixWidget.init(self, master, 'tixCheckList', ! ['options'], cnf, kw) self.subwidget_list['hlist'] = _dummyHList(self, 'hlist') --- 1562,1564 ---- TixWidget.init(self, master, 'tixCheckList', ! ['options','radio'], cnf, kw) self.subwidget_list['hlist'] = _dummyHList(self, 'hlist')