# NavigationConfig

class `cee.``NavigationConfig`()

  Navigation configuration for a view.

  Specify how mouse and touch input should be used to navigate the view (move the camera).

  Note: To use the right mouse button (either rightMouseButton or leftAndRightMouseButtons), you need to disable the default context menu in the browser (see example below).

  Example on how to configure “Envision style” navigation:

      // Disable context menu - Required for enableMouseButtonTracking
      canvas.addEventListener("contextmenu", (event) => { event.preventDefault()});

      // Enable mouse tracking (so we can use leftAndRightMouseButtons)
      viewer.enableMouseButtonTracking(true);

      // Envision style navigation
      const navConfig = view.navigation.config;
      navConfig.leftMouseButton.noModifier =cee.NavigationType.PAN;
      navConfig.rightMouseButton.noModifier =cee.NavigationType.ROTATE;
      navConfig.leftAndRightMouseButtons.noModifier =cee.NavigationType.WALK;
      navConfig.wheelOrPinch = cee.NavigationType.WALK;

Properties

- `invertWalkZoom`
- `invertWheel`
- `leftAndRightMouseButtons`
- `leftMouseButton`
- `middleMouseButton`
- `oneFinger`
- `rightMouseButton`
- `twoFinger`
- `wheelOrPinch`

## Properties

`NavigationConfig.``invertWalkZoom`

  Type: | boolean

  Invert zoom or walk. If true, camera will zoom out if mouse is moved up

  Default is false

`NavigationConfig.``invertWheel`

  Type: | boolean

  Invert the zoom direction of the mouse wheel

  Default is false

`NavigationConfig.``leftAndRightMouseButtons`

  Type: | NavigationMouseButtonConfig

  Navigation config when both left and right mouse buttons are pressed.

  Default is NONE for all modifier states.

  Note: To use the leftAndRightMouseButtons you have to enable mouse tracking in the viewer. See `Viewer.enableMouseButtonTracking`. This again requires the browser context menu to be disabled

`NavigationConfig.``leftMouseButton`

  Type: | NavigationMouseButtonConfig

  Navigation config for left mouse button.

  Default is

  - no modifiers -> ROTATE
  - shift pressed -> WALK
  - ctrl or cmd pressed -> PAN

`NavigationConfig.``middleMouseButton`

  Type: | NavigationMouseButtonConfig

  Navigation config for middle mouse button.

  Default is NONE for all modifier states.

`NavigationConfig.``oneFinger`

  Type: | NavigationType

  Navigation type to use for one finger dragging.

  Default is ROTATE

`NavigationConfig.``rightMouseButton`

  Type: | NavigationMouseButtonConfig

  Navigation config for right mouse button.

  Default is NONE for all modifier states.

`NavigationConfig.``twoFinger`

  Type: | NavigationType

  Navigation type to use for two finger dragging.

  Default is PAN

`NavigationConfig.``wheelOrPinch`

  Type: | NavigationType

  Navigation type to use for mouse wheel/touch screen pinch events.

  Default is WALK

Conversation saved
HOOPSY BETA

### Hello! I'm HOOPSY

Your multilingual generative AI assistant for documentation. Ask me anything about HOOPS Envision for Web in your own language, or choose a sample question below to start a conversation:

What is HOOPS Envision for Web?
What are the latest release notes for HOOPS Envision for Web?
How do I start evaluating HOOPS Envision for Web?
How do I write my first sample application?
How can I get assistance?

HOOPSY may store conversations according to OpenAI's policy. Responses may not always be accurate.

HOOPSY is thinking...