Interface defining properties for Fabric.js text objects. TextType

interface TextType {
    angle?: number;
    center?: number;
    evented: boolean;
    fill?: string;
    fontFamily?: string;
    fontSize?: number;
    fontWeight?: string;
    left?: number;
    objectCaching: boolean;
    right?: number;
    selectable: boolean;
    stroke?: string;
    top?: number;
    [key: string]: any;
}

Indexable

  • [key: string]: any

Properties

angle?: number

Rotation angle in degrees.

center?: number

Center position in pixels.

evented: boolean

Whether the text responds to events.

fill?: string

Fill color.

fontFamily?: string

Font family.

fontSize?: number

Font size in pixels.

fontWeight?: string

Font weight.

left?: number

Left position in pixels.

objectCaching: boolean

Whether to cache the text object.

right?: number

Right position in pixels.

selectable: boolean

Whether the text is selectable.

stroke?: string

Stroke color.

top?: number

Top position in pixels.