brilliant-msg
    Preparing search index...

    Class RectangularTextLayout

    A standard rectangular text layout.

    Implements

    Index

    Constructors

    Properties

    Accessors

    Methods

    Constructors

    • Constructs a RectangularTextLayout.

      Parameters

      • options: {
            fontFamily?: string;
            fontSize: number;
            height: number;
            textAlign?: CanvasTextAlign;
            width: number;
        }

        Configuration options.

      Returns RectangularTextLayout

    Properties

    fontFamily?: string

    Optional font family name.

    fontSize: number

    The font size in pixels.

    height: number

    The height of the layout in pixels.

    textAlign: CanvasTextAlign

    Text alignment within each line.

    width: number

    The width of the layout in pixels.

    Accessors

    Methods

    • Returns the full width at xOffset 0 if the line fits vertically, null otherwise.

      Parameters

      • lineY: number
      • lineHeight: number

      Returns null | { width: number; xOffset: number }