[Tkinter-discuss] setting a windows starting screen position

Guilherme Polo ggpolo at gmail.com
Tue Jul 15 04:11:37 CEST 2008


On Mon, Jul 14, 2008 at 10:52 PM, Alexnb <alexnbryan at gmail.com> wrote:
>
> I am wondering how to set the window's starting screen postion. I guess the
> default is the top left, or some coordinate in the top left. But i want my
> app to start in the center of the screen. How would I ot about doing that?

You would use wm_geometry, winfo_screenheight, winfo_screenwidth,
width and height methods on your toplevel. Anything else I say will
take out all the fun. Just a hint: you can set a position, without
setting the widget size, using wm_geometry and calling it with
something like ('+xpos+ypos').

> --
> View this message in context: http://www.nabble.com/setting-a-windows-starting-screen-position-tp18456640p18456640.html
> Sent from the Python - tkinter-discuss mailing list archive at Nabble.com.
>
> _______________________________________________
> Tkinter-discuss mailing list
> Tkinter-discuss at python.org
> http://mail.python.org/mailman/listinfo/tkinter-discuss
>



-- 
-- Guilherme H. Polo Goncalves


More information about the Tkinter-discuss mailing list