Skip to content

Conversation

kirchsth
Copy link
Member

@kirchsth kirchsth commented Sep 11, 2025

fixes #400

In July 2025, https://c4model.com/ introduced a new visual style for C4 diagrams. C4-PlantUML now supports this updated styling too.

To enable the new style, use one of these options:

  • Add !NEW_C4_STYLE=1 before including any C4_* files
  • Use the command line argument -DNEW_C4_STYLE=1

Warning

The !NEW_C4_STYLE=1 statement must be placed BEFORE all C4_ !include statements.

The new style can be combined with existing themes and customer specific tags.

It can be tested via my extended branch like below:

@startuml
' activates new style. It has to be set before a theme or a C4_* file is included
!NEW_C4_STYLE=1
 
!include https://raw.githubusercontent.com/kirchsth/C4-PlantUML/extended/C4_Container.puml

LAYOUT_LANDSCAPE()

Person(admin, "Administrator")
System_Boundary(c1, 'Sample') {
    Container(web_app, "Web Application", "C#, ASP.NET Core 2.1 MVC", "Allows users to compare multiple Twitter timelines")
}
System(twitter, "Twitter")

Rel(admin, web_app, "Uses", "HTTPS")
Rel(web_app, twitter, "Gets tweets from", "HTTPS")

SHOW_LEGEND()
@enduml

If the image is not correct displayed please refresh the page or open the link.

New C4 style sample

Following with theme and additional tags,...

complex

BR Helmut

@kirchsth kirchsth changed the title Feature/400 new style #400 support new visual style for C4 diagrams with !NEW_C4_STYLE=1 Sep 11, 2025
@kirchsth kirchsth added this to the v2.13.0 milestone Sep 11, 2025
@kirchsth kirchsth merged commit 279a21d into plantuml-stdlib:master Sep 11, 2025
1 check passed
@Potherca Potherca self-requested a review September 14, 2025 13:09
@Potherca
Copy link
Member

Great work!

@kirchsth kirchsth deleted the feature/400_new_style branch September 14, 2025 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Any plans to support new C4 diagrams style?
2 participants