One solution is to ignore the built-in resize methods and use a specific WindowsButtonDownFcn to emulate a resizing. But reinventing the wheel is awkward.
Another idea is a checking the actual figure size at the end of the callback and start it again in a recursion or loop - not satisfying also:
functionresize(FigH, EventData, AxesH)
doResize = true;
whiledoResize
siz = get(FigH,'Position');
pause(1.0);% Of course here are some real calculations
set(AxesH,'Position', [5, 5, siz(3:4)-10]);
drawnow;
doResize = ~isequal(siz, get(FigH,'Position'));
end
end
Of course, this is more a workaround than a solution. It would be much nicer to catch the Mouse-Release event after the resizing of the window was triggered.
Perhaps this is a question for Yair and the undocumented Java methods.
0 Comments
Sign in to comment.