altmany / export_fig

A MATLAB toolbox for exporting publication quality figures
BSD 3-Clause "New" or "Revised" License
1.27k stars 365 forks source link

figures with text overlay (using the text built-in) not saved if units are set to 'normalized' #373

Closed jay14bay closed 6 months ago

jay14bay commented 1 year ago

see attached example script and output ex1-text ex2-notext export_fig_issue.m.zip

altmany commented 1 year ago

I cannot reproduce the problem - I see the text correctly in both cases. Try again using to the latest version of export_fig.

jay14bay commented 1 year ago

Hi, seeing it on screen is not the problem - your saved figures also keep it? That's odd. I am using the latest version on Mac OS

On Thu, Apr 13, 2023 at 9:25 AM Yair Altman @.***> wrote:

I cannot reproduce the problem - I see the text correctly in both cases. Try again using to the latest version of export_fig.

— Reply to this email directly, view it on GitHub https://github.com/altmany/export_fig/issues/373#issuecomment-1507251710, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJUQAJYONOBW5DFDSUE46IDXBASGDANCNFSM6AAAAAAW5JGDWA . You are receiving this because you authored the thread.Message ID: @.***>

altmany commented 1 year ago

yes, I also see the text in the files (they look exactly the same except for the title).

Are you using export_fig v3.36? If so, then try to call drawnow; pause(0.5); immediately before the 2nd call to export_fig, see if this changes anything.

jay14bay commented 1 year ago

yes, using the version I just downloaded, adding that pause did not fix it!

jay14bay commented 1 year ago

using R2022b

jay14bay commented 1 year ago

aha - if i remove '-m4' from the export_fig call it saves the text (low quality figure)

altmany commented 6 months ago

Presumably fixed in the latest export_fig commit (v3.44)