Podium.Connector (Podium v0.3.0)

Copy Markdown View Source

Connector shapes between two points.

Supports straight, elbow (bent), and curved connector types. Flip attributes are calculated automatically from start/end coordinates.

Summary

Functions

Creates a new connector shape between two points.

Generates the <p:cxnSp> XML for the connector shape.

Types

t()

@type t() :: %Podium.Connector{
  connector_type: String.t(),
  flip_h: boolean(),
  flip_v: boolean(),
  height: non_neg_integer(),
  id: pos_integer(),
  line: Podium.line() | nil,
  name: String.t(),
  width: non_neg_integer(),
  x: non_neg_integer(),
  y: non_neg_integer()
}

Functions

new(id, connector_type, begin_x, begin_y, end_x, end_y, opts \\ [])

Creates a new connector shape between two points.

Parameters

  • id - shape ID within the slide
  • connector_type - :straight, :elbow, or :curved
  • begin_x, begin_y - start point coordinates
  • end_x, end_y - end point coordinates

Options

  • :line - line color string or keyword list with :color, :width, :dash_style

to_xml(conn)

@spec to_xml(t()) :: String.t()

Generates the <p:cxnSp> XML for the connector shape.