[Tkinter-discuss] Multiple displays/monitors?

Bob Greschke bob at passcal.nmt.edu
Fri Jan 19 20:53:48 CET 2007


Some of my programs start up and initially size themselves to, for  
example, 80% of the display height and width (usually because they  
are going to be graphing something).  That works 100% of the time  
until someone has multiple monitors then winfo_screenheight() and  
width() get misleading.  They seem to return the max dimensions (width 
+width and largest height), which isn't so bad if the two monitors  
are really the same, but with things like Mac laptops and Cinema  
displays it is usually not even close.

Is there a way to find out about multiple monitors through Tkinter?   
I played with a bunch of the winfo methods, but didn't figure  
anything out.  ALL :) I want to do is get the dimensions of the two  
(or more) displays and start the program in the center of the larger  
of the two for lack of a better plan.

Thanks!

Bob



More information about the Tkinter-discuss mailing list