[Tkinter-discuss] Strange 'tate' option in ttk.Treeview.heading

Jeff Epler jepler at unpythonic.net
Thu Apr 11 14:32:40 CEST 2013


This is an upstream bug in Tk which appears to still be present in their
development version.  There's supposed to be a "-state" property of
treeview columns, but the "-" is missing.  Python always removes the
first character in its configure-type interfaces, so you get "tate"

Compare the definition of "-text" to "state" at lines 296 and 308:
http://tktoolkit.cvs.sourceforge.net/viewvc/tktoolkit/tk/generic/ttk/ttkTreeview.c?revision=1.41&view=markup#l295

$ wish8.5
% ttk::treeview .t -columns A
.t
% .t heading 0
-text {} -image {} -anchor center -command {} state {}
% .t heading 0 -state {}
unknown option "-state"
% .t heading 0 state {}
% 

I did not immediately find a bug about this in the tktoolkit bug
tracker.  Please consider filing one if you hope for it to be fixed.
http://sourceforge.net/search/?group_id=12997&type_of_search=artifact&group_artifact_id=112997&limit=25&q=treeview

Jeff


More information about the Tkinter-discuss mailing list