thomasa88 / ParametricText

Fusion 360™ add-in for creating Text Parameters in sketches.
MIT License
75 stars 5 forks source link

Text doesn't update when configurations get generated through the API #68

Open AndireasB opened 2 months ago

AndireasB commented 2 months ago

Hi Thomas,

First of all, thank you very much for the add in! Your work is much appreciated!

I work with configurations and parametric text is pretty useful in this case. When changing/activating different configurations in the GUI the text updates just fine. However, if I want to generate new configurations through the API the text doesn't update. Even activating the configurations with .activate(), wait for Fusion adsk.doEvents(), as well as refreshing the viewport with app.activeViewport.refresh() didn't help.

When I click through the API generated configurations in the configuration table the text updates fine. But I want to automate exporting each configuration with an individual text on it. And right now the parametric text doesn't update and all exported configurations show the same text.

Do you have an idea on how to fix this issue?

Thank you in advance for your investigation. Let me know if I can help you.

Software

lukasesser commented 2 months ago

Hi, I'm having the same issue right now, would be amazing to solve this! Thanks a lot for your work!

Software

thomasa88 commented 1 month ago

Hi,

Maybe you can try

    app.fireCustomEvent('thomasa88_ParametricText_Ext_Update')
    adsk.doEvents()
    adsk.doEvents()  

from https://github.com/thomasa88/ParametricText/issues/60#issuecomment-1942770019 .

Maybe I should get triggering on Compute All implemented :thinking:

(Note: Issue #68 broken out from https://github.com/thomasa88/ParametricText/issues/56#issuecomment-2161541889 )

lukasesser commented 1 month ago

works for me. Thanks for the support!