OESF | ELSI | pdaXrom | OpenZaurus | Zaurus Themes | Community Links | Ibiblio

IPB

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Pdaxrom, Tcl/tk And Maximized Top Level Window
ivanhoe
post May 29 2007, 12:41 AM
Post #1





Group: Members
Posts: 4
Joined: 15-March 05
Member No.: 6,632



Hi,

I'm writing a small app in Tcl/Tk for pdaxrom. I want a main (top level) window to be always maximized in both portrait and landscape screen orientations. Is there any simple way to do it (without hacking Tk sources etc)?

Currently I've found that "wm geometry . [winfo screenwidth .]x[winfo screenheight]+0+0" maximizes main window at start, but I don't know how to catch screen rotation within Tk and get proper geometry to resize my window.
Go to the top of the page
 
+Quote Post
jfv
post May 29 2007, 06:26 AM
Post #2





Group: Members
Posts: 438
Joined: 24-June 03
Member No.: 202



This is a bad hack, but

while {1} {
wm geometry . [winfo screenwidth .]x[winfo screenheight .]+0+0
after 1000
update idletasks
}

might have the desired effect. You can try also deleting and redrawing the window but that might be overkill.
Go to the top of the page
 
+Quote Post
ivanhoe
post May 30 2007, 09:59 PM
Post #3





Group: Members
Posts: 4
Joined: 15-March 05
Member No.: 6,632



QUOTE(jfv @ May 29 2007, 06:26 PM)
This is a bad hack, but
...
might have the desired effect. You can try also deleting and redrawing the window but that might be overkill.


Unfortunately, it doesn't work. "screenwidth" and "screenheight" remain the same from start of my app.
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 24th November 2014 - 06:01 AM