Skip to main content

CursorKeyboardRotationConfiguration

Options to configure cursor/keyboard rotation.

Cursor/keyboard rotation is designed for desktop platforms, and allows the cursor to be used to set the rotation of the map whilst a keyboard key is held down (as triggered by is_key_trigger).

Properties

  • behavior - The behaviour of the cursor/keyboard rotation function in terms of the angle that the map is rotated to.
  • set_north_on_click - Whether to set the North of the map to the clicked angle, when the user clicks their mouse without dragging (a on_pointer_down event followed by on_pointer_up without a change in rotation).
  • trigger_keys - List of keys that will trigger cursor/keyboard rotation, when pressed.

Methods

  • disabled - A disabled CursorKeyboardRotationConfiguration.

Properties

behaviorclass-attributeinstance-attribute

The behaviour of the cursor/keyboard rotation function in terms of the angle that the map is rotated to.

Does not disable cursor/keyboard rotation, or adjust its triggers: see is_key_trigger.

set_north_on_clickclass-attributeinstance-attribute

set_north_on_click: bool = True

Whether to set the North of the map to the clicked angle, when the user clicks their mouse without dragging (a on_pointer_down event followed by on_pointer_up without a change in rotation).

trigger_keysclass-attributeinstance-attribute

trigger_keys: list = field(default_factory=(lambda: []))

List of keys that will trigger cursor/keyboard rotation, when pressed.

Methods

disabledclassmethod

disabled(cls)

A disabled CursorKeyboardRotationConfiguration.