Some additions to View2d docs

[ci skip]
This commit is contained in:
Peter Robins
2013-10-22 07:15:30 -04:00
parent ba1a4cbac8
commit f5c6565617

View File

@@ -102,8 +102,9 @@
* @typedef {Object} ol.View2DOptions * @typedef {Object} ol.View2DOptions
* @property {ol.Coordinate|undefined} center The initial center for the view. * @property {ol.Coordinate|undefined} center The initial center for the view.
* The coordinate system for the center is specified with the `projection` * The coordinate system for the center is specified with the `projection`
* option. * option. Default is null.
* @property {ol.Extent|undefined} extent The extent to constraint the center to. * @property {ol.Extent|undefined} extent The extent that constrains the center,
* in other words, center cannot be set outside this extent. Default is none
* @property {number|undefined} maxResolution The maximum resolution used to * @property {number|undefined} maxResolution The maximum resolution used to
* determine the resolution constraint. It is used together with `maxZoom` * determine the resolution constraint. It is used together with `maxZoom`
* and `zoomFactor`. If unspecified it is calculated in such a way that the * and `zoomFactor`. If unspecified it is calculated in such a way that the
@@ -117,16 +118,18 @@
* `EPSG:3857` (Spherical Mercator). * `EPSG:3857` (Spherical Mercator).
* @property {number|undefined} resolution The initial resolution for the view. * @property {number|undefined} resolution The initial resolution for the view.
* The units are `projection` units per pixel (e.g. meters per pixel). * The units are `projection` units per pixel (e.g. meters per pixel).
* An alternative to setting this is to set `zoom`.
* @property {Array.<number>|undefined} resolutions Resolutions to determine the * @property {Array.<number>|undefined} resolutions Resolutions to determine the
* resolution constraint. If set the `maxResolution`, `maxZoom` and * resolution constraint. If set the `maxResolution`, `maxZoom` and
* `zoomFactor` options are ignored. * `zoomFactor` options are ignored.
* @property {number|undefined} rotation The initial rotation for the view * @property {number|undefined} rotation The initial rotation for the view
* in radians (positive rotation clockwise). * in radians (positive rotation clockwise). Default is 0.
* @property {number|undefined} zoom Zoom level used to calculate the initial * @property {number|undefined} zoom Only used if `resolution` is not defined.
* resolution for the view. The initial resolution is determined using the * Zoom level used to calculate the initial resolution for the view.
* The initial resolution is determined using the
* `ol.View2D#constrainResolution` method. * `ol.View2D#constrainResolution` method.
* @property {number|undefined} zoomFactor The zoom factor used to determine the * @property {number|undefined} zoomFactor The zoom factor used to determine the
* resolution constraint. It is together with `maxResolution` and `maxZoom`. * resolution constraint. Used together with `maxResolution` and `maxZoom`.
* Default is 2. * Default is 2.
*/ */