Home » Modeling » UML2 Tools » How to change appearance of diagram programatically?
How to change appearance of diagram programatically? [message #476378] |
Fri, 17 April 2009 16:50 |
Eclipse User |
|
|
|
Originally posted by: misinko.gmail.com
Hello,
I created plugin, from i would like to change appearance of some
diagram's parts (mainly in class diagram), for example: background of
classes, association lines.
Is it possible? If yes, how please.
Thank you.
|
|
|
Re: How to change appearance of diagram programatically? [message #476379 is a reply to message #476378] |
Mon, 20 April 2009 11:24 |
Tatiana Fesenko Messages: 530 Registered: July 2009 |
Senior Member |
|
|
Hello Michal,
Yes, you can.
Apperance of figures is specified in *ViewFactory classes.
For example, to modify background color of classes you should override Class2ViewFactory#decorateView()
method:
FillStyle fillStyle = (FillStyle) view.getStyle(NotationPackage.Literals.FILL_STYLE);
if (fillStyle != null) {
fillStyle.setFillColor(color);
}
Best wishes,
Tanya.
> Hello,
> I created plugin, from i would like to change appearance of some
> diagram's parts (mainly in class diagram), for example: background of
> classes, association lines.
> Is it possible? If yes, how please.
> Thank you.
|
|
|
Re: How to change appearance of diagram programatically? [message #535488 is a reply to message #476379] |
Mon, 24 May 2010 03:13 |
Marcelo Messages: 14 Registered: February 2010 |
Junior Member |
|
|
Hi,
I'm wondering whether it is possible to change the color of an
association (I couldn't do it using the GUI, and I didn't find how to do
it programatically - actually this is what I need).
Any idea?
All the best,
--
Marcelo
Em 20/04/2009 08:24, Tatiana Fesenko escreveu:
> Hello Michal,
>
> Yes, you can.
> Apperance of figures is specified in *ViewFactory classes.
> For example, to modify background color of classes you should override
> Class2ViewFactory#decorateView() method:
> FillStyle fillStyle = (FillStyle)
> view.getStyle(NotationPackage.Literals.FILL_STYLE);
> if (fillStyle != null) {
> fillStyle.setFillColor(color);
> }
>
>
> Best wishes,
> Tanya.
>
>> Hello,
>> I created plugin, from i would like to change appearance of some
>> diagram's parts (mainly in class diagram), for example: background of
>> classes, association lines.
>> Is it possible? If yes, how please.
>> Thank you.
>
>
|
|
|
Re: How to change appearance of diagram programatically? [message #623695 is a reply to message #476378] |
Mon, 20 April 2009 11:24 |
Tatiana Fesenko Messages: 530 Registered: July 2009 |
Senior Member |
|
|
Hello Michal,
Yes, you can.
Apperance of figures is specified in *ViewFactory classes.
For example, to modify background color of classes you should override Class2ViewFactory#decorateView()
method:
FillStyle fillStyle = (FillStyle) view.getStyle(NotationPackage.Literals.FILL_STYLE);
if (fillStyle != null) {
fillStyle.setFillColor(color);
}
Best wishes,
Tanya.
> Hello,
> I created plugin, from i would like to change appearance of some
> diagram's parts (mainly in class diagram), for example: background of
> classes, association lines.
> Is it possible? If yes, how please.
> Thank you.
|
|
|
Re: How to change appearance of diagram programatically? [message #625634 is a reply to message #476379] |
Mon, 24 May 2010 03:13 |
Marcelo Messages: 14 Registered: February 2010 |
Junior Member |
|
|
Hi,
I'm wondering whether it is possible to change the color of an
association (I couldn't do it using the GUI, and I didn't find how to do
it programatically - actually this is what I need).
Any idea?
All the best,
--
Marcelo
Em 20/04/2009 08:24, Tatiana Fesenko escreveu:
> Hello Michal,
>
> Yes, you can.
> Apperance of figures is specified in *ViewFactory classes.
> For example, to modify background color of classes you should override
> Class2ViewFactory#decorateView() method:
> FillStyle fillStyle = (FillStyle)
> view.getStyle(NotationPackage.Literals.FILL_STYLE);
> if (fillStyle != null) {
> fillStyle.setFillColor(color);
> }
>
>
> Best wishes,
> Tanya.
>
>> Hello,
>> I created plugin, from i would like to change appearance of some
>> diagram's parts (mainly in class diagram), for example: background of
>> classes, association lines.
>> Is it possible? If yes, how please.
>> Thank you.
>
>
|
|
|
Goto Forum:
Current Time: Fri Mar 29 00:45:41 GMT 2024
Powered by FUDForum. Page generated in 0.03427 seconds
|