On Mon, Sep 17, 2012 at 3:12 PM, <a href="mailto:marcofoc@libero.it" target="_blank">marcofoc@libero.it</a> <<a href="mailto:marcofoc@libero.it" target="_blank">marcofoc@libero.it</a>> wrote:<br>> Ciao a tutti!<br>

<br>ciao Marco<br><br>> Con il fine di rilevare in automatico le dimensione del monitor, uso questo<br>
> semplice codice:<br>><br>> import gtk<br>> w = gtk.gdk.get_default_root_window()<br>> p = gtk.gdk.atom_intern('_NET_WORKAREA')<br>> height, width = w.property_get(p)[2][2:4]<br><br>urca, è come sparare a un piccione con un bazooka :)<br>


<br>> in ambiente Linux (ovviamente) funziona.<br>> In ambiente Windows, mi ritorna un errore l'ultima riga.<br>> Provate anche voi per cortesia?<br><br>usa:<br><a href="http://www.pygtk.org/docs/pygtk/class-gdkscreen.html" target="_blank">http://www.pygtk.org/docs/pygtk/class-gdkscreen.html</a><br>


<br>in particolare:<br><a href="http://www.pygtk.org/docs/pygtk/class-gdkscreen.html#method-gdkscreen--get-width" target="_blank">http://www.pygtk.org/docs/pygtk/class-gdkscreen.html#method-gdkscreen--get-width</a><br><a href="http://www.pygtk.org/docs/pygtk/class-gdkscreen.html#method-gdkscreen--get-height" target="_blank">http://www.pygtk.org/docs/pygtk/class-gdkscreen.html#method-gdkscreen--get-height</a><br>


<br>ciao<br>-- <br>Gian Mario Tagliaretti<br>GNOME Foundation member<br><a href="mailto:gianmt@gnome.org" target="_blank">gianmt@gnome.org</a>