Why does an axes tag name keep dissappearing when opening a saved figure in GUIDE?

4 vues (au cours des 30 derniers jours)
Paul
Paul le 12 Sep 2011
I've run into an issue that is becoming very very annoying and I'm wondering if anyone else ever experienced this.
I'm constructing a gui that has an axes with code in its creation function. For some reason, every now and then, when I close the open figure in GUIDE (after saving) and then re-open it, the tag name disappears, making the creation function code not work. I then have to open the figure in GUIDE again and reset the tag name.
Has anyone else encountered this very annoying issue? I have Matlab R2010a
  1 commentaire
Carsten
Carsten le 15 Avr 2013
Yes it happens "every now and then" to me too! I have just made a Service Request regarding 'axes tags disappears after using GUIDE'.
MathWorks seem to be unaware of this problem, even if it has annoyed users for many years.

Connectez-vous pour commenter.

Réponses (1)

Jan
Jan le 15 Avr 2013
I'm convinced, that Matlab does not let the tag vanish magically, but that you observe the documented and intented feature, that high-level functions like plot() and imshow() clear existing objects in the axes, when the 'NextPlot' property is not 'add', e.g. as set by hold('on').
A solution is to set the axes' property 'NextPlot' to 'add', but then you have to delete formerly existing objects explicitly on demand. Another method would be to use low-level functions as line() or image() instead.

Catégories

En savoir plus sur Migrate GUIDE Apps dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by