Browsing through figures, without opening them all
8 次查看(过去 30 天)
显示 更早的评论
Hi!
I often print/save figures in png-format or similar, in order to be able to quickly browser through results, either using a photoviewer-program or plotting them into a pdf. However, In the the matlab-figures i usually include hidden data in for example lines and buttons/functions which I would be interested in accessing when browsing through them. (ex. buttondownfunctions on lines etc.)
I'm wondering if there is a way of browsing trough .fig files in a fast way, without opening them each separately?
Regards
Peter
0 个评论
回答(1 个)
Voss
2022-9-26
You can use load to inspect .fig files programmatically:
f = figure();
plot(1:10,'ButtonDownFcn','disp(''ok'')');
saveas(f,'1.fig')
delete(f);
ff = load('1.fig','-mat')
ff.hgS_070000
ff.hgS_070000.children
ff.hgS_070000.children(1).children(1)
ff.hgS_070000.children(1).children(1).properties
ff.hgS_070000.children(1).children(1).properties.ButtonDownFcn
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Specifying Target for Graphics Output 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!