Sequence Diagram - Creol - Link Support

0 votes
asked Apr 18, 2016 in Bug by mgriffel (300 points)

Hello,

a user of the Confluence PlantUML Plugin wants to render links inside sequence diagrams like the following:

 

@startuml

"FROM"->"TO": [["http://plantuml.sourceforge.net/qa"]]

@enduml 

On the final image (map) the arrowhead is a link.

If the following markup is used then the complete text inclunding the link is rendered in the image:

@startuml

"FROM"->"TO": -[["http://plantuml.sourceforge.net/qa"]]

@enduml

For more background information see https://avono-support.atlassian.net/browse/PUML-171

Are links supported by the light creole engine (http://plantuml.com/creole.html)?

Greetings 

Michael

 

 

1 Answer

0 votes
answered Apr 18, 2016 by plantuml (295,000 points)

This behaviour is indeed strange, but there is a (historical) reason.

1) At the beginning, PlantUML was not supporting hyperlink at all.

2) Then latter, limited support for hyperlink has been added in Sequence Diagram.
In that case, the hyperlink applied on the whole message/arrow. And the hyperlink must be put at the very beginning of the message.
The syntax was:

@startuml
Bob -> Alice: [[http://www.google.com]] This is a text
@enduml


Result: http://plantuml.com/plantuml/svg/SyfFKj2rKt3CoKnEjLA8ZiueAIcmqjSlBo_NIy_FJyz9rKlEpusDLGZ9o2nM0A94XPBKYX80

As you can see, in that case, the link is set on the whole message.

3) Then latter again, support for hyperlink has been extended through Creole engine, in a more regular way.
So you can now have:

@startuml
Bob -> Alice: I a using [[http://www.google.com]] as search engine
@enduml


Result: http://plantuml.com/plantuml/svg/SyfFKj2rKt3CoKnEjLBmL4XKA2tEp4jNY8xEA2afiDBNBoylrqlFpq_FITLBpi-DZLL8B5OeJaqiIivGICrBpynB1G00

The only real issue here is that we are (somehow) trying to support older syntax: we would like that diagrams created before the introduction of syntax 3) still work with newer version of PlantUML (ascending compatibility).

Of course, this makes some strange behaviour for newer users.

Maybe it's time for us to completely remove syntax 2) to have a more logical behaviour ? Any though about this ?
 

commented Apr 20, 2016 by mgriffel (300 points)
Thank you for clarifying this! It's okay for me. I have to get feedback from the customer user. Maybe I come back with further questions. :-)
...