plantuml / backlog

Contains all issues for plantuml that are not currently working-in-progress
0 stars 0 forks source link

Is there a way to centre elements? #12

Open ghost opened 6 years ago

ghost commented 6 years ago

capture

The Plantuml elements start to the left. Is there a way to centre them like the latex equations circled in blue?

Code for the first element

@startuml
:<math>P(B|A)=\frac{P(B \cap A)}{P(A)}</math>;
@enduml
zimchaa commented 5 years ago

You could remove all the surrounding elements of the Activity node like this:

@startuml
skinparam shadowing false
skinparam backgroundColor transparent
skinparam activity {
   backgroundColor transparent
   borderColor transparent
}

:<math>P(B|A)=\frac{P(B \cap A)}{P(A)}</math>;
@enduml

plantuml.com

And then centre the resulting image... if you can't do that then you can increase the padding of the

Or you could use the @startmath operator to make it more simple:

@startmath
P(B|A)=\frac{P(B \cap A)}{P(A)}
@endmath

plantuml.com