vscode-plantuml
vscode-plantuml copied to clipboard
When using newpage in a procedure output is truncated
Attempting to split sequence diagram into multiple pages will not work if the newpage keyword is inside a procedure block.
example
@startuml
actor Actor as a
participant Business as b
participant Customer as c
!$var1 = true
!$var2 = "Abc"
!procedure $test($nm)
' newpage
== $nm ==
!endprocedure
!procedure $msg($str)
c -> b: $str
b -> a: $str
a --> c
!endprocedure
a -> a: self start
$test("1")
$msg("First msg")
a -> a++: $var2
!$var2 = "def"
a --> a: $var2
$test("2")
$msg("msg")
deactivate a
$msg("Test Message " + $var2)
$test("3")
$msg("What is happening?")
@enduml
version: 1.2021.7
confirmed, but there's no easy solutions.
the extension detects page count naively by count how much newpage
keyword in the code. when it come to the macro cases, it won't work.
just like syntax highlight problems, the final solution would be implementing a language parser which I'm not capable to do so.
What about this one? https://github.com/Enteee/plantuml-parser