x4js - v2.3.33
    Preparing search index...

    Function getEventClipboard

    • Read the clipboard in a "paste" event, its image the PNG file when there is one. The default of the event is left as it is: prevent it when what was read is used.

      Parameters

      • ev: ClipboardEvent

      Returns ClipboardRead

      this.addDOMEvent( "paste", ev => {
      const data = getEventClipboard( ev );
      if( data.image ) {
      ev.preventDefault( );
      this.setPicture( data.image );
      }
      } );