Class PortLayout
Shared geometry for a block node's input/output ports, so the node view (which draws the port
dots) and EdgeDrawableControl (which anchors arrows to them) agree exactly.
The pipeline flows top→down: inputs sit on the top edge, the output on the bottom edge.
Coordinates are canvas-space; the fallback size matches VertexViewModel defaults.
Assembly: MOSAIC.dll
Syntax
public static class PortLayout
Fields
Diameter
Declaration
public const double Diameter = 16
Field Value
FallbackHeight
Declaration
private const double FallbackHeight = 45
Field Value
FallbackWidth
Declaration
private const double FallbackWidth = 132
Field Value
Radius
Declaration
public const double Radius = 8
Field Value
Methods
Center(VertexViewModel)
Centre of v (fallback anchor when a block has no input ports).
Declaration
public static Point Center(VertexViewModel v)
Parameters
Returns
Canvas-space anchor of input port index (of count
total) on the top edge of v, evenly distributed left-to-right.
Declaration
public static Point InputAnchor(VertexViewModel v, int index, int count)
Parameters
Returns
OutputAnchor(VertexViewModel)
Canvas-space anchor of the output port on the bottom edge of v.
Declaration
public static Point OutputAnchor(VertexViewModel v)
Parameters
Returns