WinJS.UI.SemanticZoom constructor
Creates a new SemanticZoom.
Syntax
var semanticZoom = new WinJS.UI.SemanticZoom(element, options);
Parameters
element
Type: VariantThe DOM element that hosts the SemanticZoom.
options [optional]
Type: ObjectAn object that contains one or more property/value pairs to apply to the new control. This object can contain these properties:
Value | Meaning |
---|---|
initiallyZoomedOut Boolean | The initial zoom state of the SemanticZoom object. The default value is true, or zoomed out. |
zoomFactor 0.2–0.85 | The minimum scaling factor applied to the zoomed out view. The default is 0.65. When zoomed in, the zoomed in view is set to 100% of its normal size. Similarly, when zoomed out, the zoomed out view is set to 100% of its normal size. However, the two controls are scaled differently relative to one another. For example, if zoomFactor is set to 0.4 the following occurs:
zoomFactor just determines those two numbers: 0.4 yields 40% and 250%, 0.5 yields 50% and 200%, 0.8 yields 80% and 125%, and so on. If a value outside that range is passed in, it is clipped to the closest value of the range. |
Requirements
Minimum WinJS version |
WinJS 1.0 |
Namespace |
WinJS.UI |