Class WSBehaviors

Implements

Accessors

  • get currentPenStyle(): TPenStyle
  • Returns TPenStyle

  • get model(): Model
  • Returns Model

  • get penStyle(): TPenStyle
  • Returns TPenStyle

  • get penStyleClasses(): string
  • Returns string

  • get theme(): TTheme
  • Returns TTheme

Constructors

  • Parameters

    • options: {
          behaviors?: { grabber?: { attach?: {} | undefined; detach?: {} | undefined; onPointerDown?: {} | undefined; onPointerMove?: {} | undefined; onPointerUp?: {} | undefined; } | undefined; recognizer?: { ...; } | ... 2 more ... | undefined; menu?: { ...; } | undefined; gesture?: { ...; } | undefined; snap?: { ...; } | undefined; };
          configuration?: { offscreen?: boolean | undefined; server?: { protocol?: TProtocol | undefined; scheme?: TSchene | undefined; host?: string | undefined; applicationKey?: string | undefined; hmacKey?: string | undefined; version?: string | undefined; useWindowLocation?: boolean | undefined; websocket?: { ...; } | undefined; } | unde...;
          fontStyle?: { size?: number | undefined; weight?: "normal" | "bold" | undefined; };
          logger?: { readonly EDITOR?: LoggerLevel | undefined; readonly RECOGNIZER?: LoggerLevel | undefined; readonly GRABBER?: LoggerLevel | undefined; ... 16 more ...; readonly MENU?: LoggerLevel | undefined; };
          penStyle?: { width?: number | undefined; color?: string | undefined; opacity?: number | undefined; fill?: string | undefined; };
          theme?: { [x: string]: unknown; ink?: { width?: number | undefined; color?: string | undefined; opacity?: number | undefined; fill?: string | undefined; "-myscript-pen-width"?: number | undefined; "-myscript-pen-fill-style"?: string | undefined; "-myscript-pen-fill-color"?: string | undefined; } | undefined; ".math"?: { ......;
      }
      • Optional behaviors?: { grabber?: { attach?: {} | undefined; detach?: {} | undefined; onPointerDown?: {} | undefined; onPointerMove?: {} | undefined; onPointerUp?: {} | undefined; } | undefined; recognizer?: { ...; } | ... 2 more ... | undefined; menu?: { ...; } | undefined; gesture?: { ...; } | undefined; snap?: { ...; } | undefined; }
      • Optional configuration?: { offscreen?: boolean | undefined; server?: { protocol?: TProtocol | undefined; scheme?: TSchene | undefined; host?: string | undefined; applicationKey?: string | undefined; hmacKey?: string | undefined; version?: string | undefined; useWindowLocation?: boolean | undefined; websocket?: { ...; } | undefined; } | unde...
      • Optional fontStyle?: { size?: number | undefined; weight?: "normal" | "bold" | undefined; }
      • Optional logger?: { readonly EDITOR?: LoggerLevel | undefined; readonly RECOGNIZER?: LoggerLevel | undefined; readonly GRABBER?: LoggerLevel | undefined; ... 16 more ...; readonly MENU?: LoggerLevel | undefined; }
      • Optional penStyle?: { width?: number | undefined; color?: string | undefined; opacity?: number | undefined; fill?: string | undefined; }
      • Optional theme?: { [x: string]: unknown; ink?: { width?: number | undefined; color?: string | undefined; opacity?: number | undefined; fill?: string | undefined; "-myscript-pen-width"?: number | undefined; "-myscript-pen-fill-style"?: string | undefined; "-myscript-pen-fill-color"?: string | undefined; } | undefined; ".math"?: { ......

    Returns WSBehaviors

Methods

  • Returns Promise<void>

  • Returns void

  • Parameters

    • Optional mimeTypes: string[]

    Returns Promise<IModel>

  • Parameters

    • data: Blob
    • Optional mimeType: string

    Returns Promise<IModel>

  • Parameters

    • strokes: {
          creationTime?: number;
          id?: string;
          length?: number;
          modificationDate?: number;
          pointerType?: string;
          pointers?: (undefined | ({ x?: number | undefined; y?: number | undefined; t?: number | undefined; p?: number | undefined; }))[];
          style?: { width?: number | undefined; color?: string | undefined; opacity?: number | undefined; fill?: string | undefined; };
          type?: string;
      }[]

    Returns Promise<IModel>

  • Parameters

    • domElement: HTMLElement

    Returns Promise<void>

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns void

  • Parameters

    Returns Promise<void>

  • Parameters

    • height: number
    • width: number

    Returns Promise<IModel>

  • Parameters

    • Optional penStyle: {
          -myscript-pen-fill-color?: string;
          -myscript-pen-fill-style?: string;
          -myscript-pen-width?: number;
          color?: string;
          fill?: string;
          opacity?: number;
          width?: number;
      }
      • Optional -myscript-pen-fill-color?: string
      • Optional -myscript-pen-fill-style?: string
      • Optional -myscript-pen-width?: number
      • Optional color?: string
      • Optional fill?: string
      • Optional opacity?: number
      • Optional width?: number

    Returns Promise<void>

  • Parameters

    • Optional penClass: string

    Returns Promise<void>

  • Parameters

    • Optional theme: {
          .math?: { "font-family"?: string | undefined; };
          .math-solved?: { "font-family"?: string | undefined; color?: string | undefined; };
          .text?: { "font-family"?: string | undefined; "font-size"?: number | undefined; };
          ink?: { width?: number | undefined; color?: string | undefined; opacity?: number | undefined; fill?: string | undefined; "-myscript-pen-width"?: number | undefined; "-myscript-pen-fill-style"?: string | undefined; "-myscript-pen-fill-color"?: string | undefined; };
      }
      • Optional .math?: { "font-family"?: string | undefined; }
      • Optional .math-solved?: { "font-family"?: string | undefined; color?: string | undefined; }
      • Optional .text?: { "font-family"?: string | undefined; "font-size"?: number | undefined; }
      • Optional ink?: { width?: number | undefined; color?: string | undefined; opacity?: number | undefined; fill?: string | undefined; "-myscript-pen-width"?: number | undefined; "-myscript-pen-fill-style"?: string | undefined; "-myscript-pen-fill-color"?: string | undefined; }

    Returns Promise<void>

  • Returns Promise<IModel>

  • Returns Promise<void>

Properties

#configuration: TConfiguration
#logger: Logger = ...
#model: Model
#resizeTimer?: Timeout
intention: Intention
name: string = "WSBehaviors"
recognizer: WSRecognizer
renderer: WSSVGRenderer
styleManager: StyleManager

Generated using TypeDoc