copyobj from GUI to new figure but after closing figure GUI obj disappears

1 次查看(过去 30 天)
So I have a gui that reads some data and plots it on an axis figure on the GUI itself.
The GUI also has a "export graph" button, which uses copyobj and copies the axes, and legends onto a new figure.
Everything works except when I call the command to close the figure. This command closes the figure, but at the same time, some of the objects from the original GUI disappears with it, namely the legend, and the secondary axis.
Anyone run into this issue before?
  1 个评论
Walter Roberson
Walter Roberson 2013-5-31
编辑:Walter Roberson 2013-5-31
Are you specifically copyobj()'ing the legend? legends reside in their own axes.
Can you test to see whether after the legend has been copied, whether the annotation objects of the original and the copy are the same object (not just same string)? If so then a delete() of the original might affect the copy.

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile 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!

Translated by