How to load existing figure into GUIDE UIAxes
11 次查看(过去 30 天)
显示 更早的评论
I have an image with plots and labels layered on top that has been saved as both a .fig and a .jpg. My app loads the picture to display it, but the .jpg images are too blurry.
How do I load an existing .fig file into a UIAxes element? I already have the image saved as a property using openfig
4 个评论
Adam Danz
2021-4-15
Juan Pablo Pérez Durán's answer moved here as a comment
Did you find out how to? I'm struggling with the same thing:(
Adam Danz
2021-4-15
copyobj(ax.Children, app.UIAxes)
or completely replace the app axes with the axes from the external figure
newax = copyobj(ax, app.UIFigure);
and then reposition the copied axes, then delete the uiaxes
set(newax,'Units',app.UIAxes.Units,'Position',app.UIAxes.Position) % and possibily other properties
As Adam mentioned, this can get messy and my lines above are the untested bare minimum.
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Graphics Object Programming 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!