No BSD License  

Highlights from
api_showwindow

5.0

5.0 | 6 ratings Rate this file 4 Downloads (last 30 days) File Size: 25.94 KB File ID: #2041

api_showwindow

by Mihai Moldovan

 

24 Jul 2002 (Updated 24 Jul 2002)

The function warps the WIN32 ShowWindow API in User32.dll.

| Watch this File

File Information
Description

When using MATLAB on windows platforms one could write MEX files to access the WIN32 API functions. However such a tutorial is difficult to find.

I decided to post an example with a commented C-MEX file that will demonstrate how to accurately find the windows handle of a MATLAB figure window and then do some API command on it.

For simplicity I selected the 'ShowWindow' API because it can be used to solve the 'common' figure maximization problem. (maximizefigure.m sample included)

Acknowledgements
This submission has inspired the following:
maxfig, WindowAPI
MATLAB release MATLAB 6.1 (R12.1)
Other requirements Windows Platform
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (7)
25 Jul 2002 R M

Great! Really useful just for the maximize window fix. I bet there's some other cool stuff you could do with this wrapper too.

Humm...

28 Nov 2002 Jocke K

Excellent! Easy to use.

22 Jan 2003 Yuval Cohen

Excellent piece of code. Much better than my poor attempts to resizes the figure according to the screen size property ( i.e. "get(0,'ScreenSize')" ).

03 Apr 2003 Alex V

Thanks for this code. Very helpful.

12 Apr 2003 Nitesh Bhandari

Great, I wanted this for over a year, and it was hard to come to. This makes Matlab even more and more intersting to me

22 May 2003 Matthew Simoneau

http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=3434

06 Nov 2011 NK University

Thanks for your kindly work! While it may not be used in Matlab ver > 7!!!

Please login to add a comment or rating.
Tag Activity for this File
Tag Applied By Date/Time
gui tools Mihai Moldovan 22 Oct 2008 06:46:49
example Mihai Moldovan 22 Oct 2008 06:46:49
gui Mihai Moldovan 22 Oct 2008 06:46:49
windows api Mihai Moldovan 22 Oct 2008 06:46:49
tutorial Mihai Moldovan 22 Oct 2008 06:46:49
maximize Mihai Moldovan 22 Oct 2008 06:46:49

Contact us at files@mathworks.com