contribute invisible links for better graphviz alinment

0 votes
asked Aug 23, 2013 in Wanted features by mike-khl (120 points)
edited Aug 24, 2013 by mike-khl

Hi,

I'm crazy about this project. Thanks a lot.

However today I need a realy weird component chart, which from Graphviz POV makes no sense at all. 

i.e. I need

@startuml
[bb] --> [zz]
[zz] -> [ee]
[ee] --> [yy]
[ww] --> [xx]
[ww] -> [aa]
' [yy] _> [xx]
@enduml

aligned as

but not as

Fortunately I've found quite easy solution: I just added invisible arrow notation with underscore __> which is comment above

I'm enjoyed how it works and happy to contribute.

https://www.dropbox.com/s/dfiq9b0zppvss7s/CommandLinkElement.java.patch

Thank you for the plant!

 

commented Aug 24, 2013 by mike-khl (120 points)
however, supporting <<hidden>> or skinparam for stereotype might be more convenient.

1 Answer

0 votes
answered Aug 27, 2013 by plantuml (294,960 points)

Hello,

Thanks for your contribution. However, we'd better keep the _ for other functionalities, so in V7978, we have implemented this:

@startuml
[bb] --> [zz]
[zz] -> [ee]
[ee] -[bold,#green]-> [yy]
[ww] -[#red]-> [xx]
[ww] -> [aa]
[yy] -[hidden]> [xx]
@enduml

The syntax is more verbose than your proposal, but is more flexible. BTW, this is working with some other diagrams too (Class, State, Usecase...)

Thanks again for your patch.

 

commented Aug 27, 2013 by mike-khl (120 points)
Hello,

It makes sense, rather than, my "hack". However, to be combined with directions words: left,right it might be really verbose.
I see how stereotype can be referred in skinparam, don't you think it can be useful for links too?
commented Mar 24, 2014 by anonymous
I had a problem with some diagrams showing different approaches on the same problem where on some diagrams "A" was shown on the left and "B" on the right, while on some other it was the opposite. I thought, "wouldn't it be nice to have invisible links to force sides" and than I found this posts. It is a great feature and you should advertise it more. It took me some time to figure out right syntax (right[hidden]), but now my diagrams look great. Thanks!
...