Using code to maximise a window

Deploying to Windows? Utilizing VB Script execution? This is the place to ask Windows-specific questions.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
andyh1234
Posts: 476
Joined: Mon Aug 13, 2007 4:44 pm
Contact:

Using code to maximise a window

Post by andyh1234 » Sat Nov 19, 2011 3:33 pm

Is there a line of code that will force a stack to enter the 'maximised' window state?

I can set the stack to the full screen by using...

set the rect of this stack to the working screenRect

however, this puts the the menu bar is at the very top and the title bar is off the top of the screen on Windows.

If its possible just to send the stack a maximise command this would be easier!

Andy

BvG
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 1239
Joined: Sat Apr 08, 2006 1:10 pm
Contact:

Re: Using code to maximise a window

Post by BvG » Sat Nov 19, 2011 7:01 pm

There's no such thing in LC. You can use fullscreen, but of course that's not what you really want.

Now, that part of your stack is offscreen when you use the working screenrect sounds like a bug (as long as you don't have other resize code interfering of course). Also note that the working screenrect in the IDE is not the same as for standalones.

After testing the following code, I can replicate your problem in LC 5.0 on my Mac:

Code: Select all

set the rect of this stack to the working screenRect
I made a bug report.
Various teststacks and stuff:
http://bjoernke.com

Chat with other RunRev developers:
chat.freenode.net:6666 #livecode

andyh1234
Posts: 476
Joined: Mon Aug 13, 2007 4:44 pm
Contact:

Re: Using code to maximise a window

Post by andyh1234 » Sat Nov 19, 2011 11:07 pm

Thanks, I didnt think of it as a bug as I guessed it might be neat to hide the title bar if the app were to be used in a kiosk style app, but then I would also set the app up with no title bar.

Ill add a vote on the bug report.

Thanks

Andy

Post Reply