| Author |
A Busy Developer's Guide to Tcl/Tk 8.5
|
|
| Mark Roseman 2007-12-21, 7:16 pm |
| I've updated my overview of what developers should know about 8.5 to
bring it up to date with this w 's 8.5.0 release.
http://www.markroseman.com/tcl/guide85.html
Hope this is helpful - comments and suggestions appreciated.
Mark
| |
| Donal K. Fellows 2007-12-21, 7:16 pm |
| Mark Roseman wrote:
> I've updated my overview of what developers should know about 8.5 to
> bring it up to date with this w 's 8.5.0 release.
>
> http://www.markroseman.com/tcl/guide85.html
>
> Hope this is helpful - comments and suggestions appreciated.
You missed [wm manage], which is great for going that extra mile with
toolbars.
Donal.
| |
| Keith Nash 2007-12-21, 7:16 pm |
| Donal K. Fellows wrote:
> You missed [wm manage], which is great for going that extra mile with
> toolbars.
I hadn't spotted it either - I've just tried it out. It's a fantastic
facility! I'm trying to spot the differences between a toplevel and a
frame:
(1) A toplevel is created in the mapped and wm manage'd state;
A frame is created unmapped and in the wm forget'd state
(2) By default a toplevel has class Toplevel, unless it is the main
window "." when it has an application-specific class;
By default a frame has class Frame.
(3) A toplevel has additional subcommands -menu, -screen, -use
Are there any other differences?
Bindtags seem to be handled in the same way for both toplevels and frames,
in particular the bindtag that refers to "this window's toplevel" is
updated when wm manage/forget and geometry management change a window's
toplevel.
Keith.
| |
|
| Dnia 21.12.2007 Donal K. Fellows <donal.k.fellows@man.ac.uk> napisał/a:
> You missed [wm manage], which is great for going that extra mile with
> toolbars.
What "great" is about "wm manage"? Found in the docs: "The widget specified
will become a stand alone top-level window. The window will be decorated
with the window managers title bar, etc.".
So I made something like this:
pack [button .b -text "Hallo"]
wm manage .b
....and then button ".b"... just disappeared. And although tclsh answers on
the repeat of "pack .b" command:
can't pack ".b": it's a top-level window
while evaluating {pack .b}
....can't see .b anywhere on the desktop.
--
ZB
| |
| Keith Nash 2007-12-21, 7:16 pm |
| ZB wrote:
> Dnia 21.12.2007 Donal K. Fellows <donal.k.fellows@man.ac.uk> napisaĆ/a:
>
>
> What "great" is about "wm manage"? Found in the docs: "The widget
> specified will become a stand alone top-level window. The window will be
> decorated with the window managers title bar, etc.".
>
> So I made something like this:
>
> pack [button .b -text "Hallo"]
> wm manage .b
>
> ...and then button ".b"... just disappeared. And although tclsh answers on
> the repeat of "pack .b" command:
>
> can't pack ".b": it's a top-level window
> while evaluating {pack .b}
>
> ...can't see .b anywhere on the desktop.
You need to do:
wm deiconify .b
"wm state .b" returns "iconic" before this operation (though on my system
there is no icon - it behaves as if the window is withdrawn).
Keith.
| |
|
| Dnia 21.12.2007 Keith Nash <kjn9@citizenearth.com> napisał/a:
> You need to do:
> wm deiconify .b
>
> "wm state .b" returns "iconic" before this operation (though on my system
> there is no icon - it behaves as if the window is withdrawn).
Yes, so is on my system. There wasn't even any icon present, nor the related
window-tab on the taskbar.
Yes, after deiconification it finally appeared.
--
ZB
| |
| anoved 2007-12-23, 7:21 pm |
| On Dec 21, 9:19 am, Mark Roseman <m...@markroseman.com> wrote:
> http://www.markroseman.com/tcl/guide85.html
>
> Hope this is helpful - comments and suggestions appreciated.
It is helpful.
Shouldn't the first line of the "processarray" procedure in the second
pre-8.5 dictionary example be
array set a $arraydata
instead of
array set a [array get $arraydata]
since the array was already serialized when passed to processarray?
Anyway, thanks for the nice overview!
Jim
| |
|
|
|
|