Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

This is preliminary documentation. You've been warned.

KIML defines a whole set of standard layout options that many layout algorithms support. Whether an algorithm supports a layout option depends on the option and on the algorithm. Algorithms may provide more specialized documentation for a given layout option.

Contents

Overview

Beside a human-readable name, layout options are defined by the following properties:

  • An ID to identify them.
  • A type. One of Boolean, String, Int, Float, Enum, EnumSet (a Set over a given enumeration), or Object. The types Enum and EnumSet have to be further defined by an enumeration class. The Object type can be constricted to a certain class.
  • An optional definition of what kinds of graph objects the option applies to. At least one of Parents (nodes that have children, including the diagram root node), Nodes, Edges, Ports, and Labels. If this definition is omitted, a layout option will not be shown to the user in the UI, but can still be set programmatically.
  • An optional default value. If an option is not set on an object and if the option does not have a default value, null is returned when it is accessed.

KIML defines the following set of layout options:

OptionIDTypeApplies toDefault
Alignmentde.cau.cs.kieler.alignmentEnumNodesAUTOMATIC
Aspect Ratiode.cau.cs.kieler.aspectRatioFloatParents0.0
Bend Pointsde.cau.cs.kieler.bendPointsObjectEdges 
Border Spacingde.cau.cs.kieler.borderSpacingFloatParents-1.0
Comment Boxde.cau.cs.kieler.commentBoxBoolean false
Debug Modede.cau.cs.kieler.debugModeBooleanParentsfalse
Diagram Typede.cau.cs.kieler.diagramTypeString  
Directionde.cau.cs.kieler.directionEnumParentsUNDEFINED
Edge Label Placementde.cau.cs.kieler.edgeLabelPlacementEnum UNDEFINED
Edge Routingde.cau.cs.kieler.edgeRoutingEnumParentsUNDEFINED
Edge Typede.cau.cs.kieler.edgeTypeEnum NONE
Expand Nodesde.cau.cs.kieler.expandNodesBooleanParentsfalse
Font Namede.cau.cs.kieler.fontNameString  
Font Sizede.cau.cs.kieler.fontSizeInt  
Hypernodede.cau.cs.kieler.hypernodeBoolean false
Interactivede.cau.cs.kieler.interactiveBooleanParentsfalse
Label Spacingde.cau.cs.kieler.labelSpacingFloatEdges
Nodes
-1.0
Layout Hierarchyde.cau.cs.kieler.layoutHierarchyBooleanParentsfalse
Layout Algorithmde.cau.cs.kieler.algorithmStringParents 
Minimal Heightde.cau.cs.kieler.minHeightFloat 0.0
Minimal Widthde.cau.cs.kieler.minWidthFloat 0.0
No Layoutde.cau.cs.kieler.noLayoutBoolean false
Node Label Placementde.cau.cs.kieler.nodeLabelPlacementEnumSetNodes 
Port Constraintsde.cau.cs.kieler.portConstraintsEnumNodesUNDEFINED
Port Label Placementde.cau.cs.kieler.portLabelPlacementEnumNodesOUTSIDE
Port Offsetde.cau.cs.kieler.offsetFloat  
Port Sidede.cau.cs.kieler.portSideEnum UNDEFINED
Positionde.cau.cs.kieler.positionObject

Labels
Nodes
Ports

 
Priorityde.cau.cs.kieler.priorityIntEdges
Nodes
 
Randomization Seedde.cau.cs.kieler.randomSeedIntParents 
Separate Connected Componentsde.cau.cs.kieler.separateConnCompBooleanParents 
Size Constraintde.cau.cs.kieler.sizeConstraintEnumSetNodes 
Size Optionsde.cau.cs.kieler.sizeOptionsEnumSetNodesDEFAULT_MINIMUM_SIZE
Spacingde.cau.cs.kieler.spacingFloatParents-1.0

The Most Important Options

TODO: Write a bit of documentation about the most important layout options and how to use them, possibly with a simple example or something.

Detailed Documentation

This section explains every layout option in more detail.

Port Offset

The port offset is used to specify how much space a layout algorithm should leave between a port and the border of its node. This is usually zero, but doesn't have to be. If the offset is not defined for a given port, a layout algorithm can try to infer the offset from the port's coordinates and its node's size in the input graph. This of course requires both properties to be set to sensible values.

  • No labels