Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

PlantUML different layouts

Tags:

plantuml

I am using PlantUML API to generate Activity Diagram.

I have used GraphViz before and used rank parameter to define layout

rank=LR [for left to right] 

I am trying to find similiar thing in PlantUML where I can change its orientation to "Left to Right" instead of existing layout i.e. "Top to Bottom".

like image 494
Makky Avatar asked May 14 '12 10:05

Makky


People also ask

How do you align PlantUML?

When we want to text to be center aligned we simply use the new-line character \n . If we want to have our text left aligned we use \l instead of \n . And to right align the text we use \r . Written with PlantUML 1.2017.

How do I add a legend in PlantUML?

There doesn't appear to be a direct way of including a color-coded legend in a PlantUML diagram, but I figured out a workaround which is close enough. Declare classes TypeA , TypeB , TypeC inside a package LEGEND . Hide the circle, methods and members for each class. Attach "hidden" connectors between the classes.

Does PlantUML use graphviz?

(Note: PlantUML uses Graphviz/DOT for layout of UML diagrams anyway.) This allows you to use Graphviz/DOT with all tools that support PlantUML. You can use @startdot/@enddot or @startuml/@enduml to delineate the diagram, and then the very first line has to be: digraph XYZ { .

What is PUML format?

File created by PlantUML, a UML diagram creator used within programs like Sublime Text Editor or programming language like HTML; same as the . PU file; contains code referenced by PlantUML to create diagram images that can be generated as .


1 Answers

You can use the following command with State, Class, Component or Usecase diagrams:

left to right direction 

(see https://plantuml.com/use-case-diagram#d551e48d272b2b07)

Edit: This comment from 2012 originally claimed that the feature was scheduled for the next release. It's been available forever now.

like image 96
PlantUML Avatar answered Sep 19 '22 11:09

PlantUML