adopt the gui window to my computer settings
3 次查看(过去 30 天)
显示 更早的评论
Hello!
It would be great if someone could help me... I have the next problem: How can I adopt the gui window to my computer settings?
It would be good if I could scale the windows...I think more about a dynamik skale like it is in all other windows applications. So I might not see the all the contend but get a scroll bar and shift by that.
How can I do this??
0 个评论
回答(1 个)
Walter Roberson
2011-9-12
You can use the figure property ResizeFcn to detect a resizing and to adjust whatever GUI elements you desire in order to keep the figure readable.
I would advise, though, that if you have not coded your GUI elements in "normalized" units, then it may be a bit complicated for your program to decide where each element should be repositioned to. I would further advise, however, that some GUI elements (especially text) look very ugly if they are specified in "normalized" units. MATLAB is not designed well to construct GUIs that automatically "look good" when they are resized.
To have windows that are larger that the screen, you can use uipanel() with Clipping set, and place your graphical elements within the panel. You would then program a scroll bar so that it changed the Position of the uipanel within the figure, which would have the effect of "panning" the content of the panel. Unfortunately there are various bugs having to do with the proper clipping against the edge of panels, especially the clipping of uicontrols.
There are some MATLAB File Exchange contributions designed to provide scrollable plot areas or to provide scrollable sets of images.
2 个评论
Walter Roberson
2011-9-12
What approach does the code take to handle the situation? We might need to see the code in order to be able to comment on how to adapt it to use scrolling (you could provide a link to the code if it is longer or part of the file exchange.)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Migrate GUIDE Apps 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!