Increase Creation Rate

I use the setting below to maximize the Matlab pattern:

set(gcf,'units','normalized','outerposition',[0 0 1 1])

Although it is maximized, it is still not fully maximized, since the maximization icon on the label (below) is not enabled. enter image description here And that makes me free parts of the figure when exporting. Therefore, I am wondering how I can fully maximize it, as if I manually pressed the button to maximize the shape.

+4
source share
1 answer

You can use undocumented functions to achieve the desired result:

drawnow
jFig = get(handle(gcf), 'JavaFrame'); 
jFig.setMaximized(true);

drawnow is not obvious, but significant, as Yair Altman mentioned in one of his comments, how to avoid Java erros:

EDT. : drawnow; pause(0.1);, JavaFrame (setMaximized Java).

Matlab R2015a Windows 8.1.

+5

Source: https://habr.com/ru/post/1583830/


All Articles