.. role:: clio-deprecated
   :class: clio-flag clio-flag-deprecated

.. role:: clio-readonly
   :class: clio-flag clio-flag-readonly


##########
IWebViewer
##########

.. js:class:: IWebViewer

   
   Index
   =====
   
   .. rubric:: Properties
   
   
   .. rst-class:: api-xref-list
   
   
   * :js:data:`~IWebViewer._views`
   * :js:data:`~IWebViewer.animationManager`
   * :js:data:`~IWebViewer.BCFManager`
   * :js:data:`~IWebViewer.cuttingManager`
   * :js:data:`~IWebViewer.explodeManager`
   * :js:data:`~IWebViewer.floorplanManager`
   * :js:data:`~IWebViewer.lineManager`
   * :js:data:`~IWebViewer.markupManager`
   * :js:data:`~IWebViewer.measureManager`
   * :js:data:`~IWebViewer.model`
   * :js:data:`~IWebViewer.noteTextManager`
   * :js:data:`~IWebViewer.operatorManager`
   * :js:data:`~IWebViewer.overlayManager`
   * :js:data:`~IWebViewer.selectionManager`
   * :js:data:`~IWebViewer.sheetManager`
   * :js:data:`~IWebViewer.view`
   * :js:data:`~IWebViewer.views`
   
   .. rubric:: Methods
   
   
   .. rst-class:: api-xref-list
   
   
   * :js:meth:`~IWebViewer.addView`
   * :js:meth:`~IWebViewer.advanceExportToSvg`
   * :js:meth:`~IWebViewer.applyFilter`
   * :js:meth:`~IWebViewer.beginExportToSvg`
   * :js:meth:`~IWebViewer.closeConnection`
   * :js:meth:`~IWebViewer.delayCapping`
   * :js:meth:`~IWebViewer.endExportToSvg`
   * :js:meth:`~IWebViewer.exportToSvg`
   * :js:meth:`~IWebViewer.fitWorld`
   * :js:meth:`~IWebViewer.focusInput`
   * :js:meth:`~IWebViewer.getAllowHighDpi`
   * :js:meth:`~IWebViewer.getContextMenuStatus`
   * :js:meth:`~IWebViewer.getFormatVersionString`
   * :js:meth:`~IWebViewer.getMinimumFramerate`
   * :js:meth:`~IWebViewer.getModelReady`
   * :js:meth:`~IWebViewer.getRendererType`
   * :js:meth:`~IWebViewer.getSceneReady`
   * :js:meth:`~IWebViewer.getStatistics`
   * :js:meth:`~IWebViewer.getStreamCutoffScale`
   * :js:meth:`~IWebViewer.getStreamingMode`
   * :js:meth:`~IWebViewer.getView`
   * :js:meth:`~IWebViewer.getViewElement`
   * :js:meth:`~IWebViewer.getViewerVersionString`
   * :js:meth:`~IWebViewer.moveToWindow`
   * :js:meth:`~IWebViewer.pauseRendering`
   * :js:meth:`~IWebViewer.redraw`
   * :js:meth:`~IWebViewer.registerCustomOperator`
   * :js:meth:`~IWebViewer.removeView`
   * :js:meth:`~IWebViewer.reset`
   * :js:meth:`~IWebViewer.resetClientTimeout`
   * :js:meth:`~IWebViewer.resizeCanvas`
   * :js:meth:`~IWebViewer.resumeRendering`
   * :js:meth:`~IWebViewer.selectPart`
   * :js:meth:`~IWebViewer.setAllowHighDpi`
   * :js:meth:`~IWebViewer.setCallbacks`
   * :js:meth:`~IWebViewer.setClientTimeout`
   * :js:meth:`~IWebViewer.setContextMenuStatus`
   * :js:meth:`~IWebViewer.setMinimumFramerate`
   * :js:meth:`~IWebViewer.setServerRenderQuality`
   * :js:meth:`~IWebViewer.setStreamCutoffScale`
   * :js:meth:`~IWebViewer.setViewOrientation`
   * :js:meth:`~IWebViewer.shutdown`
   * :js:meth:`~IWebViewer.start`
   * :js:meth:`~IWebViewer.takeSnapshot`
   * :js:meth:`~IWebViewer.trigger`
   * :js:meth:`~IWebViewer.unregisterCustomOperator`
   * :js:meth:`~IWebViewer.unsetCallbacks`
   * :js:meth:`~IWebViewer.waitForIdle`
   
   




Properties
==========

.. js:data:: IWebViewer._views

   .. rst-class:: sig-pretty-signature
   
      | _views: :js:class:`~IView`\ []
   



.. js:data:: IWebViewer.animationManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | animationManager: :js:class:`Manager <Animation.Manager>`
   



.. js:data:: IWebViewer.BCFManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | BCFManager: *BCFManager*
   



.. js:data:: IWebViewer.cuttingManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | cuttingManager: :js:class:`~ICuttingManager`
   



.. js:data:: IWebViewer.explodeManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | explodeManager: :js:class:`~ExplodeManager`
   



.. js:data:: IWebViewer.floorplanManager

   .. rst-class:: clio-flags
   
      :clio-deprecated:`deprecated`
   
   .. rst-class:: sig-pretty-signature
   
      | floorplanManager: :js:class:`FloorplanManager <Floorplan.FloorplanManager>`
   
   **Deprecated**
   
      FloorplanManagers are now properties of Views.
   
   



.. js:data:: IWebViewer.lineManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | lineManager: :js:class:`~LineManager`
   



.. js:data:: IWebViewer.markupManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | markupManager: :js:class:`~MarkupManager`
   



.. js:data:: IWebViewer.measureManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | measureManager: :js:class:`~MeasureManager`
   



.. js:data:: IWebViewer.model

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | model: :js:class:`~IModel`
   



.. js:data:: IWebViewer.noteTextManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | noteTextManager: :js:class:`NoteTextManager <Operators.NoteTextManager>`
   



.. js:data:: IWebViewer.operatorManager

   .. rst-class:: clio-flags
   
      :clio-deprecated:`deprecated`
   
   .. rst-class:: sig-pretty-signature
   
      | operatorManager: :js:class:`~OperatorManager`
   
   **Deprecated**
   
      OperatorManagers are now properties of Views.
   
   



.. js:data:: IWebViewer.overlayManager

   .. rst-class:: clio-flags
   
      :clio-deprecated:`deprecated`
   
   .. rst-class:: sig-pretty-signature
   
      | overlayManager: :js:class:`OverlayManager <Overlay.OverlayManager>`
   
   **Deprecated**
   
      OverlayManagers are now properties of Views.
   
   



.. js:data:: IWebViewer.selectionManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | selectionManager: :js:class:`SelectionManager <Selection.SelectionManager>`
   



.. js:data:: IWebViewer.sheetManager

   .. rst-class:: clio-flags
   
      :clio-readonly:`readonly`
   
   .. rst-class:: sig-pretty-signature
   
      | sheetManager: :js:class:`~SheetManager`
   



.. js:data:: IWebViewer.view

   .. rst-class:: sig-pretty-signature
   
      | view: :js:class:`~IView`
   



.. js:data:: IWebViewer.views

   .. rst-class:: sig-pretty-signature
   
      | views: :js:class:`~IView`\ []
   





Methods
=======

.. js:method:: IWebViewer.addView

   .. rst-class:: sig-pretty-signature
   
      | addView(**config**\ : :js:class:`~ViewConfig`\ ): *Promise*
   
   Adds another 3D view of the scene to the page.
   
   **Parameters**
   
      **config**\ : :js:class:`~ViewConfig`
   
         configuration to be used for the new view.
   
   
   
   **Returns**\ : *Promise*
   
      A promise with the created View.
   
   



.. js:method:: IWebViewer.advanceExportToSvg

   .. rst-class:: sig-pretty-signature
   
      | advanceExportToSvg(): *Promise*
   
   Get the next chunk of the SVG code
   
   **Returns**\ : *Promise*
   
      A promise that resolves to a string containing the next chunk or undefined on completed..
   
   



.. js:method:: IWebViewer.applyFilter

   .. rst-class:: sig-pretty-signature
   
      | applyFilter(**filterId**\ : :js:data:`~FilterId`\ ): *void*
   
   **Parameters**
   
      **filterId**\ : :js:data:`~FilterId`
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.beginExportToSvg

   .. rst-class:: sig-pretty-signature
   
      | beginExportToSvg(**config**\ : :js:class:`~SvgConfig`\ ): *Promise*
   
   Setup the env to export the current scene to a two-dimensional SVG representation through stream.
   
   **Parameters**
   
      **config**\ : :js:class:`~SvgConfig`
   
         Allows customization of the resultant SVG.
   
   
   
   **Returns**\ : *Promise*
   
      A promise that resolves to void when the env is ready.
   
   



.. js:method:: IWebViewer.closeConnection

   .. rst-class:: sig-pretty-signature
   
      | closeConnection(): *void*
   
   Disconnects the network connection when in CSR mode.
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.delayCapping

   .. rst-class:: sig-pretty-signature
   
      | delayCapping(): *void*
   
   Delays capping processing by a fixed time interval.
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.endExportToSvg

   .. rst-class:: sig-pretty-signature
   
      | endExportToSvg(): *Promise*
   
   Reset the env after SVG stream export.
   
   **Returns**\ : *Promise*
   
      A promise that resolves to void when the env is reset.
   
   



.. js:method:: IWebViewer.exportToSvg

   .. rst-class:: sig-pretty-signature
   
      | exportToSvg(**config**\ : :js:class:`~SvgConfig`\ ): *Promise*
   
   Exports the current scene to a two-dimensional SVG representation.
   
   **Parameters**
   
      **config**\ : :js:class:`~SvgConfig`
   
         Allows customization of the resultant SVG.
   
   
   
   **Returns**\ : *Promise*
   
      A promise that resolves to the created SVG string.
   
   



.. js:method:: IWebViewer.fitWorld

   .. rst-class:: sig-pretty-signature
   
      | fitWorld(**duration**\ : *number*\ ): *Promise*
   
   **Parameters**
   
      **duration**\ : *number*
   
   
   **Returns**\ : *Promise*
   



.. js:method:: IWebViewer.focusInput

   .. rst-class:: sig-pretty-signature
   
      | focusInput(**focus**\ : *boolean*\ ): *void*
   
   Sets whether keyboard input should be directed to this Web Viewer.
   
   **Parameters**
   
      **focus**\ : *boolean*
   
         if true, the Web Viewer will be focused and accept keyboard input, otherwise it will be blurred and not accept keyboard input
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.getAllowHighDpi

   .. rst-class:: sig-pretty-signature
   
      | getAllowHighDpi(): *boolean*
   
   Gets the current value for high DPI rendering
   
   **Returns**\ : *boolean*
   
      current high DPI setting
   
   



.. js:method:: IWebViewer.getContextMenuStatus

   .. rst-class:: sig-pretty-signature
   
      | getContextMenuStatus(): *boolean*
   
   **Returns**\ : *boolean*
   
      boolean true if the context menu is active, false otherwise
   
   



.. js:method:: IWebViewer.getFormatVersionString

   .. rst-class:: sig-pretty-signature
   
      | getFormatVersionString(): *string*
   
   Returns the format version string.
   
   **Returns**\ : *string*
   
      string containing version information for the format.
   
   



.. js:method:: IWebViewer.getMinimumFramerate

   .. rst-class:: sig-pretty-signature
   
      | getMinimumFramerate(): *Promise*
   
   Gets the minimum framerate that will be maintained by the viewer. The viewer will use various culling techniques in order to maintain the value returned.
   
   **Deprecated**
   
      Views can have independent framerates. This should be set using ``View.getMinimumFramerate``\ .
   
   
   **Returns**\ : *Promise*
   
      Promise that is resolved when the operation has completed.
   
   



.. js:method:: IWebViewer.getModelReady

   .. rst-class:: sig-pretty-signature
   
      | getModelReady(): *boolean*
   
   **Returns**\ : *boolean*
   



.. js:method:: IWebViewer.getRendererType

   .. rst-class:: sig-pretty-signature
   
      | getRendererType(): :js:data:`~RendererType`
   
   Gets the RendererType this viewer was created with.
   
   **Returns**\ : :js:data:`~RendererType`
   
      the render mode.
   
   



.. js:method:: IWebViewer.getSceneReady

   .. rst-class:: sig-pretty-signature
   
      | getSceneReady(): *boolean*
   
   **Returns**\ : *boolean*
   



.. js:method:: IWebViewer.getStatistics

   .. rst-class:: sig-pretty-signature
   
      | getStatistics(**calculateTotals**\ : *boolean*\ ): *Promise*
   
   Gets viewer statistics for the current rendered frame. Statistics marked with a (\*) below must be calculated and will not be included in the results unless the calculateTotals parameter is true. The values of these items will be cached and only updated during the next call to this method with calculateTotals set to true.
   
   **Parameters**
   
      **calculateTotals**\ : *boolean*
   
         Forces an update of the total count elements. Please note that repeatedly calculating these items can cause a performance impact.
   
   
   
   **Returns**\ : *Promise*
   
      an object containing informational key/value pairs
   
   



.. js:method:: IWebViewer.getStreamCutoffScale

   .. rst-class:: sig-pretty-signature
   
      | getStreamCutoffScale(): *number*
   
   Returns the scale factor that will be applied to the streaming size cutoff. An object whose projected size is lower than the cutoff will not be streamed until its projected size reaches the cutoff. A value of 0 disables the cutoff.
   
   **Returns**\ : *number*
   



.. js:method:: IWebViewer.getStreamingMode

   .. rst-class:: sig-pretty-signature
   
      | getStreamingMode(): :js:data:`~StreamingMode`
   
   Gets the streaming mode this viewer was created with.
   
   **Returns**\ : :js:data:`~StreamingMode`
   
      the streaming mode.
   
   



.. js:method:: IWebViewer.getView

   .. rst-class:: sig-pretty-signature
   
      | getView(**viewKey**\ : :js:data:`ViewKey <Sc.ViewKey>`\ ): (*undefined* \| :js:class:`~IView`\ )
   
   Gets a view with the provided key.
   
   **Parameters**
   
      **viewKey**\ : :js:data:`ViewKey <Sc.ViewKey>`
   
         The key of the view to be returned.
   
   
   
   **Returns**\ : (*undefined* \| :js:class:`~IView`\ )
   
      The view, or undefined if it doesn't exist.
   
   



.. js:method:: IWebViewer.getViewElement

   .. rst-class:: sig-pretty-signature
   
      | getViewElement(): *HTMLDivElement*
   
   Gets the view element for this viewer. This element contains the canvas
   
   **Returns**\ : *HTMLDivElement*
   
      the view element
   
   



.. js:method:: IWebViewer.getViewerVersionString

   .. rst-class:: sig-pretty-signature
   
      | getViewerVersionString(): *string*
   
   Returns the viewer version string.
   
   **Returns**\ : *string*
   
      string containing version information for the viewer.
   
   



.. js:method:: IWebViewer.moveToWindow

   .. rst-class:: sig-pretty-signature
   
      | moveToWindow(**win**\ : *Window*\ ): *void*
   
   This method should be called when the viewer is being moved to a new window. An example use case would be opening a new pop up window.
   
   **Parameters**
   
      **win**\ : *Window*
   
         the new document that this viewer will be associated with.
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.pauseRendering

   .. rst-class:: sig-pretty-signature
   
      | pauseRendering(**callback**\ : () => *void*\ ): *Promise*
   
   Pauses rendering updates for all views. This function is useful when performing large batches of updates and you would like the result to appear all at once.
   
   **Parameters**
   
      **callback**\ : () => *void*
   
         If provided, rendering will be paused, the callback will be called, and then rendering will be resumed once the callback returns or throws an exception.
   
   
   
   **Returns**\ : *Promise*
   



.. js:method:: IWebViewer.redraw

   .. rst-class:: sig-pretty-signature
   
      | redraw(**callback**\ : () => *void*\ ): *void*
   
   Forces the viewer to perform a full redraw of all views.
   
   **Parameters**
   
      **callback**\ : () => *void*
   
         A function to be called once the draw is complete. This is provided instead of a ``Promise`` to ensure the callback is called before the start of another redraw.
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.registerCustomOperator

   .. rst-class:: sig-pretty-signature
   
      | registerCustomOperator(**operator**\ : :js:class:`Operator <Operators.Operator>`\ ): :js:data:`~OperatorId`
   
   Associates a custom operator object with a system generated operatorId.
   
   **Parameters**
   
      **operator**\ : :js:class:`Operator <Operators.Operator>`
   
   
   **Returns**\ : :js:data:`~OperatorId`
   
      an operatorId to be used for this operator.
   
   



.. js:method:: IWebViewer.removeView

   .. rst-class:: sig-pretty-signature
   
      | removeView(**view**\ : :js:class:`~IView`\ ): *void*
   
   Removes an existing view from the page. Note that the default view cannot be removed.
   
   **Parameters**
   
      **view**\ : :js:class:`~IView`
   
         The view to remove.
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.reset

   .. rst-class:: sig-pretty-signature
   
      | reset(**durationCameraTransition**\ : *number*\ ): *Promise*
   
   Reset the camera, visibility, and transforms to their default state
   
   **Parameters**
   
      **durationCameraTransition**\ : *number*
   
   
   **Returns**\ : *Promise*
   
      Promise that resolves when the operation has completed.
   
   



.. js:method:: IWebViewer.resetClientTimeout

   .. rst-class:: sig-pretty-signature
   
      | resetClientTimeout(): *void*
   
   Resets the client timeout to the duration set with setClientTimeout.
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.resizeCanvas

   .. rst-class:: sig-pretty-signature
   
      | resizeCanvas(): *void*
   
   This method should be called after the container element is moved or resized.
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.resumeRendering

   .. rst-class:: sig-pretty-signature
   
      | resumeRendering(): *Promise*
   
   Resumes rendering for all views.
   
   **Returns**\ : *Promise*
   



.. js:method:: IWebViewer.selectPart

   .. rst-class:: sig-pretty-signature
   
      | selectPart(**nodeId**\ : (*None* \| *number*\ ), **selectionMode**\ : :js:data:`~SelectionMode`\ ): :js:data:`~SelectionType`
   
   Selects a part with the given Id.
   
   **Parameters**
   
      **nodeId**\ : (*None* \| *number*\ )
   
         nodeId of the part to select. Pass null to clear the selection.
   
   
      **selectionMode**\ : :js:data:`~SelectionMode`
   
   
   **Returns**\ : :js:data:`~SelectionType`
   



.. js:method:: IWebViewer.setAllowHighDpi

   .. rst-class:: sig-pretty-signature
   
      | setAllowHighDpi(**allow**\ : *boolean*\ ): *void*
   
   Controls rendering on high DPI displays. If true, the image will be rendered at full resolution when a high-DPI display is detected. If false, the image may be rendered at a lower resolution. The default value is false. This method may be called any time during or after the sceneReady callback has triggered.
   
   **Parameters**
   
      **allow**\ : *boolean*
   
         controls the high DPI Setting.
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.setCallbacks

   .. rst-class:: sig-pretty-signature
   
      | setCallbacks(**callbacks**\ : :js:class:`~CallbackMap`\ ): *void*
   
   Registers callbacks that will be called when their corresponding events occur.
   
   **Parameters**
   
      **callbacks**\ : :js:class:`~CallbackMap`
   
         object with property names set to corresponding functions to be called when the event occurs.
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.setClientTimeout

   .. rst-class:: sig-pretty-signature
   
      | setClientTimeout(**timeoutDuration**\ : *number*\ , **warningTime**\ : *number*\ ): *boolean*
   
   Sets the parameters for client driven timeout monitoring. If no input is recorded for the the duration, the viewer will disconnect and free server resources. Calling this method will reset any pending timeout duration. No timeout will occur when viewing SCS Files. The default value is to disconnect after 15 minutes, with a warning issued after 14 minutes of inactivity. <br><br> <strong>Please note:</strong> Both parameters are required.
   
   **Parameters**
   
      **timeoutDuration**\ : *number*
   
         the total time in minutes of inactivity that is allowed before a timeout event occurs
   
   
      **warningTime**\ : *number*
   
         the number of minutes before issuing a timeoutWarning event
   
   
   
   **Returns**\ : *boolean*
   
      boolean value indicating whether the timeout values were sucessfully updated
   
   



.. js:method:: IWebViewer.setContextMenuStatus

   .. rst-class:: sig-pretty-signature
   
      | setContextMenuStatus(**isActive**\ : *boolean*\ ): *void*
   
   Sets a boolean with the status of the context menu
   
   **Parameters**
   
      **isActive**\ : *boolean*
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.setMinimumFramerate

   .. rst-class:: sig-pretty-signature
   
      | setMinimumFramerate(**value**\ : *number*\ ): *Promise*
   
   Sets a minimum frame rate that will be maintained by all views. Views will use various culling techniques in order to maintain the value passed in.
   
   Passing ``0`` will cause the entire scene to be drawn for every frame.
   
   **Parameters**
   
      **value**\ : *number*
   
         The frame rate for the views to maintain.
   
   
   
   **Returns**\ : *Promise*
   
      Promise that is resolved when the operation has completed.
   
   



.. js:method:: IWebViewer.setServerRenderQuality

   .. rst-class:: sig-pretty-signature
   
      | setServerRenderQuality(**jpegQualityLow**\ : *number*\ , **jpegQualityHigh**\ : *number*\ , **scaleLow**\ : *number*\ , **scaleHigh**\ : *number*\ ): *void*
   
   Sets the image quality settings for the high quality and low quality server side render. The low quality settings will be applied during model interaction (camera changes, selection, etc)
   
   **Parameters**
   
      **jpegQualityLow**\ : *number*
   
         The JPEG quality of the low quality render frame
   
   
      **jpegQualityHigh**\ : *number*
   
         The JPEG quality of the high quality render frame
   
   
      **scaleLow**\ : *number*
   
         The scale factor for the low quality render frame
   
   
      **scaleHigh**\ : *number*
   
         The scale factor for the high quality render frame
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.setStreamCutoffScale

   .. rst-class:: sig-pretty-signature
   
      | setStreamCutoffScale(**value**\ : *number*\ ): *Promise*
   
   Specifies a scale factor that will be applied to the streaming size cutoff. An object whose projected size is lower than the cutoff will not be streamed until its projected size reaches the cutoff.
   
   This value may also be set for file-based sessions.  In that case, when loading an SCS file based assembly via XML, projected size will be calculated on a per-file basis using the bounding information provided in the XML. For additional information, refer to [[Model.loadSubtreeFromXmlBuffer]].
   
   A value of 0 will disable the cutoff.  The value should be in the interval of [0.0, 2.0].
   
   **Parameters**
   
      **value**\ : *number*
   
   
   **Returns**\ : *Promise*
   



.. js:method:: IWebViewer.setViewOrientation

   .. rst-class:: sig-pretty-signature
   
      | setViewOrientation(**orientation**\ : :js:data:`~ViewOrientation`\ , **duration**\ : *number*\ ): *Promise*
   
   Sets the orientation of the current model view.
   
   **Parameters**
   
      **orientation**\ : :js:data:`~ViewOrientation`
   
         a [[ViewOrientation]] object specifying back, front, top, etc.
   
   
      **duration**\ : *number*
   
         the time in milliseconds for the model to transition to the new view orientation.
   
   
   
   **Returns**\ : *Promise*
   



.. js:method:: IWebViewer.shutdown

   .. rst-class:: sig-pretty-signature
   
      | shutdown(): *void*
   
   Releases the resources used by the viewer. This method should be called when the viewer is no longer needed but the page is not being reloaded.
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.start

   .. rst-class:: sig-pretty-signature
   
      | start(): *boolean*
   
   Starts the viewer and begins the loading process
   
   **Returns**\ : *boolean*
   



.. js:method:: IWebViewer.takeSnapshot

   .. rst-class:: sig-pretty-signature
   
      | takeSnapshot(**config**\ : :js:class:`~SnapshotConfig`\ ): *Promise*
   
   Creates an Image of the current canvas
   
   **Parameters**
   
      **config**\ : :js:class:`~SnapshotConfig`
   
   
   **Returns**\ : *Promise*
   



.. js:method:: IWebViewer.trigger

   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"bcfLoaded"*\ , **id**\ : *number*\ , **filename**\ : *string*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"bcfLoaded"*
   
      **id**\ : *number*
   
      **filename**\ : *string*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"bcfRemoved"*\ , **id**\ : *number*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"bcfRemoved"*
   
      **id**\ : *number*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"handleEvent"*\ , **eventType**\ : :js:data:`~HandleEventType`\ , **nodeIds**\ : *number*\ [], **initialMatrices**\ : :js:class:`~Matrix`\ [], **newMatrices**\ : :js:class:`~Matrix`\ []): *void*
   
   **Parameters**
   
      **name**\ : *"handleEvent"*
   
      **eventType**\ : :js:data:`~HandleEventType`
   
      **nodeIds**\ : *number*\ []
   
      **initialMatrices**\ : :js:class:`~Matrix`\ []
   
      **newMatrices**\ : :js:class:`~Matrix`\ []
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"handleEventEnd"*\ , **eventType**\ : :js:data:`~HandleEventType`\ , **nodeIds**\ : *number*\ [], **initialMatrices**\ : :js:class:`~Matrix`\ [], **newMatrices**\ : :js:class:`~Matrix`\ []): *void*
   
   **Parameters**
   
      **name**\ : *"handleEventEnd"*
   
      **eventType**\ : :js:data:`~HandleEventType`
   
      **nodeIds**\ : *number*\ []
   
      **initialMatrices**\ : :js:class:`~Matrix`\ []
   
      **newMatrices**\ : :js:class:`~Matrix`\ []
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"handleEventStart"*\ , **eventType**\ : :js:data:`~HandleEventType`\ , **nodeIds**\ : *number*\ [], **initialMatrices**\ : :js:class:`~Matrix`\ []): *void*
   
   **Parameters**
   
      **name**\ : *"handleEventStart"*
   
      **eventType**\ : :js:data:`~HandleEventType`
   
      **nodeIds**\ : *number*\ []
   
      **initialMatrices**\ : :js:class:`~Matrix`\ []
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"cuttingPlaneDragStart"*\ , **cuttingSection**\ : :js:class:`~ICuttingSection`\ , **planeIndex**\ : *number*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"cuttingPlaneDragStart"*
   
      **cuttingSection**\ : :js:class:`~ICuttingSection`
   
      **planeIndex**\ : *number*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"cuttingPlaneDrag"*\ , **cuttingSection**\ : :js:class:`~ICuttingSection`\ , **planeIndex**\ : *number*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"cuttingPlaneDrag"*
   
      **cuttingSection**\ : :js:class:`~ICuttingSection`
   
      **planeIndex**\ : *number*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"cuttingPlaneDragEnd"*\ , **cuttingSection**\ : :js:class:`~ICuttingSection`\ , **planeIndex**\ : *number*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"cuttingPlaneDragEnd"*
   
      **cuttingSection**\ : :js:class:`~ICuttingSection`
   
      **planeIndex**\ : *number*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"cuttingSectionsLoaded"*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"cuttingSectionsLoaded"*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"redlineCreated"*\ , **redlineMarkup**\ : :js:class:`RedlineItem <Markup.Redline.RedlineItem>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"redlineCreated"*
   
      **redlineMarkup**\ : :js:class:`RedlineItem <Markup.Redline.RedlineItem>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"redlineDeleted"*\ , **redlineMarkup**\ : :js:class:`RedlineItem <Markup.Redline.RedlineItem>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"redlineDeleted"*
   
      **redlineMarkup**\ : :js:class:`RedlineItem <Markup.Redline.RedlineItem>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"redlineUpdated"*\ , **redlineMarkup**\ : :js:class:`RedlineItem <Markup.Redline.RedlineItem>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"redlineUpdated"*
   
      **redlineMarkup**\ : :js:class:`RedlineItem <Markup.Redline.RedlineItem>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"measurementBegin"*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"measurementBegin"*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"measurementCreated"*\ , **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"measurementCreated"*
   
      **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"measurementDeleted"*\ , **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"measurementDeleted"*
   
      **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"measurementValueSet"*\ , **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"measurementValueSet"*
   
      **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"measurementShown"*\ , **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"measurementShown"*
   
      **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"measurementHidden"*\ , **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"measurementHidden"*
   
      **measurement**\ : :js:class:`MeasureMarkup <Operators.Markup.Measure.MeasureMarkup>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"noteTextCreated"*\ , **noteText**\ : *NoteText*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"noteTextCreated"*
   
      **noteText**\ : *NoteText*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"noteTextDeleted"*\ , **noteText**\ : *NoteText*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"noteTextDeleted"*
   
      **noteText**\ : *NoteText*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"noteTextUpdated"*\ , **noteText**\ : *NoteText*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"noteTextUpdated"*
   
      **noteText**\ : *NoteText*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"noteTextHidden"*\ , **noteText**\ : *NoteText*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"noteTextHidden"*
   
      **noteText**\ : *NoteText*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"noteTextShown"*\ , **noteText**\ : *NoteText*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"noteTextShown"*
   
      **noteText**\ : *NoteText*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"walkOperatorActivated"*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"walkOperatorActivated"*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"walkOperatorDeactivated"*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"walkOperatorDeactivated"*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"viewCreated"*\ , **view**\ : :js:class:`MarkupView <Markup.MarkupView>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"viewCreated"*
   
      **view**\ : :js:class:`MarkupView <Markup.MarkupView>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"viewDeleted"*\ , **view**\ : :js:class:`MarkupView <Markup.MarkupView>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"viewDeleted"*
   
      **view**\ : :js:class:`MarkupView <Markup.MarkupView>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"viewLoaded"*\ , **view**\ : :js:class:`MarkupView <Markup.MarkupView>`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"viewLoaded"*
   
      **view**\ : :js:class:`MarkupView <Markup.MarkupView>`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"contextMenu"*\ , **position**\ : :js:class:`~Point2`\ , **modifiers**\ : :js:data:`~KeyModifiers`\ ): *void*
   
   **Parameters**
   
      **name**\ : *"contextMenu"*
   
      **position**\ : :js:class:`~Point2`
   
      **modifiers**\ : :js:data:`~KeyModifiers`
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"beginInteraction"*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"beginInteraction"*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : *"endInteraction"*\ ): *void*
   
   **Parameters**
   
      **name**\ : *"endInteraction"*
   
   
   **Returns**\ : *void*
   
   .. rst-class:: sig-pretty-signature
   
      | trigger(**name**\ : keyof :js:class:`~CallbackMap`\ , **args**\ : *any*\ []): *void*
   
   Used to trigger Web Viewer events from operators. Refer to the overloaded method signatures for acceptable invocations of this method. Refer to [[CallbackMap]] for additional details for each event.
   
   **Parameters**
   
      **name**\ : keyof :js:class:`~CallbackMap`
   
      **args**\ : *any*\ []
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.unregisterCustomOperator

   .. rst-class:: sig-pretty-signature
   
      | unregisterCustomOperator(**operatorId**\ : :js:data:`~OperatorId`\ ): *void*
   
   Removes a previously registered custom operator from the system.
   
   **Parameters**
   
      **operatorId**\ : :js:data:`~OperatorId`
   
         the ID of the operator that is to be unregistered
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.unsetCallbacks

   .. rst-class:: sig-pretty-signature
   
      | unsetCallbacks(**callbacks**\ : :js:class:`~CallbackMap`\ ): *void*
   
   Unregisters callbacks from the system. Note the actual function object passed in must be the same as the one that was registered using setCallbacks.
   
   **Parameters**
   
      **callbacks**\ : :js:class:`~CallbackMap`
   
         object with property names set to corresponding functions to be unregistered.
   
   
   
   **Returns**\ : *void*
   



.. js:method:: IWebViewer.waitForIdle

   .. rst-class:: sig-pretty-signature
   
      | waitForIdle(**config**\ : { redraw: *boolean* }): *Promise*
   
   Returns a Promise that will resolve after streaming and associated asynchronous operations complete and the scene is fully drawn.
   
   **Parameters**
   
      **config**\ : { redraw: *boolean* }
   
   
   **Returns**\ : *Promise*
   





