Tkinter: centering windows on screen

Kevin Cazabon kcazabon at
Sun Apr 9 16:39:32 EDT 2000

Thanks Fred... It'll work, but that means that I'll actually have to do some
work to get it positioned right!  q:]

I guessed it wouldn't be as easy as  Oh well...

Is there a Python or Tkinter call to return the screen resolution?  I know I
can probably get it through Win32, but I'd rather make it cross-platform...
I'll do some digging.


"Fredrik Lundh" <effbot at> wrote in message
news:xR4I4.274$rc9.188784640 at
> Kilian Lorenz <kilian.lorenz at> wrote:
> > >> that works but doesn't help me much because I'm interested in the
> > >> return value. So I would really like to know how to call Tk commands
> > >> from within Python because .... blah blah
> >
> > Now I also found out how this works ... pretty easy with
> > <widget><command>, <parameter>, <next parameter> ...)
> >
> > You just have to browse and get the answers to all your
> > questions !  :)
> if you browsed the source, how come you didn't find the
> corresponding Tkinter methods?
> windows geometry:
> .htm
> file dialogues:
> (direct pointers to the current draft; official version at
> will be synchronized next week).
> </F>

More information about the Python-list mailing list