Hello,
I'm using this code to layout a diagram:
rep.GetProjectInterface().LayoutDiagramEx(diagram.GetDiagramGUID(), 0, 4, 20, 20, true);
rep.RefreshModelView(1);
diagram.Update();
This is working great, except I don't how to use the ConstLayoutStyles Enum in java
http://www.sparxsystems.com/enterprise_architect_user_guide/9.0/automation/constlayoutstylesenum.htmlThe LayoutDiagramEx methods takes these parameters:
LayoutDiagramEx (string
DiagramGUID, long
LayoutStyle, long Iterations,
long LayerSpacing, long
ColumnSpacing, boolean
SaveToDiagram)
The LayoutStyle which is a long, can take the values of the ConstLayoutStyles Enum, yet I don't know what are those values.
In the sdk documentation, it is said:
LayoutStyleaccepts the following options (also see
ConstLayoutStyles Enum ):
· Default Options:
lsDiagramDefault
lsProgramDefault.
· Cycle Removal Options:
lsCycleRemoveGreedy
lsCycleRemoveDFS.
· Layering Options:
lsLayeringLongestPathSink
lsLayeringLongestPathSource
lsLayeringOptimalLinkLength.
· Initialize Options:
IsInitializeNaive
IsInitializeDFSOut
IsInitializeDFSIn.
· Crossing Reduction Option:
lsCrossReduceAggressive.
· Layout Options - Direction
lsLayoutDirectionUp
lsLayoutDirectionDown
lsLayoutDirectionLeft
lsLayoutDirectionRight.For example, if I want to have the option "lsLayoutDirectionLeft", what will be the value of the long LayoutStyle in LayoutDiagramEx, and how do you find this value.
Thanks in advance,
Kevin