Colors have to be defined in UpdateElementStyle() too, otherwise error in dynamic legend
kirchsth opened this issue · comments
kirchsth commented
If an UpdateElementStyle()
call does not define all colors, then the missing colors are shown in the legend as no ... color
.
@startuml
!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Container.puml
UpdateElementStyle(person, $fontColor="green")
Person(p, "Person")
SHOW_LEGEND()
@enduml
(Workaround:) If the missing colors are defined with the default colors then it is working, but this should not be necessary.
@startuml
!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Container.puml
UpdateElementStyle(person, $fontColor="green", $bgColor=$PERSON_BG_COLOR, $borderColor=$PERSON_BORDER_COLOR)
Person(p, "Person")
SHOW_LEGEND()
@enduml