circular update when arrowhead effect in plugin group

Contributor ,
Jan 13, 2021

Copy link to clipboard

Copied

My plugin creates a plugin group, which generally works fine. When the edit art contains a path with an arrowhead, round corners, or other effects, and I copy that art into the result art, it begins a cycle where the plugin group continually updates itself, then the effect updates, causing the plugin art to again update, until Illustrator crashes.

Is there a way to stop this from happening? The approach I've been trying is to simply expand the arrowhead, but I'm having trouble discovering programatically whether a path even has an arrowhead to expand.

It only happens when the object is selected, though, and the selection-changed notifier is sent. Then the object redraws, and the cycle repeats until it's no longer selected.

Any suggestions would be very much appreciated.

 

SOLVED: There's no need to mark the art as dirty when the plugin receives the SelectionChanged notifier. It only has to redraw the annotations. Illustrator will redraw the plugin group automatically.

TOPICS
SDK

Views

18

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

circular update when arrowhead effect in plugin group

Contributor ,
Jan 13, 2021

Copy link to clipboard

Copied

My plugin creates a plugin group, which generally works fine. When the edit art contains a path with an arrowhead, round corners, or other effects, and I copy that art into the result art, it begins a cycle where the plugin group continually updates itself, then the effect updates, causing the plugin art to again update, until Illustrator crashes.

Is there a way to stop this from happening? The approach I've been trying is to simply expand the arrowhead, but I'm having trouble discovering programatically whether a path even has an arrowhead to expand.

It only happens when the object is selected, though, and the selection-changed notifier is sent. Then the object redraws, and the cycle repeats until it's no longer selected.

Any suggestions would be very much appreciated.

 

SOLVED: There's no need to mark the art as dirty when the plugin receives the SelectionChanged notifier. It only has to redraw the annotations. Illustrator will redraw the plugin group automatically.

TOPICS
SDK

Views

19

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jan 13, 2021 0

Have something to add?

Join the conversation
Resources