Sign in

    This version of the module is deprecated: Moved to moonbit-community/diago. Use moonbit-community/diago@0.4.0 or later and update import paths.

    Milky2018/diago/graph does not have a README file

    ArrowheadType

    pub(all) enum ArrowheadType {
    None
    Triangle
    Diamond
    Circle
    Open
    Line
    CfOne
    CfMany
    CfOneRequired
    CfManyRequired
    CfOneOptional
    CfManyOptional
    }

    All supported arrowhead types
    impl Eq for ArrowheadType

    ArrowheadType::from_string

    fn ArrowheadType::from_string(s : String) -> ArrowheadType

    Parse an arrowhead type from a string

    ArrowheadType::is_crows_foot

    fn ArrowheadType::is_crows_foot(self : ArrowheadType) -> Bool

    Check if this is a crow's foot notation type

    ArrowheadType::marker_id

    fn ArrowheadType::marker_id(self : ArrowheadType, reverse : Bool) -> String

    Get the SVG marker ID for this arrowhead type

    ArrowheadType::marker_url

    fn ArrowheadType::marker_url(self : ArrowheadType, reverse : Bool) -> String

    Get the marker URL for SVG use

    ArrowheadType::to_arrowhead_string

    fn ArrowheadType::to_arrowhead_string(self : ArrowheadType) -> String

    Convert arrowhead type to canonical string representation

    ArrowheadType::to_ascii

    fn ArrowheadType::to_ascii(self : ArrowheadType, reverse : Bool) -> String

    Get ASCII representation of this arrowhead

    Box

    pub struct Box {
    x : Double
    y : Double
    width : Double
    height : Double
    }

    Bounding box for positioning
    impl Eq for Box
    impl Show for Box

    Box::bottom_left

    fn Box::bottom_left(self : Box) -> Point

    Get the bottom-left corner

    Box::bottom_right

    fn Box::bottom_right(self : Box) -> Point

    Get the bottom-right corner

    Box::center

    fn Box::center(self : Box) -> Point

    Get the center point of the box

    Box::contains

    fn Box::contains(self : Box, p : Point) -> Bool

    Check if a point is inside the box

    Box::get_height

    fn Box::get_height(self : Box) -> Double

    Get height

    Box::get_width

    fn Box::get_width(self : Box) -> Double

    Get width

    Box::get_x

    fn Box::get_x(self : Box) -> Double

    Get x coordinate

    Box::get_y

    fn Box::get_y(self : Box) -> Double

    Get y coordinate

    Box::intersects

    fn Box::intersects(self : Box, other : Box) -> Bool

    Check if this box intersects another

    Box::new

    fn Box::new(x : Double, y : Double, width : Double, height : Double) -> Box

    Box::top_left

    fn Box::top_left(self : Box) -> Point

    Get the top-left corner

    Box::top_right

    fn Box::top_right(self : Box) -> Point

    Get the top-right corner

    Box::zero

    fn Box::zero() -> Box

    EdgeInput

    pub struct EdgeInput {
    index : Int
    src_id : String
    dst_id : String
    src_arrow : Bool
    dst_arrow : Bool
    src_arrowhead : ArrowheadType
    dst_arrowhead : ArrowheadType
    src_arrowhead_label : String?
    dst_arrowhead_label : String?
    src_arrowhead_label_color : String?
    dst_arrowhead_label_color : String?
    src_anchor : String?
    dst_anchor : String?
    label : String
    style : StyleInput
    route : Array[Point]
    bend_points : Array[Point]?
    is_curve : Bool
    z_index : Int
    reference_count : Int
    label_box : Box?
    src_column_index : Int?
    dst_column_index : Int?
    }

    impl Show for EdgeInput

    EdgeInput::from_model

    fn EdgeInput::from_model(edge : EdgeModel) -> EdgeInput

    EdgeInput::from_parts

    fn EdgeInput::from_parts(index : Int, src_id : String, dst_id : String, src_arrow : Bool, dst_arrow : Bool, src_arrowhead : ArrowheadType, dst_arrowhead : ArrowheadType, src_arrowhead_label : String?, dst_arrowhead_label : String?, src_arrowhead_label_color : String?, dst_arrowhead_label_color : String?, src_anchor : String?, dst_anchor : String?, label : String, style : StyleInput, route : Array[Point], bend_points : Array[Point]?, is_curve : Bool, z_index : Int, reference_count : Int, label_box : Box?, src_column_index : Int?, dst_column_index : Int?) -> EdgeInput

    EdgeInput::get_dst_id

    fn EdgeInput::get_dst_id(self : EdgeInput) -> String

    EdgeInput::get_label_box

    fn EdgeInput::get_label_box(self : EdgeInput) -> Box?

    EdgeInput::get_src_id

    fn EdgeInput::get_src_id(self : EdgeInput) -> String

    EdgeInput::new

    fn EdgeInput::new(index : Int, src_id : String, dst_id : String, src_arrow : Bool, dst_arrow : Bool) -> EdgeInput

    EdgeModel

    pub struct EdgeModel {
    index : Int
    src_id : String
    dst_id : String
    src_arrow : Bool
    dst_arrow : Bool
    src_arrowhead : ArrowheadType
    dst_arrowhead : ArrowheadType
    src_arrowhead_label : String?
    dst_arrowhead_label : String?
    src_arrowhead_label_color : String?
    dst_arrowhead_label_color : String?
    src_anchor : String?
    dst_anchor : String?
    label : String
    style : StyleModel
    route : Array[Point]
    bend_points : Array[Point]?
    is_curve : Bool
    z_index : Int
    reference_count : Int
    label_box : Box?
    src_column_index : Int?
    dst_column_index : Int?
    }

    Immutable edge model
    impl Show for EdgeModel

    EdgeModel::new

    fn EdgeModel::new(index : Int, src_id : String, dst_id : String, src_arrow : Bool, dst_arrow : Bool) -> EdgeModel

    EdgeModel::with_label

    fn EdgeModel::with_label(self : EdgeModel, label : String) -> EdgeModel

    EdgeModel::with_label_box

    fn EdgeModel::with_label_box(self : EdgeModel, label_box : Box?) -> EdgeModel

    EdgeModel::with_route

    fn EdgeModel::with_route(self : EdgeModel, route : Array[Point]) -> EdgeModel

    FragmentOperandInput

    pub struct FragmentOperandInput {
    condition : String?
    }

    FragmentOperandInput::new

    fn FragmentOperandInput::new(condition : String?) -> FragmentOperandInput

    FragmentOperandLayout

    pub struct FragmentOperandLayout {
    condition : String?
    separator_y : Double
    }

    FragmentOperandLayout::new

    fn FragmentOperandLayout::new(condition : String?, separator_y : Double) -> FragmentOperandLayout

    FragmentOperandModel

    pub struct FragmentOperandModel {
    condition : String?
    separator_y : Double
    }

    GraphInput

    pub struct GraphInput {
    name : String
    root : ObjectInput
    objects : Array[ObjectInput]
    edges : Array[EdgeInput]
    sequence_fragments : Array[SequenceFragmentInput]
    activation_boxes : Array[(String, Box)]
    sequence_notes : Array[(String, String, Box)]
    sequence_fragments_layout : Array[SequenceFragmentLayout]
    layers : Array[LayerInput]
    scenarios : Array[ScenarioInput]
    steps : Array[StepInput]
    legend : LegendInput?
    }

    impl Show for GraphInput

    GraphInput::children_of

    fn GraphInput::children_of(self : GraphInput, obj : ObjectInput) -> Array[ObjectInput]

    GraphInput::find_object

    fn GraphInput::find_object(self : GraphInput, id : String) -> ObjectInput?

    GraphInput::from_model

    fn GraphInput::from_model(graph : GraphModel) -> GraphInput

    GraphInput::from_parts

    fn GraphInput::from_parts(name : String, root : ObjectInput, objects : Array[ObjectInput], edges : Array[EdgeInput], sequence_fragments : Array[SequenceFragmentInput], activation_boxes : Array[(String, Box)], sequence_notes : Array[(String, String, Box)], sequence_fragments_layout : Array[SequenceFragmentLayout], layers : Array[LayerInput], scenarios : Array[ScenarioInput], steps : Array[StepInput], legend : LegendInput?) -> GraphInput

    GraphInput::get_edges

    fn GraphInput::get_edges(self : GraphInput) -> Array[EdgeInput]

    GraphInput::get_objects

    fn GraphInput::get_objects(self : GraphInput) -> Array[ObjectInput]

    GraphInput::new

    fn GraphInput::new(name : String) -> GraphInput

    GraphModel

    pub struct GraphModel {
    name : String
    root : ObjectModel
    objects : Array[ObjectModel]
    edges : Array[EdgeModel]
    activation_boxes : Array[(String, Box)]
    sequence_notes : Array[(String, String, Box)]
    sequence_fragments : Array[SequenceFragmentModel]
    layers : Array[LayerModel]
    scenarios : Array[ScenarioModel]
    steps : Array[StepModel]
    legend : LegendModel?
    }

    Immutable graph model
    impl Show for GraphModel

    GraphModel::add_edge

    fn GraphModel::add_edge(self : GraphModel, edge : EdgeModel) -> GraphModel

    GraphModel::add_object

    fn GraphModel::add_object(self : GraphModel, obj : ObjectModel) -> GraphModel

    GraphModel::new

    fn GraphModel::new(name : String) -> GraphModel

    GraphModel::with_legend

    fn GraphModel::with_legend(self : GraphModel, legend : LegendModel?) -> GraphModel

    LayerInput

    pub struct LayerInput {
    name : String
    graph : GraphInput
    }

    impl Show for LayerInput

    LayerInput::new

    fn LayerInput::new(name : String, graph : GraphInput) -> LayerInput

    LayerModel

    pub struct LayerModel {
    name : String
    graph : GraphModel
    }

    impl Show for LayerModel

    LayoutPatch

    pub struct LayoutPatch {
    nodes : Map[String, Box]
    node_labels : Map[String, Box]
    edges : Map[Int, Array[Point]]
    edge_bend_points : Map[Int, Array[Point]]
    edge_curves : Map[Int, Bool]
    edge_labels : Map[Int, Box]
    activation_boxes : Array[(String, Box)]
    sequence_notes : Array[(String, String, Box)]
    sequence_fragments : Array[SequenceFragmentLayout]
    }

    impl Show for LayoutPatch

    LayoutPatch::new

    Legend

    pub struct Legend {
    title : String?
    position : LegendPosition
    entries : Array[LegendEntry]
    fill : String?
    stroke : String?
    padding : Double
    entry_gap : Double
    icon_size : Double
    }

    The legend configuration for a diagram
    impl Show for Legend

    Legend::add_connection

    fn Legend::add_connection(self : Legend, src_arrow : ArrowheadType, dst_arrow : ArrowheadType, label : String) -> Unit

    Add a connection entry to the legend

    Legend::add_entry

    fn Legend::add_entry(self : Legend, entry : LegendEntry) -> Unit

    Add an entry to the legend

    Legend::add_separator

    fn Legend::add_separator(self : Legend) -> Unit

    Add a separator to the legend

    Legend::add_shape

    fn Legend::add_shape(self : Legend, shape : ShapeType, label : String) -> Unit

    Add a shape entry to the legend

    Legend::entry_count

    fn Legend::entry_count(self : Legend) -> Int

    Get the number of entries (excluding separators)

    Legend::is_empty

    fn Legend::is_empty(self : Legend) -> Bool

    Check if legend has any entries

    Legend::new

    fn Legend::new() -> Legend

    Create a new legend with default settings

    Legend::set_entry_gap

    fn Legend::set_entry_gap(self : Legend, entry_gap : Double) -> Legend

    Legend::set_fill

    fn Legend::set_fill(self : Legend, fill : String) -> Legend

    Legend::set_icon_size

    fn Legend::set_icon_size(self : Legend, icon_size : Double) -> Legend

    Legend::set_padding

    fn Legend::set_padding(self : Legend, padding : Double) -> Legend

    Legend::set_position

    fn Legend::set_position(self : Legend, position : LegendPosition) -> Legend

    Legend::set_stroke

    fn Legend::set_stroke(self : Legend, stroke : String) -> Legend

    Legend::set_title

    fn Legend::set_title(self : Legend, title : String) -> Legend

    Legend::with_position

    fn Legend::with_position(position : LegendPosition) -> Legend

    Create a legend with a specific position

    LegendEntry

    pub(all) enum LegendEntry {
    ShapeEntry(ShapeType, String, StyleInput?)
    ConnectionEntry(ArrowheadType, ArrowheadType, String, StyleInput?)
    CustomEntry(String, String)
    Separator
    }

    A single entry in the legend
    impl Show for LegendEntry

    LegendEntry::connection

    fn LegendEntry::connection(src_arrow : ArrowheadType, dst_arrow : ArrowheadType, label : String, style : StyleInput?) -> LegendEntry

    Create a connection legend entry

    LegendEntry::custom

    fn LegendEntry::custom(icon : String, label : String) -> LegendEntry

    Create a custom legend entry

    LegendEntry::separator

    fn LegendEntry::separator() -> LegendEntry

    Create a separator entry

    LegendEntry::shape

    fn LegendEntry::shape(shape : ShapeType, label : String, style : StyleInput?) -> LegendEntry

    Create a shape legend entry

    LegendEntryInput

    pub enum LegendEntryInput {
    ShapeEntry(ShapeType, String, StyleInput?)
    ConnectionEntry(ArrowheadType, ArrowheadType, String, StyleInput?)
    CustomEntry(String, String)
    Separator
    }

    LegendEntryInput::connection

    fn LegendEntryInput::connection(src_arrow : ArrowheadType, dst_arrow : ArrowheadType, label : String, style : StyleInput?) -> LegendEntryInput

    LegendEntryInput::custom

    fn LegendEntryInput::custom(icon : String, label : String) -> LegendEntryInput

    LegendEntryInput::separator

    LegendEntryInput::shape

    fn LegendEntryInput::shape(shape : ShapeType, label : String, style : StyleInput?) -> LegendEntryInput

    LegendInput

    pub struct LegendInput {
    title : String?
    position : LegendPosition
    entries : Array[LegendEntryInput]
    fill : String?
    stroke : String?
    padding : Double
    entry_gap : Double
    icon_size : Double
    }

    impl Show for LegendInput

    LegendInput::entry_count

    fn LegendInput::entry_count(self : LegendInput) -> Int

    LegendInput::from_model

    fn LegendInput::from_model(legend : LegendModel) -> LegendInput

    LegendInput::from_parts

    fn LegendInput::from_parts(title : String?, position : LegendPosition, entries : Array[LegendEntryInput], fill : String?, stroke : String?, padding : Double, entry_gap : Double, icon_size : Double) -> LegendInput

    LegendInput::is_empty

    fn LegendInput::is_empty(self : LegendInput) -> Bool

    LegendModel

    pub struct LegendModel {
    title : String?
    position : LegendPosition
    entries : Array[LegendEntryInput]
    fill : String?
    stroke : String?
    padding : Double
    entry_gap : Double
    icon_size : Double
    }

    Immutable legend configuration
    impl Show for LegendModel

    LegendModel::new

    LegendPosition

    pub(all) enum LegendPosition {
    TopLeft
    TopRight
    BottomLeft
    BottomRight
    Hidden
    }

    Position of the legend in the diagram

    LegendPosition::from_string

    fn LegendPosition::from_string(s : String) -> LegendPosition

    Parse legend position from string

    LegendPosition::to_position_string

    fn LegendPosition::to_position_string(self : LegendPosition) -> String

    Convert legend position to string

    ObjectInput

    pub struct ObjectInput {
    id : String
    label : String
    shape_type : ShapeType
    style : StyleInput
    box : Box?
    label_box : Box?
    child_ids : Array[String]
    z_index : Int
    icon : String?
    tooltip : String?
    link : String?
    classes : Array[String]
    grid_rows : Int?
    grid_columns : Int?
    grid_gap : Double?
    horizontal_gap : Double?
    vertical_gap : Double?
    grid_column_span : Int?
    grid_row_span : Int?
    near : String?
    top : Int?
    left : Int?
    }

    Immutable representation of a graph object for layout engines.

    Fields:

    • id : Unique identifier for the object.
    • label : Display text for the object.
    • shape_type : Visual shape of the object.
    • style : Visual styling properties.
    • box : Optional precomputed bounding box.
    • label_box : Optional precomputed label bounding box.
    • child_ids : Array of child object identifiers.
    • z_index : Layer ordering for visual stacking.
    • icon : Optional icon identifier.
    • tooltip : Optional tooltip text.
    • link : Optional hyperlink URL.
    • classes : Array of CSS class names for styling.
    • grid_rows : Optional number of grid rows for layout.
    • grid_columns : Optional number of grid columns for layout.
    • grid_gap : Optional spacing between grid items.
    • horizontal_gap : Optional horizontal spacing between children.
    • vertical_gap : Optional vertical spacing between children.
    • grid_column_span : Optional number of columns this object spans.
    • grid_row_span : Optional number of rows this object spans.
    • near : Optional identifier of object to position near.
    • top : Optional fixed top coordinate in pixels.
    • left : Optional fixed left coordinate in pixels.

    impl Show for ObjectInput

    ObjectInput::from_model

    fn ObjectInput::from_model(obj : ObjectModel) -> ObjectInput

    ObjectInput::from_parts

    fn ObjectInput::from_parts(id : String, label : String, shape_type : ShapeType, style : StyleInput, box : Box?, label_box : Box?, child_ids : Array[String], z_index : Int, icon : String?, tooltip : String?, link : String?, classes : Array[String], grid_rows : Int?, grid_columns : Int?, grid_gap : Double?, horizontal_gap : Double?, vertical_gap : Double?, grid_column_span : Int?, grid_row_span : Int?, near : String?, top : Int?, left : Int?) -> ObjectInput

    ObjectInput::get_box

    fn ObjectInput::get_box(self : ObjectInput) -> Box?

    ObjectInput::get_label_box

    fn ObjectInput::get_label_box(self : ObjectInput) -> Box?

    ObjectInput::new

    fn ObjectInput::new(id : String) -> ObjectInput

    ObjectModel

    pub struct ObjectModel {
    id : String
    label : String
    shape_type : ShapeType
    style : StyleModel
    box : Box?
    label_box : Box?
    children : Array[ObjectModel]
    z_index : Int
    icon : String?
    tooltip : String?
    link : String?
    classes : Array[String]
    grid_rows : Int?
    grid_columns : Int?
    grid_gap : Double?
    horizontal_gap : Double?
    vertical_gap : Double?
    grid_column_span : Int?
    grid_row_span : Int?
    near : String?
    top : Int?
    left : Int?
    }

    Immutable object model
    impl Show for ObjectModel

    ObjectModel::add_child

    fn ObjectModel::add_child(self : ObjectModel, child : ObjectModel) -> ObjectModel

    ObjectModel::new

    fn ObjectModel::new(id : String) -> ObjectModel

    ObjectModel::with_box

    fn ObjectModel::with_box(self : ObjectModel, box : Box?) -> ObjectModel

    ObjectModel::with_label

    fn ObjectModel::with_label(self : ObjectModel, label : String) -> ObjectModel

    Functional helpers

    ObjectModel::with_label_box

    fn ObjectModel::with_label_box(self : ObjectModel, label_box : Box?) -> ObjectModel

    Point

    pub struct Point {
    x : Double
    y : Double
    }

    A 2D point
    impl Eq for Point
    impl Show for Point

    Point::add

    fn Point::add(self : Point, other : Point) -> Point

    Add two points

    Point::distance

    fn Point::distance(self : Point, other : Point) -> Double

    Calculate distance to another point

    Point::get_x

    fn Point::get_x(self : Point) -> Double

    Get x coordinate

    Point::get_y

    fn Point::get_y(self : Point) -> Double

    Get y coordinate

    Point::new

    fn Point::new(x : Double, y : Double) -> Point

    Point::scale

    fn Point::scale(self : Point, factor : Double) -> Point

    Scale by a factor

    Point::sub

    fn Point::sub(self : Point, other : Point) -> Point

    Subtract another point

    Point::zero

    fn Point::zero() -> Point

    Route

    pub struct Route {
    style : RouteStyle
    waypoints : Array[Waypoint]
    src_arrowhead : ArrowheadType
    dst_arrowhead : ArrowheadType
    }

    Route configuration for an edge
    impl Show for Route

    Route::add_point

    fn Route::add_point(self : Route, x : Double, y : Double) -> Unit

    Add a simple point to the route

    Route::add_waypoint

    fn Route::add_waypoint(self : Route, wp : Waypoint) -> Unit

    Add a waypoint to the route

    Route::end

    fn Route::end(self : Route) -> Waypoint?

    Get the ending point of the route

    Route::from_points

    fn Route::from_points(points : Array[Point], style : RouteStyle, src : ArrowheadType, dst : ArrowheadType) -> Route

    Convert from Edge's simple route (Array[Point]) to Route

    Route::is_empty

    fn Route::is_empty(self : Route) -> Bool

    Check if route has any waypoints

    Route::length

    fn Route::length(self : Route) -> Int

    Get the number of waypoints

    Route::new

    fn Route::new() -> Route

    Create a new empty route with default style

    Route::start

    fn Route::start(self : Route) -> Waypoint?

    Get the starting point of the route

    Route::to_points

    fn Route::to_points(self : Route) -> Array[Point]

    Get all points as a simple array (for backward compatibility)

    Route::with_style

    fn Route::with_style(style : RouteStyle) -> Route

    Create a route with specified style

    RouteStyle

    pub(all) enum RouteStyle {
    Straight
    Curved
    Elbow
    Orthogonal
    }

    Route style for edge paths
    impl Eq for RouteStyle
    impl Show for RouteStyle

    RouteStyle::from_string

    fn RouteStyle::from_string(s : String) -> RouteStyle

    Parse route style from string

    RouteStyle::is_curved

    fn RouteStyle::is_curved(self : RouteStyle) -> Bool

    Check if this style uses curves

    RouteStyle::is_orthogonal

    fn RouteStyle::is_orthogonal(self : RouteStyle) -> Bool

    Check if this style uses right angles

    RouteStyle::to_route_string

    fn RouteStyle::to_route_string(self : RouteStyle) -> String

    Convert route style to canonical string

    ScenarioInput

    pub struct ScenarioInput {
    name : String
    graph : GraphInput
    }

    ScenarioInput::new

    fn ScenarioInput::new(name : String, graph : GraphInput) -> ScenarioInput

    ScenarioModel

    pub struct ScenarioModel {
    name : String
    graph : GraphModel
    }

    SequenceFragmentInput

    pub struct SequenceFragmentInput {
    fragment_type : String
    condition : String?
    start_index : Int
    end_index : Int
    operands : Array[FragmentOperandInput]
    }

    SequenceFragmentInput::from_model

    SequenceFragmentInput::new

    fn SequenceFragmentInput::new(fragment_type : String, condition : String?, start_index : Int, end_index : Int, operands : Array[FragmentOperandInput]) -> SequenceFragmentInput

    SequenceFragmentLayout

    pub struct SequenceFragmentLayout {
    fragment_type : String
    condition : String?
    bbox : Box?
    start_index : Int
    end_index : Int
    operands : Array[FragmentOperandLayout]
    }

    SequenceFragmentLayout::new

    fn SequenceFragmentLayout::new(fragment_type : String, condition : String?, bbox : Box?, start_index : Int, end_index : Int, operands : Array[FragmentOperandLayout]) -> SequenceFragmentLayout

    SequenceFragmentModel

    pub struct SequenceFragmentModel {
    fragment_type : String
    condition : String?
    bbox : Box?
    start_index : Int
    end_index : Int
    operands : Array[FragmentOperandModel]
    }

    Immutable sequence fragment

    SequenceFragmentModel::new

    fn SequenceFragmentModel::new(fragment_type : String, start_index : Int, end_index : Int) -> SequenceFragmentModel

    ShapeType

    pub(all) enum ShapeType {
    Rectangle
    Square
    Circle
    Oval
    Diamond
    Hexagon
    Parallelogram
    Cylinder
    Queue
    Package
    Step
    Callout
    StoredData
    Person
    Cloud
    Page
    Document
    Class
    SqlTable
    Text
    Code
    Image
    SequenceDiagram
    Octagon
    C4Person
    C4Container
    }

    All supported shape types
    impl Eq for ShapeType
    impl Show for ShapeType

    ShapeType::default_aspect_ratio

    fn ShapeType::default_aspect_ratio(self : ShapeType) -> Double

    Get the default aspect ratio for the shape (width / height)

    ShapeType::from_string

    fn ShapeType::from_string(s : String) -> ShapeType

    Parse a shape type from a string

    ShapeType::has_inside_label

    fn ShapeType::has_inside_label(self : ShapeType) -> Bool

    Check if this shape renders its label inside the shape

    ShapeType::is_3d_shape

    fn ShapeType::is_3d_shape(self : ShapeType) -> Bool

    Check if this shape needs special 3D rendering

    ShapeType::is_container

    fn ShapeType::is_container(self : ShapeType) -> Bool

    Check if this shape is a container type (can have structured children)

    ShapeType::is_text_only

    fn ShapeType::is_text_only(self : ShapeType) -> Bool

    Check if this shape is a text-only type (no border)

    ShapeType::to_shape_string

    fn ShapeType::to_shape_string(self : ShapeType) -> String

    Convert shape type to canonical string representation

    StepInput

    pub struct StepInput {
    name : String
    graph : GraphInput
    }

    impl Show for StepInput

    StepInput::new

    fn StepInput::new(name : String, graph : GraphInput) -> StepInput

    StepModel

    pub struct StepModel {
    name : String
    graph : GraphModel
    }

    impl Show for StepModel

    StyleInput

    pub struct StyleInput {
    opacity : StyleValue?
    stroke : StyleValue?
    fill : StyleValue?
    stroke_width : StyleValue?
    stroke_dash : StyleValue?
    border_radius : StyleValue?
    shadow : StyleValue?
    three_d : StyleValue?
    multiple : StyleValue?
    font : StyleValue?
    font_size : StyleValue?
    font_color : StyleValue?
    bold : StyleValue?
    italic : StyleValue?
    underline : StyleValue?
    animated : StyleValue?
    filled : StyleValue?
    double_border : StyleValue?
    text_transform : StyleValue?
    font_family : StyleValue?
    fill_pattern : StyleValue?
    sketch : StyleValue?
    curved : StyleValue?
    }

    impl Eq for StyleInput
    impl Show for StyleInput

    StyleInput::from_model

    fn StyleInput::from_model(style : StyleModel) -> StyleInput

    StyleInput::from_parts

    fn StyleInput::from_parts(opacity : StyleValue?, stroke : StyleValue?, fill : StyleValue?, stroke_width : StyleValue?, stroke_dash : StyleValue?, border_radius : StyleValue?, shadow : StyleValue?, three_d : StyleValue?, multiple : StyleValue?, font : StyleValue?, font_size : StyleValue?, font_color : StyleValue?, bold : StyleValue?, italic : StyleValue?, underline : StyleValue?, animated : StyleValue?, filled : StyleValue?, double_border : StyleValue?, text_transform : StyleValue?, font_family : StyleValue?, fill_pattern : StyleValue?, sketch : StyleValue?, curved : StyleValue?) -> StyleInput

    StyleInput::new

    fn StyleInput::new() -> StyleInput

    StyleModel

    pub struct StyleModel {
    opacity : StyleValue?
    stroke : StyleValue?
    fill : StyleValue?
    stroke_width : StyleValue?
    stroke_dash : StyleValue?
    border_radius : StyleValue?
    shadow : StyleValue?
    three_d : StyleValue?
    multiple : StyleValue?
    font : StyleValue?
    font_size : StyleValue?
    font_color : StyleValue?
    bold : StyleValue?
    italic : StyleValue?
    underline : StyleValue?
    animated : StyleValue?
    filled : StyleValue?
    double_border : StyleValue?
    text_transform : StyleValue?
    font_family : StyleValue?
    fill_pattern : StyleValue?
    sketch : StyleValue?
    curved : StyleValue?
    }

    Immutable style model
    impl Eq for StyleModel
    impl Show for StyleModel

    StyleModel::new

    fn StyleModel::new() -> StyleModel

    StyleValue

    pub struct StyleValue {
    value : String
    range :
    Range

    }

    A style value with its source range.

    The value is preserved as a string. Consumers may parse it as needed.
    impl Eq for StyleValue
    impl Show for StyleValue

    StyleValue::as_bool

    fn StyleValue::as_bool(self : StyleValue) -> Bool?

    StyleValue::as_double

    fn StyleValue::as_double(self : StyleValue) -> Double?

    StyleValue::as_int

    fn StyleValue::as_int(self : StyleValue) -> Int?

    StyleValue::from_bool

    fn StyleValue::from_bool(value : Bool) -> StyleValue

    StyleValue::from_bool_opt

    fn StyleValue::from_bool_opt(value : Bool?) -> StyleValue?

    StyleValue::from_double

    fn StyleValue::from_double(value : Double) -> StyleValue

    StyleValue::from_double_opt

    fn StyleValue::from_double_opt(value : Double?) -> StyleValue?

    StyleValue::from_int

    fn StyleValue::from_int(value : Int) -> StyleValue

    StyleValue::from_int_opt

    fn StyleValue::from_int_opt(value : Int?) -> StyleValue?

    StyleValue::from_string

    fn StyleValue::from_string(value : String) -> StyleValue

    StyleValue::from_string_opt

    fn StyleValue::from_string_opt(value : String?) -> StyleValue?

    StyleValue::get_range

    StyleValue::get_value

    fn StyleValue::get_value(self : StyleValue) -> String

    StyleValue::new

    fn StyleValue::new(value : String, range :
    Range
    ) -> StyleValue

    StyleValue::synthetic

    fn StyleValue::synthetic(value : String) -> StyleValue

    Create a style value without a concrete source location.

    Waypoint

    pub struct Waypoint {
    x : Double
    y : Double
    control : (Double, Double)?
    }

    A waypoint along an edge route
    impl Show for Waypoint

    Waypoint::new

    fn Waypoint::new(x : Double, y : Double) -> Waypoint

    Create a simple waypoint

    Waypoint::to_point

    fn Waypoint::to_point(self : Waypoint) -> Point

    Convert waypoint to Point

    Waypoint::with_control

    fn Waypoint::with_control(x : Double, y : Double, cx : Double, cy : Double) -> Waypoint

    Create a waypoint with a bezier control point

    apply_layout

    fn apply_layout(graph : GraphInput, patch : LayoutPatch) -> GraphInput