UNPKG

@mescius/dsimageviewer

Version:

Document Solutions Image Viewer

263 lines (254 loc) 112 kB
<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>IImageViewer | Document Solutions Image Viewer - v8.0.4</title><meta name="description" content="Documentation for Document Solutions Image Viewer - v8.0.4"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><link rel="stylesheet" href="../assets/custom.css"/><script async src="../assets/search.js" id="search-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os"</script><header class="tsd-page-toolbar"> <div class="tsd-toolbar-contents container"> <div class="table-cell" id="tsd-search" data-base=".."> <div class="field"><label for="tsd-search-field" class="tsd-widget search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M15.7824 13.833L12.6666 10.7177C12.5259 10.5771 12.3353 10.499 12.1353 10.499H11.6259C12.4884 9.39596 13.001 8.00859 13.001 6.49937C13.001 2.90909 10.0914 0 6.50048 0C2.90959 0 0 2.90909 0 6.49937C0 10.0896 2.90959 12.9987 6.50048 12.9987C8.00996 12.9987 9.39756 12.4863 10.5008 11.6239V12.1332C10.5008 12.3332 10.5789 12.5238 10.7195 12.6644L13.8354 15.7797C14.1292 16.0734 14.6042 16.0734 14.8948 15.7797L15.7793 14.8954C16.0731 14.6017 16.0731 14.1267 15.7824 13.833ZM6.50048 10.499C4.29094 10.499 2.50018 8.71165 2.50018 6.49937C2.50018 4.29021 4.28781 2.49976 6.50048 2.49976C8.71001 2.49976 10.5008 4.28708 10.5008 6.49937C10.5008 8.70852 8.71314 10.499 6.50048 10.499Z" fill="var(--color-text)"></path></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div> <ul class="results"> <li class="state loading">Preparing search index...</li> <li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">Document Solutions Image Viewer - v8.0.4</a></div> <div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><rect x="1" y="3" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="7" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="11" width="14" height="2" fill="var(--color-text)"></rect></svg></a></div></div></header> <div class="container container-main"> <div class="col-8 col-content"> <div class="tsd-page-title"> <ul class="tsd-breadcrumb"> <li><a href="../index.html">Document Solutions Image Viewer - v8.0.4</a></li> <li><a href="IImageViewer.html">IImageViewer</a></li></ul> <h1>Interface IImageViewer</h1></div> <section class="tsd-panel tsd-comment"> <div class="tsd-comment tsd-typography"><p>Interface describing the ImageViewer API, primarily utilized for control/plugin development purposes.</p> </div></section> <section class="tsd-panel tsd-hierarchy"> <h4>Hierarchy</h4> <ul class="tsd-hierarchy"> <li><span class="target">IImageViewer</span></li></ul></section> <section class="tsd-panel"> <h4>Implemented by</h4> <ul class="tsd-hierarchy"> <li><a href="../classes/GcImageViewer.html" class="tsd-signature-type" data-tsd-kind="Class">GcImageViewer</a></li></ul></section> <section class="tsd-panel-group tsd-index-group"> <section class="tsd-panel tsd-index-panel"> <details class="tsd-index-content tsd-index-accordion" open><summary class="tsd-accordion-summary tsd-index-summary"> <h5 class="tsd-index-heading uppercase" role="button" aria-expanded="false" tabIndex=0><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M1.5 5.50969L8 11.6609L14.5 5.50969L12.5466 3.66086L8 7.96494L3.45341 3.66086L1.5 5.50969Z" fill="var(--color-text)"></path></svg> Index</h5></summary> <div class="tsd-accordion-details"> <section class="tsd-index-section"> <h3 class="tsd-index-heading">Methods</h3> <div class="tsd-index-list"><a href="IImageViewer.html#showPanel" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="#FF4DB8" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12" id="icon-2048-path"></rect><path d="M9.162 16V7.24H10.578L11.514 10.072C11.602 10.328 11.674 10.584 11.73 10.84C11.794 11.088 11.842 11.28 11.874 11.416C11.906 11.28 11.954 11.088 12.018 10.84C12.082 10.584 12.154 10.324 12.234 10.06L13.122 7.24H14.538V16H13.482V12.82C13.482 12.468 13.49 12.068 13.506 11.62C13.53 11.172 13.558 10.716 13.59 10.252C13.622 9.78 13.654 9.332 13.686 8.908C13.726 8.476 13.762 8.1 13.794 7.78L12.366 12.16H11.334L9.894 7.78C9.934 8.092 9.97 8.456 10.002 8.872C10.042 9.28 10.078 9.716 10.11 10.18C10.142 10.636 10.166 11.092 10.182 11.548C10.206 12.004 10.218 12.428 10.218 12.82V16H9.162Z" fill="var(--color-text)" id="icon-2048-text"></path></svg><span>show<wbr/>Panel</span></a> <a href="IImageViewer.html#updatePanel" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>update<wbr/>Panel</span></a> <a href="IImageViewer.html#getPanelState" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>get<wbr/>Panel<wbr/>State</span></a> <a href="IImageViewer.html#layoutPanels" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>layout<wbr/>Panels</span></a> <a href="IImageViewer.html#save" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>save</span></a> <a href="IImageViewer.html#toggleFullscreen" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>toggle<wbr/>Fullscreen</span></a> <a href="IImageViewer.html#toggleToolbar" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>toggle<wbr/>Toolbar</span></a> <a href="IImageViewer.html#applyToolbarLayout" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>apply<wbr/>Toolbar<wbr/>Layout</span></a> <a href="IImageViewer.html#addKeyboardListener" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>add<wbr/>Keyboard<wbr/>Listener</span></a> <a href="IImageViewer.html#removeKeyboardListener" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>remove<wbr/>Keyboard<wbr/>Listener</span></a> <a href="IImageViewer.html#configurePluginMainToolbar" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>configure<wbr/>Plugin<wbr/>Main<wbr/>Toolbar</span></a> <a href="IImageViewer.html#dataUrlToImageData" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>data<wbr/>Url<wbr/>To<wbr/>Image<wbr/>Data</span></a> <a href="IImageViewer.html#ensurePaintLayer" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>ensure<wbr/>Paint<wbr/>Layer</span></a> <a href="IImageViewer.html#findPlugin" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>find<wbr/>Plugin</span></a> <a href="IImageViewer.html#getEventCanvasPoint" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>get<wbr/>Event<wbr/>Canvas<wbr/>Point</span></a> <a href="IImageViewer.html#getImageDataUrl" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>get<wbr/>Image<wbr/>Data<wbr/>Url</span></a> <a href="IImageViewer.html#setImageDataUrl" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>set<wbr/>Image<wbr/>Data<wbr/>Url</span></a> <a href="IImageViewer.html#showActivitySpinner" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>show<wbr/>Activity<wbr/>Spinner</span></a> <a href="IImageViewer.html#hideActivitySpinner" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>hide<wbr/>Activity<wbr/>Spinner</span></a> <a href="IImageViewer.html#confirm" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>confirm</span></a> <a href="IImageViewer.html#getOriginalImageDataUrl" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>get<wbr/>Original<wbr/>Image<wbr/>Data<wbr/>Url</span></a> <a href="IImageViewer.html#removeLayer" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>remove<wbr/>Layer</span></a> <a href="IImageViewer.html#removeLayers" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>remove<wbr/>Layers</span></a> <a href="IImageViewer.html#showSecondToolbar" class="tsd-index-link tsd-kind-method tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-2048-path"></use><use href="#icon-2048-text"></use></svg><span>show<wbr/>Second<wbr/>Toolbar</span></a> </div></section> <section class="tsd-index-section"> <h3 class="tsd-index-heading">Accessors</h3> <div class="tsd-index-list"><a href="IImageViewer.html#isFullscreen" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="#FF4D4D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12" id="icon-262144-path"></rect><path d="M8.85 16L11.13 7.24H12.582L14.85 16H13.758L13.182 13.672H10.53L9.954 16H8.85ZM10.746 12.76H12.954L12.282 10.06C12.154 9.548 12.054 9.12 11.982 8.776C11.91 8.432 11.866 8.208 11.85 8.104C11.834 8.208 11.79 8.432 11.718 8.776C11.646 9.12 11.546 9.544 11.418 10.048L10.746 12.76Z" fill="var(--color-text)" id="icon-262144-text"></path></svg><span>is<wbr/>Fullscreen</span></a> <a href="IImageViewer.html#isToolbarHidden" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>is<wbr/>Toolbar<wbr/>Hidden</span></a> <a href="IImageViewer.html#eventBus" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>event<wbr/>Bus</span></a> <a href="IImageViewer.html#hasImage" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>has<wbr/>Image</span></a> <a href="IImageViewer.html#imageFormat" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>image<wbr/>Format</span></a> <a href="IImageViewer.html#layers" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>layers</span></a> <a href="IImageViewer.html#naturalSize" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>natural<wbr/>Size</span></a> <a href="IImageViewer.html#undoStorage" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>undo<wbr/>Storage</span></a> <a href="IImageViewer.html#hostElement" class="tsd-index-link tsd-kind-accessor tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-262144-path"></use><use href="#icon-262144-text"></use></svg><span>host<wbr/>Element</span></a> </div></section> <section class="tsd-index-section"> <h3 class="tsd-index-heading">Properties</h3> <div class="tsd-index-list"><a href="IImageViewer.html#toggleSidebar" class="tsd-index-link tsd-kind-property tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="#FF984D" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="12" id="icon-1024-path"></rect><path d="M9.354 16V7.24H12.174C12.99 7.24 13.638 7.476 14.118 7.948C14.606 8.412 14.85 9.036 14.85 9.82C14.85 10.604 14.606 11.232 14.118 11.704C13.638 12.168 12.99 12.4 12.174 12.4H10.434V16H9.354ZM10.434 11.428H12.174C12.646 11.428 13.022 11.284 13.302 10.996C13.59 10.7 13.734 10.308 13.734 9.82C13.734 9.324 13.59 8.932 13.302 8.644C13.022 8.356 12.646 8.212 12.174 8.212H10.434V11.428Z" fill="var(--color-text)" id="icon-1024-text"></path></svg><span>toggle<wbr/>Sidebar</span></a> <a href="IImageViewer.html#toolbarLayout" class="tsd-index-link tsd-kind-property tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg><span>toolbar<wbr/>Layout</span></a> <a href="IImageViewer.html#in17n" class="tsd-index-link tsd-kind-property tsd-parent-kind-interface"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-1024-path"></use><use href="#icon-1024-text"></use></svg><span>in17n</span></a> </div></section></div></details></section></section> <section class="tsd-panel-group tsd-member-group"> <h2>Methods</h2> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="showPanel" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>show<wbr/>Panel</span><a href="#showPanel" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none" id="icon-anchor-a"></path><path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5" id="icon-anchor-b"></path><path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5" id="icon-anchor-c"></path></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="showPanel.showPanel-1">show<wbr/>Panel<span class="tsd-signature-symbol">(</span>panelKey<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">PanelHandle</span>, visible<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#showPanel.showPanel-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Updates the panel visibility.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5>panelKey: <span class="tsd-signature-type">PanelHandle</span></h5></li> <li> <h5><code class="tsd-tag ts-flagOptional">Optional</code> visible: <span class="tsd-signature-type">boolean</span></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="updatePanel" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>update<wbr/>Panel</span><a href="#updatePanel" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="updatePanel.updatePanel-1">update<wbr/>Panel<span class="tsd-signature-symbol">(</span>panelKey<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">PanelHandle</span>, settings<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Partial</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">PanelSettings</span><span class="tsd-signature-symbol">&gt;</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#updatePanel.updatePanel-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Updates panel settings such as visibility, label or &quot;enabled&quot; status.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5>panelKey: <span class="tsd-signature-type">PanelHandle</span></h5></li> <li> <h5>settings: <span class="tsd-signature-type">Partial</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">PanelSettings</span><span class="tsd-signature-symbol">&gt;</span></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="getPanelState" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>get<wbr/>Panel<wbr/>State</span><a href="#getPanelState" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="getPanelState.getPanelState-1">get<wbr/>Panel<wbr/>State<span class="tsd-signature-symbol">(</span>panelKey<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">PanelHandle</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">PanelSettings</span><a href="#getPanelState.getPanelState-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Gets the current panel state.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5>panelKey: <span class="tsd-signature-type">PanelHandle</span></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">null</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">PanelSettings</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="layoutPanels" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>layout<wbr/>Panels</span><a href="#layoutPanels" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="layoutPanels.layoutPanels-1">layout<wbr/>Panels<span class="tsd-signature-symbol">(</span>layout<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#layoutPanels.layoutPanels-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Orders and filters panel items. &#39;*&#39; indicates &quot;the rest of panels&quot;. &#39;sep&#39;/&#39;separator&#39; indicated menu separator.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5>layout: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="save" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>save</span><a href="#save" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="save.save-1">save<span class="tsd-signature-symbol">(</span>options<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> | </span><a href="../types/SaveOptions.html" class="tsd-signature-type" data-tsd-kind="Type alias">SaveOptions</a>, original<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#save.save-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Saves the Image document loaded in the Viewer to the local disk.</p> <h3>Example</h3><pre><code class="language-javascript"><span class="hl-5">// Example: Save the modified image without using specific options.</span><br/><span class="hl-4">const</span><span class="hl-1"> </span><span class="hl-8">viewer</span><span class="hl-1"> = </span><span class="hl-0">DsImageViewer</span><span class="hl-1">.</span><span class="hl-2">findControl</span><span class="hl-1">(</span><span class="hl-3">&quot;#root&quot;</span><span class="hl-1">);</span><br/><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">save</span><span class="hl-1">();</span> </code></pre> <h3>Example</h3><pre><code class="language-javascript"><span class="hl-5">// Example: Save the modified image as &quot;image.png&quot;.</span><br/><span class="hl-4">const</span><span class="hl-1"> </span><span class="hl-8">viewer</span><span class="hl-1"> = </span><span class="hl-0">DsImageViewer</span><span class="hl-1">.</span><span class="hl-2">findControl</span><span class="hl-1">(</span><span class="hl-3">&quot;#root&quot;</span><span class="hl-1">);</span><br/><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">save</span><span class="hl-1">({ </span><span class="hl-0">fileName:</span><span class="hl-1"> </span><span class="hl-3">&quot;image.png&quot;</span><span class="hl-1"> });</span> </code></pre> <h3>Example</h3><pre><code class="language-javascript"><span class="hl-5">// Example: Download the original version of the image as &quot;original_image.jpg&quot;.</span><br/><span class="hl-4">const</span><span class="hl-1"> </span><span class="hl-8">viewer</span><span class="hl-1"> = </span><span class="hl-0">DsImageViewer</span><span class="hl-1">.</span><span class="hl-2">findControl</span><span class="hl-1">(</span><span class="hl-3">&quot;#root&quot;</span><span class="hl-1">);</span><br/><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">save</span><span class="hl-1">({ </span><span class="hl-0">fileName:</span><span class="hl-1"> </span><span class="hl-3">&quot;original_image.jpg&quot;</span><span class="hl-1">, </span><span class="hl-0">original:</span><span class="hl-1"> </span><span class="hl-4">true</span><span class="hl-1"> });</span> </code></pre> <h3>Example</h3><pre><code class="language-javascript"><span class="hl-5">// Example: Save the modified image in PNG format.</span><br/><span class="hl-4">const</span><span class="hl-1"> </span><span class="hl-8">viewer</span><span class="hl-1"> = </span><span class="hl-0">DsImageViewer</span><span class="hl-1">.</span><span class="hl-2">findControl</span><span class="hl-1">(</span><span class="hl-3">&quot;#root&quot;</span><span class="hl-1">);</span><br/><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">save</span><span class="hl-1">({ </span><span class="hl-0">convertToFormat:</span><span class="hl-1"> </span><span class="hl-3">&quot;image/png&quot;</span><span class="hl-1"> });</span> </code></pre> <h3>Example</h3><pre><code class="language-javascript"><span class="hl-5">// Example: Save the modified image with a custom file name and in JPEG format.</span><br/><span class="hl-4">const</span><span class="hl-1"> </span><span class="hl-8">viewer</span><span class="hl-1"> = </span><span class="hl-0">DsImageViewer</span><span class="hl-1">.</span><span class="hl-2">findControl</span><span class="hl-1">(</span><span class="hl-3">&quot;#root&quot;</span><span class="hl-1">);</span><br/><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">save</span><span class="hl-1">({ </span><span class="hl-0">fileName:</span><span class="hl-1"> </span><span class="hl-3">&quot;custom_name&quot;</span><span class="hl-1">, </span><span class="hl-0">convertToFormat:</span><span class="hl-1"> </span><span class="hl-3">&quot;image/jpeg&quot;</span><span class="hl-1"> });</span> </code></pre> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5><code class="tsd-tag ts-flagOptional">Optional</code> options: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> | </span><a href="../types/SaveOptions.html" class="tsd-signature-type" data-tsd-kind="Type alias">SaveOptions</a></h5> <div class="tsd-comment tsd-typography"><p>The save options, including the destination file name and other settings.</p> </div></li> <li> <h5><code class="tsd-tag ts-flagOptional">Optional</code> original: <span class="tsd-signature-type">boolean</span></h5> <div class="tsd-comment tsd-typography"><p>Flag indicating whether to use the initial version of the image for save. Defaults to <code>false</code>.</p> </div></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="toggleFullscreen" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>toggle<wbr/>Fullscreen</span><a href="#toggleFullscreen" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="toggleFullscreen.toggleFullscreen-1">toggle<wbr/>Fullscreen<span class="tsd-signature-symbol">(</span>fullscreen<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#toggleFullscreen.toggleFullscreen-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Toggle full screen mode.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5><code class="tsd-tag ts-flagOptional">Optional</code> fullscreen: <span class="tsd-signature-type">boolean</span></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="toggleToolbar" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>toggle<wbr/>Toolbar</span><a href="#toggleToolbar" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="toggleToolbar.toggleToolbar-1">toggle<wbr/>Toolbar<span class="tsd-signature-symbol">(</span>show<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span><a href="#toggleToolbar.toggleToolbar-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Toggle toolbar visibility.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5><code class="tsd-tag ts-flagOptional">Optional</code> show: <span class="tsd-signature-type">boolean</span></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="applyToolbarLayout" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>apply<wbr/>Toolbar<wbr/>Layout</span><a href="#applyToolbarLayout" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="applyToolbarLayout.applyToolbarLayout-1">apply<wbr/>Toolbar<wbr/>Layout<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span><a href="#applyToolbarLayout.applyToolbarLayout-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Call this method in order to apply changes in @see:toolbarLayout.</p> <h3>Example</h3><pre><code class="language-javascript"><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-0">toolbarLayout</span><span class="hl-1">.</span><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-0">default</span><span class="hl-1"> = [</span><span class="hl-3">&quot;open&quot;</span><span class="hl-1">, </span><span class="hl-3">&quot;save&quot;</span><span class="hl-1">];</span><br/><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">applyToolbarLayout</span><span class="hl-1">();</span> </code></pre> <h3>Example</h3><pre><code class="language-javascript"><span class="hl-1"> </span><span class="hl-4">var</span><span class="hl-1"> </span><span class="hl-0">viewer</span><span class="hl-1"> = </span><span class="hl-4">new</span><span class="hl-1"> </span><span class="hl-2">GcImageViewer</span><span class="hl-1">(</span><span class="hl-0">document</span><span class="hl-1">.</span><span class="hl-2">querySelector</span><span class="hl-1">(</span><span class="hl-3">&quot;#viewer&quot;</span><span class="hl-1">));</span><br/><span class="hl-1"> </span><span class="hl-4">var</span><span class="hl-1"> </span><span class="hl-0">toolbar</span><span class="hl-1"> = </span><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-0">toolbar</span><span class="hl-1">;</span><br/><span class="hl-1"> </span><span class="hl-4">var</span><span class="hl-1"> </span><span class="hl-0">toolbarLayout</span><span class="hl-1"> = </span><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-0">toolbarLayout</span><span class="hl-1">;</span><br/><span class="hl-1"> </span><span class="hl-0">toolbar</span><span class="hl-1">.</span><span class="hl-2">addItem</span><span class="hl-1">({</span><br/><span class="hl-1"> </span><span class="hl-0">key:</span><span class="hl-1"> </span><span class="hl-3">&#39;custom-action&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-0">icon:</span><span class="hl-1"> { </span><span class="hl-0">type:</span><span class="hl-1"> </span><span class="hl-3">&quot;svg&quot;</span><span class="hl-1">, </span><span class="hl-0">content:</span><span class="hl-1"> </span><span class="hl-3">&#39;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; version=&quot;1.1&quot; width=&quot;24&quot; height=&quot;24&quot; viewBox=&quot;0 0 24 24&quot;&gt;&lt;path style=&quot;fill: #205F78;&quot; d=&quot;M20.25 12l-2.25 2.25 2.25 2.25-3.75 3.75-2.25-2.25-2.25 2.25-2.25-2.25-2.25 2.25-3.75-3.75 2.25-2.25-2.25-2.25 2.25-2.25-2.25-2.25 3.75-3.75 2.25 2.25 2.25-2.25 2.25 2.25 2.25-2.25 3.75 3.75-2.25 2.25 2.25 2.25z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;&#39;</span><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-0">title:</span><span class="hl-1"> </span><span class="hl-3">&#39;Custom action&#39;</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-0">checked:</span><span class="hl-1"> </span><span class="hl-4">false</span><span class="hl-1">, </span><span class="hl-0">enabled:</span><span class="hl-1"> </span><span class="hl-4">false</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-2">action</span><span class="hl-0">:</span><span class="hl-1"> </span><span class="hl-4">function</span><span class="hl-1"> () { </span><br/><span class="hl-1"> </span><span class="hl-2">alert</span><span class="hl-1">(</span><span class="hl-3">&quot;Implement your action here.&quot;</span><span class="hl-1">); </span><br/><span class="hl-1"> },</span><br/><span class="hl-1"> </span><span class="hl-2">onUpdate</span><span class="hl-0">:</span><span class="hl-1"> </span><span class="hl-4">function</span><span class="hl-1"> (</span><span class="hl-0">args</span><span class="hl-1">) {</span><br/><span class="hl-1"> </span><span class="hl-6">return</span><span class="hl-1"> {</span><br/><span class="hl-1"> </span><span class="hl-0">enabled:</span><span class="hl-1"> </span><span class="hl-4">true</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-0">checked:</span><span class="hl-1"> </span><span class="hl-4">false</span><span class="hl-1">,</span><br/><span class="hl-1"> </span><span class="hl-0">title:</span><span class="hl-1"> </span><span class="hl-3">&#39;Custom action title&#39;</span><br/><span class="hl-1"> }</span><br/><span class="hl-1"> }</span><br/><span class="hl-1"> });</span><br/><span class="hl-1"> </span><span class="hl-0">toolbarLayout</span><span class="hl-1">.</span><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-0">default</span><span class="hl-1">.</span><span class="hl-2">splice</span><span class="hl-1">(</span><span class="hl-7">0</span><span class="hl-1">, </span><span class="hl-7">0</span><span class="hl-1">, </span><span class="hl-3">&quot;custom-action&quot;</span><span class="hl-1">);</span><br/><span class="hl-1"> </span><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">applyToolbarLayout</span><span class="hl-1">();</span> </code></pre> </div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">any</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="addKeyboardListener" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>add<wbr/>Keyboard<wbr/>Listener</span><a href="#addKeyboardListener" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="addKeyboardListener.addKeyboardListener-1">add<wbr/>Keyboard<wbr/>Listener<span class="tsd-signature-symbol">(</span>uniqueKey<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span>, handler<span class="tsd-signature-symbol">: </span><a href="WindowKeyboardListener.html" class="tsd-signature-type" data-tsd-kind="Interface">WindowKeyboardListener</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span><a href="#addKeyboardListener.addKeyboardListener-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Add window keyboard listener.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5>uniqueKey: <span class="tsd-signature-type">string</span></h5></li> <li> <h5>handler: <a href="WindowKeyboardListener.html" class="tsd-signature-type" data-tsd-kind="Interface">WindowKeyboardListener</a></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">any</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="removeKeyboardListener" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>remove<wbr/>Keyboard<wbr/>Listener</span><a href="#removeKeyboardListener" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="removeKeyboardListener.removeKeyboardListener-1">remove<wbr/>Keyboard<wbr/>Listener<span class="tsd-signature-symbol">(</span>uniqueKey<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span><a href="#removeKeyboardListener.removeKeyboardListener-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Remove window keyboard listener.</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5>uniqueKey: <span class="tsd-signature-type">string</span></h5></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">any</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="configurePluginMainToolbar" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>configure<wbr/>Plugin<wbr/>Main<wbr/>Toolbar</span><a href="#configurePluginMainToolbar" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul class="tsd-signatures tsd-kind-method tsd-parent-kind-interface"> <li class="tsd-signature tsd-anchor-link" id="configurePluginMainToolbar.configurePluginMainToolbar-1">configure<wbr/>Plugin<wbr/>Main<wbr/>Toolbar<span class="tsd-signature-symbol">(</span>pos<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">boolean</span>, buttonsToInsert<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">any</span><a href="#configurePluginMainToolbar.configurePluginMainToolbar-1" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></li> <li class="tsd-description"> <div class="tsd-comment tsd-typography"><p>Used preliminarily by the plugin developers to configure the main toolbar layout.</p> <h3>Example</h3><pre><code class="language-ts"><span class="hl-5">// Apply a custom layout to insert &quot;zoomIn&quot; and &quot;zoomOut&quot; buttons at position 2 for the &quot;PaintTools&quot; plugin.</span><br/><span class="hl-0">viewer</span><span class="hl-1">.</span><span class="hl-2">configurePluginMainToolbar</span><span class="hl-1">(</span><span class="hl-7">2</span><span class="hl-1">, [</span><span class="hl-3">&quot;zoomIn&quot;</span><span class="hl-1">, </span><span class="hl-3">&quot;zoomOut&quot;</span><span class="hl-1">]);</span> </code></pre> <h3>Returns</h3><p>void</p> </div> <div class="tsd-parameters"> <h4 class="tsd-parameters-title">Parameters</h4> <ul class="tsd-parameter-list"> <li> <h5>pos: <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">boolean</span></h5> <div class="tsd-comment tsd-typography"><p>The position where the buttons should be inserted. Use <code>false</code> or <code>-1</code> to skip insertion. Undefined means the position will be determined automatically.</p> </div></li> <li> <h5>buttonsToInsert: <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">[]</span></h5> <div class="tsd-comment tsd-typography"><p>An array of button keys to be inserted.</p> </div></li></ul></div> <h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">any</span></h4></li></ul></section> <section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-interface"><a id="dataUrlToImageData" class="tsd-anchor"></a> <h3 class="tsd-anchor-link"><span>data<wbr/>Url<wbr/>To<wbr/>Image<wbr/>Data</span><a href="#dataUrlToImageData" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3> <ul cl