Welcome to PlantUML Q&A, where you can ask questions and receive answers from other members of the community.

You can also submit new features request and vote for them.

How do I add link notes in sub states

0 votes
Hi, how do I add notes for links in substates? I've tried the following but the translation fails. The note at the end works just fine if I remove the note from the inner state.
 
@startuml
 
[*] --> SubState
 
state SubState {
    [*] --> State1
    State1 --> State2
    note right on link
    hi
    end note
    State2 --> State3
}
 
OtherState --> OtherState2
note right on link
hi
end note
 
@enduml
asked Nov 5, 2015 by bep (120 points)

1 Answer

0 votes

Hi,

Thanks for the feedback. Your diagram is correct, but there is a bug in the parser.

This has been just fixed in last beta https://dl.dropboxusercontent.com/u/13064071/plantuml.jar

The fix will be included in next official release.

As temporary workaround you can remove heading spaces at "note right on link" and "end note" lines :

 [*] --> SubState
 
state SubState {
    [*] --> State1
    State1 --> State2
note right on link
  hi
end note
    State2 --> State3
}
 
OtherState --> OtherState2
note right on link
hi
end note

Thanks again!

answered Nov 8, 2015 by plantuml (124,290 points)
Support This Project Offer 250 Mo! Follow PlantUML on Twitter
...