Specifies how the zoom level affects the rendering of styles that are used as selection, highlight, or focus indicator.
Type Details
- yFiles module
- view
Constants
Uses WORLD_COORDINATES rendering for zoom level ≥ 1 and VIEW_COORDINATES rendering for zoom level < 1.
Remarks
While the decoration is rendered in view coordinates, its actual bounds are still in world coordinates. This is useful for e.g. highlight decorations where stroke size and padding of the decoration should be clearly visible at larger zoom levels. The bounds of the decoration, on the other hand, should still fit the decorated item's bounds.
Uses WORLD_COORDINATES rendering for zoom level ≥ 1 and VIEW_COORDINATES rendering for zoom level < 1, but in the latter case, the visual does not scale down below its initial size.
Remarks
This ensures that the style decorations remain clearly visible and do not become too small to discern when the user zooms out. The bounds of the decoration, on the other hand, exceed the decorated item's bounds, which may result in visual overlaps with other items.
The visual is rendered in intermediate coordinates (the same as view coordinates if projection is not used) and does not scale with the zoom level.
Remarks
This is similar to handles, for example, which also do not scale with the zoom level.
If a projection is set, this is really the intermediate coordinate system, despite the name of this constant. This will not make a difference to most developers, so the name remained the same to prevent an incompatible API change.
Static Methods
Converts the given argument to an enum constant of this enum type.
Remarks
Most notably, this method can convert an enum constant's name into the enum constant itself.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- value - StyleIndicatorZoomPolicy
- The value to convert to an enum constant.
Returns
- ↪StyleIndicatorZoomPolicy
- The enum constant that corresponds to the given argument.
Returns the name of the given enum constant.
Parameters
options - Object
A map of options to pass to the method.
A map of options to pass to the method.
- value - StyleIndicatorZoomPolicy
- The numeric value of an enum constant.
Returns
- ↪string
- The name of the enum constant.
Throws
- Exception({ name: 'Error' })
- If this type is a flags enums, and the provided value doesn't correspond to a single enum constant, or if this enum type contains no constant of the given numeric value.