Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: McBie on July 09, 2009, 03:12:04 am

Title: [Shape script] modify fillcolor of native shape
Post by: McBie on July 09, 2009, 03:12:04 am
Hi everybody,
I'd like to some modify the visual appearance of elements with a certain tagged value. So I created a stereotype and assigned  a shape script.
 The script looks like this:
Code: [Select]
shape main
{
      if (HasTag("EPDMPhase","1_A"))
      {
            setFillColor(128,255,128);
            drawnativeShape();
      
      }else{
            drawnativeShape();
      }
}

The funny thing is in the diagramm only the left half of an element is filled with my color.

Any Ideas?

Thanks!

mArco
Title: Re: [Shape script] modify fillcolor of native shap
Post by: Eve on July 09, 2009, 08:49:50 am
It's to do with the gradients on the elements.  You can get it right by turning off gradients or by getting the latest version of EA.