Assigning color to connectors

0 votes
asked Aug 30 in Wanted features by Steve

Is it possible to alter the background color of connectors in an activity diagram? My fervent Googling implies it's not, but proving a negative...

E.g.,

@startuml
start
:The connector below 
wishes he was blue;
(B)
:This next connector
feels that she would
be better off green;
(G)
stop
@enduml


Thanks in advance,
-Steve

1 Answer

0 votes
answered Aug 30 by plantuml (202,540 points)
 
Best answer

Is this what you are looking for ?

@startuml
start
:The connector below
wishes he was blue;
-[#blue]->
:This next connector
feels that she would
be better off green;
-[#green]->
stop
@enduml
commented Aug 31 by Steve

No, I'm actually hoping to get the circles (i.e., the 'connectors') coloured. It's sort of confusing nomenclature but the Docs refers to them as connectors.

I mocked up what I want to generate in InkScape below. Is there any way to recreate the following with available PlantUML syntax?

commented Aug 31 by plantuml (202,540 points)

Of course ! This is a good idea.

So with last beta http://beta.plantuml.net/plantuml.jar you can now have :

@startuml
start
:The connector below
wishes he was blue;
#blue:(B)
:This next connector
feels that she would
be better off green;
#green:(G)
stop
@enduml

Is this what you are looking for ?

commented Aug 31 by Steve
Yes! This is wonderful. I'll do some additional testing on more complicated examples next week and post again if I find any issues, which seems unlikely, but the new syntax is intuitive.

Thanks so much for this.

-Steve
...