Re: ttk::checkbutton - I think, it's a bug
- From: Joe English <jenglish@xxxxxxxxxxxxx>
- Date: 10 Feb 2008 02:43:03 GMT
Óscar Fuentes wrote:
If every data-entry widget had a getter with the same name, you could
read all data on a form without resorting to arrays, garbage collection,
variables or whatever. Just the form, iterate over its widgets, get the
value for those widgets that implement the getter. Done.
Conversely, if every data entry widget in a form is
linked to an array entry (with a dedicated array for
each form), you can read all the data on a form with
a single statement: [array get $formVar]. And you can
update all the data on a form with a single call:
[array set $formVar $dictionary].
(An aside: the ttk::checkbutton widget had a bug
for a long time whereby it basically did not work
at all unless -variable was specified [#1257319].
It simply never occurred to me that anyone would
ever use a checkbutton *without* a linked variable
(and it was a long time before anyone noticed this bug).
Linked variables are, to me, the #1 feature that
makes Tk so pleasant to use. They handle a huge
chunk of the work necessary to decouple the GUI from
the "business logic". Until this thread, I would
not have suspected that anyone felt otherwise :-)
--JE
.
- Follow-Ups:
- References:
- ttk::checkbutton - I think, it's a bug
- From: ZB
- Re: ttk::checkbutton - I think, it's a bug
- From: Gerald W. Lester
- Re: ttk::checkbutton - I think, it's a bug
- From: ZB
- Re: ttk::checkbutton - I think, it's a bug
- From: Gerry Snyder
- Re: ttk::checkbutton - I think, it's a bug
- From: Óscar Fuentes
- Re: ttk::checkbutton - I think, it's a bug
- From: Bryan Oakley
- Re: ttk::checkbutton - I think, it's a bug
- From: Óscar Fuentes
- Re: ttk::checkbutton - I think, it's a bug
- From: Bryan Oakley
- Re: ttk::checkbutton - I think, it's a bug
- From: Óscar Fuentes
- Re: ttk::checkbutton - I think, it's a bug
- From: Bryan Oakley
- Re: ttk::checkbutton - I think, it's a bug
- From: ZB
- Re: ttk::checkbutton - I think, it's a bug
- From: Bryan Oakley
- Re: ttk::checkbutton - I think, it's a bug
- From: Óscar Fuentes
- ttk::checkbutton - I think, it's a bug
- Prev by Date: Re: ttk::checkbutton - I think, it's a bug
- Next by Date: Re: ttk::checkbutton - I think, it's a bug
- Previous by thread: Re: ttk::checkbutton - I think, it's a bug
- Next by thread: Re: ttk::checkbutton - I think, it's a bug
- Index(es):