This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author terry.reedy
Recipients gpolo, rtw, serhiy.storchaka, terry.reedy
Date 2015-10-23.01:09:42
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1445562584.81.0.465025582113.issue25464@psf.upfronthosting.co.za>
In-reply-to
Content
(Rob: FYI, a crash is something worse than just an exception.)

I know very little about tix, so I don't know whether the bug is really passing 'exists' or that not being accepted.  I think it is the latter.  The offending function in class HList is

    def header_exists(self,  col):
        return self.tk.call(self._w, 'header', 'exists', col)

There are also

    def indicator_exists(self,  entry):
        return self.tk.call (self._w, 'indicator', 'exists', entry)
    def info_exists(self, entry):
        return self.tk.call(self._w, 'info', 'exists', entry)
    def item_exists(self, entry, col):
        return self.tk.call(self._w, 'item', 'exists', entry, col)

This pattern, and the more general pattern

    def x_y(arg1, ...):
        return self.tk.call(self._w, 'x', 'y', arg1, ...)

suggests that header_exists is written correctly and that 'exists' is not the error.  The other accepted options, cget, configure, create, delete, and size are other options for y when x is 'header'. 

I don't know what an 'entry' must be, but this runs without error.
>>> root = tix.Tk()
>>> hl = tix.HList(root)
>>> hl.info_exists('')
'0'

http://tix.sourceforge.net/dist/current/man/html/TixCmd/tixHList.htm#M73
also suggests that 'exists is correct, since the tcl for this is "pathName header exists col", with 'exists', not 'exist'.

Still, it is possible that the attached patch is the best we can do, but then, if I am correct, a comment should be added that it is a bug workaround.

A test is really needed, but test_tix, added in 3.5, is vestigial and only tests that tix.Tk() works on Windows. Adding real tests would be a separate issue.  Serhiy, is this something that might be done or is tix considered passe'?
History
Date User Action Args
2015-10-23 01:09:44terry.reedysetrecipients: + terry.reedy, gpolo, serhiy.storchaka, rtw
2015-10-23 01:09:44terry.reedysetmessageid: <1445562584.81.0.465025582113.issue25464@psf.upfronthosting.co.za>
2015-10-23 01:09:44terry.reedylinkissue25464 messages
2015-10-23 01:09:42terry.reedycreate