1. Get
Scrsz = get (0, 'screensize'); % displays the resolution of the computer,
Each computer has only one root object of the handle, that is, the screen. Its handle is always 0.
Screensize is four-dimensional vector: [left, bottom, width, height].
For example:
> Scrsz = get (0, 'screensize ')
Scrsz =
1 1280 800
1280 and 800 are the resolution settings of the computer. Note: to change the resolution settings, restart the computer.
To take effect. Scrsz (4) is 800, scrsz (3) is 1280
2. Figure
Set the size of figure to 1/4 and place it in the top left corner:
Figure ('position', [1 scrsz (4)/2 scrsz (3)/2 scrsz (4)/2])
The figure outerposition attributes include title bar, menu bar, tool bars, and outer edges.
The figure position attribute does not include title bar, menu bar, tool bars, and outer edges.
Set (0, 'hideunincluented', 'off ')
> Get (GCF)
...
Position = [360 278 560 420]
...
Outerposition = [352 270 576 511]
...
Set the axis position. The axes outerpositio attributes include axis labels, title, and a margin. For a figure with only one axes object
The position attribute of axes is not including the tick marks and labels, title, and axis labels within the boundaries of axes.
The axesde tightinset attribute is the blank distance between the axes text labels, title, and axis labels. And the axes boundary.
Set (GCO, 'Units ', 'pixels ')
Get (GCO)
...
Outerposition = [1 560 420]
...
Position = [73.8 47.2 434 342.3]
...
Tightinset = [22 17 5 8]
Modified from: http://blog.csdn.net/lulubooboo/article/details/7313600
This article is from the squirrel blog, please be sure to keep this source http://apinetree.blog.51cto.com/714152/1546850
Get and figure