Could other diagram types, like component, state, etc. support dynamic color notation?

0 votes
asked Apr 22, 2025 in Wanted features by boshka (4,060 points)
in https://plantuml.com/ru/color - Automatic Font Color seems to be applicable only to sequences. It would be really cool to support it also for other diagram types.

1 Answer

0 votes
answered Apr 23, 2025 by The-Lu (89,080 points)

Hello B.,

For your information, here is an example of component and deployment diagram, with:

@startuml
<style>
document {
  BackGroundColor darkblue
}
root {
  FontColor #?black:white
  LineColor white
}
</style>

file f
node n {
  card c
}
database d {
  card c1
}
@enduml

Enjoy,
Regards,
Th.

commented Apr 24, 2025 by boshka (4,060 points)
Hi The-Lu!

thank you! I meant a bit another case (which actually brakes):

@startuml

component n #?black:white{
  
}

@enduml

Please have a look:
https://www.plantuml.com/plantuml/uml/SoWkIImgAStDuU9ApiyjoCzBpIjHo5DGja_AIKpEjYhFo2n9hUPIKE2gvU9oICrB0Qe40000
...