Options
All
  • Public
  • Public/Protected
  • All
Menu

An action that can be undone and redone. For example, editing a shape (see the EditController's EditShape event).

You usually create undoables in response to an event from the API, and then add them to an UndoManager.

This example shows how to create Undoables in LuciadRIA:

You can find the full source, and more examples in samples/common/util/SampleUndoSupport.ts.

Common events are:

Hierarchy

  • Undoable

Overview

Constructors

Accessors

Methods

Constructors

constructor

  • Creates a new Undoable

    Parameters

    • id: string

      An id for the Undoable. This id is not used by the UndoManager, but it can be useful for differentiating between undoables in your application.

    • label: string

      A label for the Undoable. This can be a string you display directly in the UI, or a translation key.

    Returns Undoable

Accessors

id

  • get id(): string
  • An id for the Undoable. This id is not used by the UndoManager, but it can be useful for differentiating between undoables in your application.

    Returns string

label

  • get label(): string
  • A label for the Undoable. This can be a string you display directly in the UI, or a translation key.

    Returns string

Methods

Abstract redo

  • (): void
  • Redoes the operation represented by this Undoable

    Returns void

Abstract undo

  • (): void
  • Undoes the operation represented by this Undoable

    Returns void

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method