No subject

Wed Mar 18 03:15:45 PDT 2009

"To make a window with none of the normal window decoration (titlebars,
borders and so on), you can use the overrideredirect method with a true

Be careful though; you won't be able to move the window on the screen once
it is drawn. If you forgot to put an Exit button on it, you won't be able
to quit the application gracefully.
This is a way to make a splash screen (a screen that shows up as your
application is loading.
Calling overrideredirect with no arguments returns the current value (1 or
Calling overrideredirect again with a 0 value will not turn decorations
back on once the window has been displayed.

I hope this helps.

Yossi Itzkovich
mailto:Yossi.Itzkovich at
Phone : 03-9266147     Fax: 03-9266200
Mobile:  055-786147

                      Oron Peled                                                                                                  
                      <oron at         To:      perl at                                                          
                      il>                      cc:      yarongo at                                                     
                      Sent by:                 Subject: Re: [Perl] Perl/Tk widget "locking"                                       
                      perl-admin at perl.                                                                                            
                      02/16/2003 23:25                                                                                            
                      Please respond                                                                                              
                      to perl                                                                                                     

On Sun, 16 Feb 2003 17:06:31 +0200
Yaron Golan <yarongo at> wrote:
> how do you "lock" a widget?

What you really look for is called "mouse grab" in X-Window-System.
There is a:
        "local grab" - meaning that no other window of the *same*
                       application may be selected
        "global grab" - meaning that other window of *any* application
                        may be selected

So in perl/Tk you use:

perldoc grab for more details.

> e.g. I have an error message for the user, and I do not wish him to
> move/minimize it and continue working.

Limiting just move/minimize/iconize etc, may be done by playing with
window-manager hints. I'm not sure though how you interface with it
directly from Tk.  I browsed in the doc and code for and
(two probable places) and haven't found the right method. Anybody else?

Oron Peled                             Voice/Fax: +972-4-8228492
oron at        

"Unix is simple. It just takes a genius to understand its simplicity"
             (Dennis Ritchie)
Perl mailing list
Perl at


More information about the Perl mailing list