最近は GitHub が Mermaid.js をサポートしたため、plantuml の利用はよく検討してください
plantuml 良いよ
PlantUML : シンプルなテキストファイルで UML が書ける、オープンソースのツール
例えば、フローチャートなどの アクティビティ図 が、
@startuml
start
if (Graphviz installed?) then (yes)
:process all\ndiagrams;
else (no)
:process only
__sequence__ and __activity__ diagrams;
endif
stop
@enduml
で書けたりする。擬似コード書くのに最高。
ホームページにシンプルな説明があるため、DRY に則って、ここでは style を格好良くしたい。
デフォルト
CloudFoundry のブランドガイドラインに沿ってみた
Brand Guidelines - Cloud Foundry
カラースキーム
下記、color scheme を config.txt に保存して、
alias plantuml = "plantuml -config ~/plantuml/config.txt"
としておくと、自動で以下の color Scheme を使ってくれる。
Go-zen-chu/plantuml_cf_theme: CF Color Theme
' defaults
skinparam shadowing false
skinparam DefaultFontName Proxima Nova
skinparam ArrowColor #00b2e2
skinparam DefaultFontColor #454645
' BorderColor
skinparam ActivityBorderColor #2D74BA
skinparam ActivityDiamondBorderColor #2D74BA
skinparam ActorBorderColor #2D74BA
skinparam AgentBorderColor #2D74BA
skinparam ArtifactBorderColor #2D74BA
skinparam BoundaryBorderColor #2D74BA
skinparam CardBorderColor #2D74BA
skinparam ClassBorderColor #2D74BA
skinparam CloudBorderColor #2D74BA
skinparam CollectionsBorderColor #2D74BA
skinparam ComponentBorderColor #2D74BA
skinparam ControlBorderColor #2D74BA
skinparam DatabaseBorderColor #2D74BA
skinparam EntityBorderColor #2D74BA
skinparam FileBorderColor #2D74BA
skinparam FolderBorderColor #2D74BA
skinparam FrameBorderColor #2D74BA
skinparam InterfaceBorderColor #2D74BA
skinparam LegendBorderColor #2D74BA
skinparam NodeBorderColor #2D74BA
skinparam NoteBorderColor #2D74BA
skinparam ObjectBorderColor #2D74BA
skinparam PackageBorderColor #2D74BA
skinparam PageBorderColor #2D74BA
skinparam ParticipantBorderColor #2D74BA
skinparam PartitionBorderColor #2D74BA
skinparam QueueBorderColor #2D74BA
skinparam RectangleBorderColor #2D74BA
skinparam SequenceBoxBorderColor #2D74BA
skinparam SequenceDividerBorderColor #2D74BA
skinparam SequenceGroupBorderColor #2D74BA
skinparam SequenceLifeLineBorderColor #2D74BA
skinparam SequenceReferenceBorderColor #2D74BA
skinparam StackBorderColor #2D74BA
skinparam StateBorderColor #2D74BA
skinparam StereotypeABorderColor #2D74BA
skinparam StereotypeCBorderColor #2D74BA
skinparam StereotypeEBorderColor #2D74BA
skinparam StereotypeIBorderColor #2D74BA
skinparam StereotypeNBorderColor #2D74BA
skinparam StorageBorderColor #2D74BA
skinparam SwimlaneBorderColor #2D74BA
skinparam UsecaseBorderColor #2D74BA
' BackgroundColor
skinparam ActivityBackgroundColor #FFFFFF
skinparam ActivityDiamondBackgroundColor #FFFFFF
skinparam ActorBackgroundColor #FFFFFF
skinparam AgentBackgroundColor #FFFFFF
skinparam ArtifactBackgroundColor #FFFFFF
skinparam BackgroundColor #FFFFFF
skinparam BoundaryBackgroundColor #FFFFFF
skinparam CardBackgroundColor #FFFFFF
skinparam ClassBackgroundColor #FFFFFF
skinparam ClassHeaderBackgroundColor #FFFFFF
skinparam CloudBackgroundColor #FFFFFF
skinparam CollectionsBackgroundColor #FFFFFF
skinparam ComponentBackgroundColor #FFFFFF
skinparam ControlBackgroundColor #FFFFFF
skinparam DatabaseBackgroundColor #FFFFFF
skinparam EntityBackgroundColor #FFFFFF
skinparam FileBackgroundColor #FFFFFF
skinparam FolderBackgroundColor #FFFFFF
skinparam FrameBackgroundColor #FFFFFF
skinparam IconPackageBackgroundColor #FFFFFF
skinparam IconPrivateBackgroundColor #FFFFFF
skinparam IconProtectedBackgroundColor #FFFFFF
skinparam IconPublicBackgroundColor #FFFFFF
skinparam InterfaceBackgroundColor #FFFFFF
skinparam LegendBackgroundColor #FFFFFF
skinparam NodeBackgroundColor #FFFFFF
skinparam NoteBackgroundColor #FFFFFF
skinparam ObjectBackgroundColor #FFFFFF
skinparam PackageBackgroundColor #FFFFFF
skinparam ParticipantBackgroundColor #FFFFFF
skinparam PartitionBackgroundColor #FFFFFF
skinparam QueueBackgroundColor #FFFFFF
skinparam RectangleBackgroundColor #FFFFFF
skinparam SequenceBoxBackgroundColor #FFFFFF
skinparam SequenceDividerBackgroundColor #FFFFFF
skinparam SequenceGroupBackgroundColor #FFFFFF
skinparam SequenceGroupBodyBackgroundColor #FFFFFF
skinparam SequenceLifeLineBackgroundColor #FFFFFF
skinparam SequenceReferenceBackgroundColor #FFFFFF
skinparam SequenceReferenceHeaderBackgroundColor #FFFFFF
skinparam StackBackgroundColor #FFFFFF
skinparam StateBackgroundColor #FFFFFF
skinparam StereotypeABackgroundColor #FFFFFF
skinparam StereotypeCBackgroundColor #FFFFFF
skinparam StereotypeEBackgroundColor #FFFFFF
skinparam StereotypeIBackgroundColor #FFFFFF
skinparam StereotypeNBackgroundColor #FFFFFF
skinparam StorageBackgroundColor #FFFFFF
skinparam TitleBackgroundColor #FFFFFF
skinparam UsecaseBackgroundColor #FFFFFF
' StateColor
skinparam ActivityStartColor #454645
skinparam ActivityEndColor #454645
skinparam StateStartColor #454645
skinparam StateEndColor #454645
参考
plantuml -language
でなぜかすべての予約語が取れるよう。これで skinparam で設定できる値がわかる。
plantuml 予約語
;type
abstract
actor
agent
archimate
artifact
boundary
card
class
cloud
component
control
database
entity
enum
file
folder
frame
interface
node
object
package
participant
queue
rectangle
stack
state
storage
usecase
;keyword
@enddot
@endsalt
@enduml
@startdot
@startsalt
@startuml
activate
again
also
alt
as
autonumber
bottom
box
break
caption
center
create
critical
deactivate
destroy
down
else
elseif
end
endif
endwhile
footbox
footer
fork
group
header
hide
hnote
if
is
kill
left
legend
link
loop
namespace
newpage
note
of
on
opt
order
over
package
page
par
partition
ref
repeat
return
right
rnote
rotate
show
skin
skinparam
start
stop
title
top
top to bottom direction
up
while
;preprocessor
!define
!definelong
!else
!enddefinelong
!endif
!exit
!if
!ifdef
!ifndef
!include
!pragma
!undef
;skinparameter
ActivityBackgroundColor
ActivityBarColor
ActivityBorderColor
ActivityBorderThickness
ActivityDiamondBackgroundColor
ActivityDiamondBorderColor
ActivityDiamondFontColor
ActivityDiamondFontName
ActivityDiamondFontSize
ActivityDiamondFontStyle
ActivityEndColor
ActivityFontColor
ActivityFontName
ActivityFontSize
ActivityFontStyle
ActivityStartColor
ActorBackgroundColor
ActorBorderColor
ActorFontColor
ActorFontName
ActorFontSize
ActorFontStyle
ActorStereotypeFontColor
ActorStereotypeFontName
ActorStereotypeFontSize
ActorStereotypeFontStyle
AgentBackgroundColor
AgentBorderColor
AgentBorderThickness
AgentFontColor
AgentFontName
AgentFontSize
AgentFontStyle
AgentStereotypeFontColor
AgentStereotypeFontName
AgentStereotypeFontSize
AgentStereotypeFontStyle
ArrowColor
ArrowFontColor
ArrowFontName
ArrowFontSize
ArrowFontStyle
ArrowLollipopColor
ArrowThickness
ArtifactBackgroundColor
ArtifactBorderColor
ArtifactFontColor
ArtifactFontName
ArtifactFontSize
ArtifactFontStyle
ArtifactStereotypeFontColor
ArtifactStereotypeFontName
ArtifactStereotypeFontSize
ArtifactStereotypeFontStyle
BackgroundColor
BoundaryBackgroundColor
BoundaryBorderColor
BoundaryFontColor
BoundaryFontName
BoundaryFontSize
BoundaryFontStyle
BoundaryStereotypeFontColor
BoundaryStereotypeFontName
BoundaryStereotypeFontSize
BoundaryStereotypeFontStyle
CaptionFontColor
CaptionFontName
CaptionFontSize
CaptionFontStyle
CardBackgroundColor
CardBorderColor
CardBorderThickness
CardFontColor
CardFontName
CardFontSize
CardFontStyle
CardStereotypeFontColor
CardStereotypeFontName
CardStereotypeFontSize
CardStereotypeFontStyle
CircledCharacterFontColor
CircledCharacterFontName
CircledCharacterFontSize
CircledCharacterFontStyle
CircledCharacterRadius
ClassAttributeFontColor
ClassAttributeFontName
ClassAttributeFontSize
ClassAttributeFontStyle
ClassAttributeIconSize
ClassBackgroundColor
ClassBorderColor
ClassBorderThickness
ClassFontColor
ClassFontName
ClassFontSize
ClassFontStyle
ClassHeaderBackgroundColor
ClassStereotypeFontColor
ClassStereotypeFontName
ClassStereotypeFontSize
ClassStereotypeFontStyle
CloudBackgroundColor
CloudBorderColor
CloudFontColor
CloudFontName
CloudFontSize
CloudFontStyle
CloudStereotypeFontColor
CloudStereotypeFontName
CloudStereotypeFontSize
CloudStereotypeFontStyle
CollectionsBackgroundColor
CollectionsBorderColor
ColorArrowSeparationSpace
ComponentBackgroundColor
ComponentBorderColor
ComponentBorderThickness
ComponentFontColor
ComponentFontName
ComponentFontSize
ComponentFontStyle
ComponentStereotypeFontColor
ComponentStereotypeFontName
ComponentStereotypeFontSize
ComponentStereotypeFontStyle
ComponentStyle
ConditionStyle
ControlBackgroundColor
ControlBorderColor
ControlFontColor
ControlFontName
ControlFontSize
ControlFontStyle
ControlStereotypeFontColor
ControlStereotypeFontName
ControlStereotypeFontSize
ControlStereotypeFontStyle
DatabaseBackgroundColor
DatabaseBorderColor
DatabaseFontColor
DatabaseFontName
DatabaseFontSize
DatabaseFontStyle
DatabaseStereotypeFontColor
DatabaseStereotypeFontName
DatabaseStereotypeFontSize
DatabaseStereotypeFontStyle
DefaultFontColor
DefaultFontName
DefaultFontSize
DefaultFontStyle
DefaultMonospacedFontName
DefaultTextAlignment
DiagramBorderColor
DiagramBorderThickness
Dpi
EntityBackgroundColor
EntityBorderColor
EntityFontColor
EntityFontName
EntityFontSize
EntityFontStyle
EntityStereotypeFontColor
EntityStereotypeFontName
EntityStereotypeFontSize
EntityStereotypeFontStyle
FileBackgroundColor
FileBorderColor
FileFontColor
FileFontName
FileFontSize
FileFontStyle
FileStereotypeFontColor
FileStereotypeFontName
FileStereotypeFontSize
FileStereotypeFontStyle
FolderBackgroundColor
FolderBorderColor
FolderFontColor
FolderFontName
FolderFontSize
FolderFontStyle
FolderStereotypeFontColor
FolderStereotypeFontName
FolderStereotypeFontSize
FolderStereotypeFontStyle
FooterFontColor
FooterFontName
FooterFontSize
FooterFontStyle
FrameBackgroundColor
FrameBorderColor
FrameFontColor
FrameFontName
FrameFontSize
FrameFontStyle
FrameStereotypeFontColor
FrameStereotypeFontName
FrameStereotypeFontSize
FrameStereotypeFontStyle
GenericDisplay
Guillemet
Handwritten
HeaderFontColor
HeaderFontName
HeaderFontSize
HeaderFontStyle
HyperlinkColor
HyperlinkUnderline
IconIEMandatoryColor
IconPackageBackgroundColor
IconPackageColor
IconPrivateBackgroundColor
IconPrivateColor
IconProtectedBackgroundColor
IconProtectedColor
IconPublicBackgroundColor
IconPublicColor
InterfaceBackgroundColor
InterfaceBorderColor
InterfaceFontColor
InterfaceFontName
InterfaceFontSize
InterfaceFontStyle
InterfaceStereotypeFontColor
InterfaceStereotypeFontName
InterfaceStereotypeFontSize
InterfaceStereotypeFontStyle
LegendBackgroundColor
LegendBorderColor
LegendBorderThickness
LegendFontColor
LegendFontName
LegendFontSize
LegendFontStyle
Linetype
MaxAsciiMessageLength
MaxMessageSize
MinClassWidth
Monochrome
NodeBackgroundColor
NodeBorderColor
NodeFontColor
NodeFontName
NodeFontSize
NodeFontStyle
NodeStereotypeFontColor
NodeStereotypeFontName
NodeStereotypeFontSize
NodeStereotypeFontStyle
Nodesep
NoteBackgroundColor
NoteBorderColor
NoteBorderThickness
NoteFontColor
NoteFontName
NoteFontSize
NoteFontStyle
NoteShadowing
ObjectAttributeFontColor
ObjectAttributeFontName
ObjectAttributeFontSize
ObjectAttributeFontStyle
ObjectBackgroundColor
ObjectBorderColor
ObjectBorderThickness
ObjectFontColor
ObjectFontName
ObjectFontSize
ObjectFontStyle
ObjectStereotypeFontColor
ObjectStereotypeFontName
ObjectStereotypeFontSize
ObjectStereotypeFontStyle
PackageBackgroundColor
PackageBorderColor
PackageBorderThickness
PackageFontColor
PackageFontName
PackageFontSize
PackageFontStyle
PackageStereotypeFontColor
PackageStereotypeFontName
PackageStereotypeFontSize
PackageStereotypeFontStyle
PackageStyle
Padding
PageBorderColor
PageExternalColor
PageMargin
ParticipantBackgroundColor
ParticipantBorderColor
ParticipantFontColor
ParticipantFontName
ParticipantFontSize
ParticipantFontStyle
PartitionBackgroundColor
PartitionBorderColor
PartitionBorderThickness
PartitionFontColor
PartitionFontName
PartitionFontSize
PartitionFontStyle
PathHoverColor
QueueBackgroundColor
QueueBorderColor
QueueFontColor
QueueFontName
QueueFontSize
QueueFontStyle
QueueStereotypeFontColor
QueueStereotypeFontName
QueueStereotypeFontSize
QueueStereotypeFontStyle
Ranksep
RectangleBackgroundColor
RectangleBorderColor
RectangleBorderThickness
RectangleFontColor
RectangleFontName
RectangleFontSize
RectangleFontStyle
RectangleStereotypeFontColor
RectangleStereotypeFontName
RectangleStereotypeFontSize
RectangleStereotypeFontStyle
ResponseMessageBelowArrow
RoundCorner
SameClassWidth
SequenceActorBorderThickness
SequenceArrowThickness
SequenceBoxBackgroundColor
SequenceBoxBorderColor
SequenceBoxFontColor
SequenceBoxFontName
SequenceBoxFontSize
SequenceBoxFontStyle
SequenceDelayFontColor
SequenceDelayFontName
SequenceDelayFontSize
SequenceDelayFontStyle
SequenceDividerBackgroundColor
SequenceDividerBorderColor
SequenceDividerBorderThickness
SequenceDividerFontColor
SequenceDividerFontName
SequenceDividerFontSize
SequenceDividerFontStyle
SequenceGroupBackgroundColor
SequenceGroupBodyBackgroundColor
SequenceGroupBorderColor
SequenceGroupBorderThickness
SequenceGroupFontColor
SequenceGroupFontName
SequenceGroupFontSize
SequenceGroupFontStyle
SequenceGroupHeaderFontColor
SequenceGroupHeaderFontName
SequenceGroupHeaderFontSize
SequenceGroupHeaderFontStyle
SequenceLifeLineBackgroundColor
SequenceLifeLineBorderColor
SequenceLifeLineBorderThickness
SequenceNewpageSeparatorColor
SequenceParticipant
SequenceParticipantBorderThickness
SequenceReferenceBackgroundColor
SequenceReferenceBorderColor
SequenceReferenceBorderThickness
SequenceReferenceFontColor
SequenceReferenceFontName
SequenceReferenceFontSize
SequenceReferenceFontStyle
SequenceReferenceHeaderBackgroundColor
SequenceStereotypeFontColor
SequenceStereotypeFontName
SequenceStereotypeFontSize
SequenceStereotypeFontStyle
SequenceTitleFontColor
SequenceTitleFontName
SequenceTitleFontSize
SequenceTitleFontStyle
Shadowing
StackBackgroundColor
StackBorderColor
StackFontColor
StackFontName
StackFontSize
StackFontStyle
StackStereotypeFontColor
StackStereotypeFontName
StackStereotypeFontSize
StackStereotypeFontStyle
StateAttributeFontColor
StateAttributeFontName
StateAttributeFontSize
StateAttributeFontStyle
StateBackgroundColor
StateBorderColor
StateEndColor
StateFontColor
StateFontName
StateFontSize
StateFontStyle
StateStartColor
StereotypeABackgroundColor
StereotypeABorderColor
StereotypeCBackgroundColor
StereotypeCBorderColor
StereotypeEBackgroundColor
StereotypeEBorderColor
StereotypeIBackgroundColor
StereotypeIBorderColor
StereotypeNBackgroundColor
StereotypeNBorderColor
StereotypePosition
StorageBackgroundColor
StorageBorderColor
StorageFontColor
StorageFontName
StorageFontSize
StorageFontStyle
StorageStereotypeFontColor
StorageStereotypeFontName
StorageStereotypeFontSize
StorageStereotypeFontStyle
Style
SvglinkTarget
SwimlaneBorderColor
SwimlaneBorderThickness
SwimlaneTitleFontColor
SwimlaneTitleFontName
SwimlaneTitleFontSize
SwimlaneTitleFontStyle
SwimlaneWidth
TabSize
TitleBackgroundColor
TitleBorderColor
TitleBorderRoundCorner
TitleBorderThickness
TitleFontColor
TitleFontName
TitleFontSize
TitleFontStyle
UsecaseBackgroundColor
UsecaseBorderColor
UsecaseBorderThickness
UsecaseFontColor
UsecaseFontName
UsecaseFontSize
UsecaseFontStyle
UsecaseStereotypeFontColor
UsecaseStereotypeFontName
UsecaseStereotypeFontSize
UsecaseStereotypeFontStyle
;color
;154
APPLICATION
AliceBlue
AntiqueWhite
Aqua
Aquamarine
Azure
BUSINESS
Beige
Bisque
Black
BlanchedAlmond
Blue
BlueViolet
Brown
BurlyWood
CadetBlue
Chartreuse
Chocolate
Coral
CornflowerBlue
Cornsilk
Crimson
Cyan
DarkBlue
DarkCyan
DarkGoldenRod
DarkGray
DarkGreen
DarkGrey
DarkKhaki
DarkMagenta
DarkOliveGreen
DarkOrchid
DarkRed
DarkSalmon
DarkSeaGreen
DarkSlateBlue
DarkSlateGray
DarkSlateGrey
DarkTurquoise
DarkViolet
Darkorange
DeepPink
DeepSkyBlue
DimGray
DimGrey
DodgerBlue
FireBrick
FloralWhite
ForestGreen
Fuchsia
Gainsboro
GhostWhite
Gold
GoldenRod
Gray
Green
GreenYellow
Grey
HoneyDew
HotPink
IMPLEMENTATION
IndianRed
Indigo
Ivory
Khaki
Lavender
LavenderBlush
LawnGreen
LemonChiffon
LightBlue
LightCoral
LightCyan
LightGoldenRodYellow
LightGray
LightGreen
LightGrey
LightPink
LightSalmon
LightSeaGreen
LightSkyBlue
LightSlateGray
LightSlateGrey
LightSteelBlue
LightYellow
Lime
LimeGreen
Linen
MOTIVATION
Magenta
Maroon
MediumAquaMarine
MediumBlue
MediumOrchid
MediumPurple
MediumSeaGreen
MediumSlateBlue
MediumSpringGreen
MediumTurquoise
MediumVioletRed
MidnightBlue
MintCream
MistyRose
Moccasin
NavajoWhite
Navy
OldLace
Olive
OliveDrab
Orange
OrangeRed
Orchid
PHYSICAL
PaleGoldenRod
PaleGreen
PaleTurquoise
PaleVioletRed
PapayaWhip
PeachPuff
Peru
Pink
Plum
PowderBlue
Purple
Red
RosyBrown
RoyalBlue
STRATEGY
SaddleBrown
Salmon
SandyBrown
SeaGreen
SeaShell
Sienna
Silver
SkyBlue
SlateBlue
SlateGray
SlateGrey
Snow
SpringGreen
SteelBlue
TECHNOLOGY
Tan
Teal
Thistle
Tomato
Turquoise
Violet
Wheat
White
WhiteSmoke
Yellow
YellowGreen