?
Solved

Modify the position and dimensions for windows in the "Maximized" state

Posted on 2015-02-08
15
Medium Priority
?
150 Views
Last Modified: 2015-02-25
Hello,

Is there a way to change the maximize dimensions in Windows (7)?

As far as I know, there are three automatic screen-position settings for any given window:

        1) Maximize
        2) Restore
        3) Minimize

I'm wondering if there is a way to modify the position & dimensions for a window when the Maximize button is clicked (or when the title bar is double-clicked).

For example, the monitor I'm currently using measures 1920 x 1200 pixels (20" x 12.5") and therefore, when maximized, a window takes on those same dimensions. But suppose you want to modify the "maximize" effect so the window, in its maximized position, measures 16" x 12.5" so the far right 4" of the screen are open.

I know that some programs like MS OneNote cause this behavior (for instance, if the OneNote window is positioned in a certain way at the right end of the screen, maximizing another window will extend it right up to the edge of OneNote but not much), but is there a way to manipulate the maximize position via user input?

Thanks
0
Comment
Question by:WeThotUWasAToad
  • 4
  • 4
  • 3
  • +3
15 Comments
 
LVL 12

Expert Comment

by:FarWest
ID: 40597471
this is program specific behavior if you want to do this for a software program you built then you can interrupt maximizing event and set your own position, size
otherwise you need a program that hook to windows messaging system (the one used by os for marshaling windows events and commands ) and inspect the event to handle it
0
 
LVL 11

Accepted Solution

by:
Wilder1626 earned 2000 total points
ID: 40597476
A program that can handle this is called MaxMax. You will be able to customize your window size as you like.

MaxMax software

Or

MaxMax Software
0
 
LVL 57

Expert Comment

by:Joe Winograd, EE MVE 2015&2016
ID: 40597509
Hi We...Toad,

A program can do this, but I'm not aware of a way to do it for an arbitrary window in W7. For example, here's an explanation of how a Visual Basic program can limit a window's maximum size (and the minimum size, too):
http://support.microsoft.com/kb/185733

But unless the app is programmed for it, there's no way in native W7 to do this. However, there are third-party utilities that claim to be able to do it. I haven't tried them, so I can't endorse one for you. One that pops up in a web search that seems to be worth a look is MaxMax:
http://lifehacker.com/5623681/maxmax-customizes-windows-default-maximize-size

The link in that article no longer works, because the developer took down his site, but here's a site that still has it:
http://www.ghacks.net/2010/08/25/change-the-maximize-window-size/

I want to say again that I haven't tried it so you're on your own to evaluate it.

Another approach is to write an AutoHotkey program to do it (I mention this because I know you use AHK). You could have an AHK persistent script look for various windows (via IfWinExist and then WinActivate) and then size each window that it finds via the WinSet command (with the W, H, and X-Y parameters). If you're not familiar with how to do this in AHK, I'll be happy to work with you on it. Regards, Joe
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 11

Expert Comment

by:Wilder1626
ID: 40597523
Hi Joe Winograd,

Always good to see you on topics. Always keeping learning, just by reading your posts.

I used to have MaxMax before. I can tell that it was working for me.

WeThotUWasAToad, you can give it a try. let use know if it works. I gave you 2 links on my previous post were you can download it.
0
 
LVL 88

Expert Comment

by:rindi
ID: 40597527
A "Maximized" window is always full-screen, so it takes up all your display. Naturally when something uses the full-screen, there is no point and no way to change the size or position, or it won't be maximized anymore. This is by definition of maximize.
0
 
LVL 57

Expert Comment

by:Joe Winograd, EE MVE 2015&2016
ID: 40597556
> A "Maximized" window is always full-screen, so it takes up all your display.

Not true. Microsoft allows a program to define the size of a "Maximized" window (a "Minimized" one, too). The article I posted earlier shows how a VB program can do it. Regards, Joe
0
 
LVL 88

Expert Comment

by:rindi
ID: 40597569
But then it is something else, not maximized anymore. Since this is something of VB, it probably has to do with the history of VB, which started off with DOS and really had nothing to do with a Windows Software yet. For me Maximized is either "On" or "Off", there is nothing in between. Probably in VB it is just a wrong definition.
0
 
LVL 57

Expert Comment

by:Joe Winograd, EE MVE 2015&2016
ID: 40597587
It's semantics. Depends on your definition of "maximized". You're defining it as taking up "the full-screen". But Windows has definitions for maximizing, minimizing, and restoring a window — and such definitions include that a maximized window does not necessarily have to take up "the full-screen". Regards, Joe
0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 40597615
@Rindi,

A window in the "Maximized" state will take up the "Working Area" of the Desktop, not the full screen:
https://msdn.microsoft.com/en-us/library/system.windows.forms.screen.workingarea(v=vs.110).aspx

The working area is the desktop area of the display, excluding taskbars, docked windows, and docked tool bars.

Here is the documentation for AppBars, which fall under the category of docked tool bars:
https://msdn.microsoft.com/en-us/library/windows/desktop/cc144177%28v=vs.85%29.aspx

An application desktop toolbar (also called an appbar) is a window that is similar to the Windows taskbar. It is anchored to an edge of the screen, and it typically contains buttons that give the user quick access to other applications and windows. The system prevents other applications from using the desktop area used by an appbar. Any number of appbars can exist on the desktop at any given time.
0
 

Author Comment

by:WeThotUWasAToad
ID: 40632089
A program that can handle this is called MaxMax. You will be able to customize your window size as you like.

MaxMax software

Thanks. This is exactly what I was hoping to find.
0
 
LVL 11

Expert Comment

by:Wilder1626
ID: 40632092
I'm glad  this is what your were searching for.

Just make sure to accept the solution if this solution works for you.
0
 

Author Comment

by:WeThotUWasAToad
ID: 40632104
Another approach is to write an AutoHotkey program…
Joe, as usual, you are right on target — well actually, almost on target.

I've got an AHK script which creates a ButtonBar and enables the creation of as many buttons of whatever shape or size you want. It's essentially a way to to replace keyboard hotkeys with GUI triggers. In other words, any AHK script can be set to run in response to the click of a button rather than a keyboard entry.

Now with MaxMax (which seems to work great), my intent is to play around with button bars on all for sides of a "maximized" window. I'm optimistic that, with as many scripts as I'm always using, the need to remember keyboard hotkeys will be a thing of the past.

:)
0
 

Author Closing Comment

by:WeThotUWasAToad
ID: 40632106
Thanks!
0
 
LVL 11

Expert Comment

by:Wilder1626
ID: 40632110
We are always glad to help :-)
0
 
LVL 57

Expert Comment

by:Joe Winograd, EE MVE 2015&2016
ID: 40632116
> Joe, as usual, you are right on target — well actually, almost on target.

Thanks — I appreciate the compliment — even the "almost" part of it. :)

Sounds like a fascinating approach that you're taking with the AHK-created ButtonBar. Keep us posted on your progress with it. Regards,  Joe
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is an article on how to answer questions, earn points and become an expert.
This is an update to some code that someone else posted on Experts Exchange. It is an alternate approach, I think a little easier to use, & makes sure that things like the Task Bar will update.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

621 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question