We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
Page Index Toggle Pages: 1
Resize a window ? (Read 4126 times)
Resize a window ?
Sep 28th, 2007, 7:33pm
 
Hello,

I'd like to know how to be able to resize the window when you make an application !

thanks

(I read something on Processing for the first time last saturday and I'm already able to make (very) little programs !
wao !)
Re: Resize a window ?
Reply #1 - Sep 28th, 2007, 8:07pm
 
do you want resize it after it has been launched, or just want to change the size in the code?
Re: Resize a window ?
Reply #2 - Sep 29th, 2007, 4:33pm
 
something like this should do the trick:

size(w,h);
frame.setSize(w,h);

check out seltar's example in this thread. it uses the code above to change the window's size during runtime:
http://processing.org/discourse/yabb_beta/YaBB.cgi?board=Integrate;action=display;num=1147684168
Re: Resize a window ?
Reply #3 - Nov 19th, 2007, 10:46am
 
related:
I put an example online with a resizable applet
http://www.metaportaldermedienpolemik.net/processing.org/applet_resize/

Walter
Re: Resize a window ?
Reply #4 - Nov 19th, 2007, 2:07pm
 
nice! thanks for sharing.

frank.
Re: Resize a window ?
Reply #5 - Nov 19th, 2007, 2:19pm
 
hi,

looks promising, but unfortunately does not work on Mac Firefox and Safari. The box resizes, but if I release the mouse the applet appears with it's initial size. The html below it stays resized, covered by the applet...
Re: Resize a window ?
Reply #6 - Nov 20th, 2007, 9:34am
 
extrapixel wrote on Nov 19th, 2007, 2:19pm:
looks promising, but unfortunately does not work on Mac Firefox and Safari. The box resizes, but if I release the mouse the applet appears with it's initial size. The html below it stays resized, covered by the applet...


I'll have a look at it when I'm at my mac at home. So far it worked in Ubuntu(Firefox) and WinXP(Firefox/IE6).

I started a new thread for this:
http://processing.org/discourse/yabb_beta/YaBB.cgi?num=1195547866/0#0
Re: Resize a window ?
Reply #7 - Feb 15th, 2010, 7:50am
 
is there a way to resize a window in presentation mode (shift play)?

Re: Resize a window ?
Reply #8 - Feb 15th, 2010, 11:18am
 
as far as i know if on fullscreen (present mode) the window-size is the same as your screen resolution. so, do you want to change your screen resolution? otherwise that would not make sense to me...
Re: Resize a window ?
Reply #9 - Feb 15th, 2010, 12:06pm
 
no, what i mean is that in presentation mode there is a grey area around your sketch that fills up the gap between the sketch size and the screen resolution.
now when i resize the sketch while it runs (via frame.setSize(w,h)) it doesn't work at all, i just get some grey fragments and the sketch itself is gone.
Re: Resize a window ?
Reply #10 - Feb 15th, 2010, 12:17pm
 
ok maybe i just don't understand why you want to resize the sketch in present mode Smiley if its just about the grey borders, why not draw them yourself?
Page Index Toggle Pages: 1