SheetXL - v1.0.2
    Preparing search index...

    What a movable needs of its content: IMovable.IContent, and that it can be saved.

    interface Content {
        acceptFlip?(flip: Flip): Flip;
        acceptRotation?(degrees: number): number;
        delete(options?: ITransaction.OperationOptions): void;
        getConnections?(
            width: number,
            height: number,
            options?: ConnectionsOptions,
        ): readonly Connection[] | null;
        getDefaultAnchorType?(): IAnchored.Type;
        getDescription(): string | null;
        getId(): string;
        getMovable(): IMovable | null;
        getMovables?(): IMovableCollection;
        getName?(): string | null;
        getReferences(): ICellRanges | null;
        getType(): string;
        getTypeDescription(): string;
        isDefaultLockAspectRatio?(): boolean;
        isDeleted(): boolean;
        setDescription(description: string | null): this;
        setName?(name: string): this;
        toJSON(toResourceId?: (resource: IResource) => number | null): any;
    }

    Hierarchy (View Summary)

    Index
    • The flip this content takes when asked to mirror as flip states.

      Parameters

      Returns Flip

      Defined by content that can be mirrored, such as a shape or a picture; absent, the content cannot: a frame dragged through its opposite edge is moved there but not mirrored, as Excel does with a chart. Must be pure, as acceptRotation is. A connector may accept each axis on its own.

    • The rotation this content takes when asked to turn by degrees, clockwise.

      Parameters

      • degrees: number

      Returns number

      Defined by content that can be turned, such as a shape or a picture; absent, the content cannot and no rotate handle is offered. Must be pure: it is asked throughout a gesture to draw its preview, and the answer is what the movable stores.

    • The points a connector's end may be glued to, in a width by height frame of this content, before the frame is placed.

      Parameters

      Returns readonly Connection[] | null

      Absent, the four edge midpoints — top, left, bottom, right, numbered in that order, each leaving straight out — as Excel offers on a picture, a chart, a slicer or a control. A shape is the exception and answers its geometry's own sites (a triangle's three, a connector's none); a group answers none, since Excel glues to a group's members and never to the group. Must be synchronous: null means the content cannot answer yet and will call options.onReady when it can.

    • Returns the alternative text used by assistive technologies, or null if none has been set.

      Returns string | null

    • Returns the id of the content.

      Returns string

    • Returns the movable that places the content on the sheet, or null if it is not placed by one.

      Returns IMovable | null

    • The movables this content holds, for content that holds any (a group); absent, none. The movable answers it as IMovable.getMovables. Content that holds movables states them in its JSON as members, so the kinds a tree needs are loaded before it is built.

      Returns IMovableCollection

    • Returns the name, or null if the content has none.

      Returns string | null

      Not defined for content that is never named.

    • Returns the cells the content names - a chart's series, a control's linked cell, a slicer's column - or null when it names none.

      Returns ICellRanges | null

      Not where the movable sits: that is IMovable.getRange. The references are formulas the calculation engine holds, so they follow the cells they name through inserts, deletes, cuts, sheet renames and undo, and ContentEvents.onReferencesChange is announced when they have. A reference to deleted cells is left out. Without a running engine the references read as they were set.

    • Returns an immutable type string.

      Returns string

    • Returns a label for the kind of content, such as Chart or Picture.

      Returns string

    • Whether a movable of this content keeps its aspect ratio when resized from a corner, when it states no lock of its own.

      Returns boolean

      Absent, it does not. A picture does.

    • Returns true if the content has been deleted.

      Returns boolean

    • Set the alternative text used by assistive technologies.

      Parameters

      • description: string | null

      Returns this

    • Set the name.

      Parameters

      • name: string

        The name of the content.

      Returns this

    • Parameters

      • OptionaltoResourceId: (resource: IResource) => number | null

      Returns any