Add rotateWithView option to ol.style.Text
This commit is contained in:
@@ -28,6 +28,12 @@ ol.style.Text = function(opt_options) {
|
||||
*/
|
||||
this.rotation_ = options.rotation;
|
||||
|
||||
/**
|
||||
* @private
|
||||
* @type {boolean|undefined}
|
||||
*/
|
||||
this.rotateWithView_ = options.rotateWithView;
|
||||
|
||||
/**
|
||||
* @private
|
||||
* @type {number|undefined}
|
||||
@@ -129,6 +135,16 @@ ol.style.Text.prototype.getFill = function() {
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Determine whether the text rotates with the map.
|
||||
* @return {boolean|undefined} Rotate with map.
|
||||
* @api
|
||||
*/
|
||||
ol.style.Text.prototype.getRotateWithView = function() {
|
||||
return this.rotateWithView_;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Get the text rotation.
|
||||
* @return {number|undefined} Rotation.
|
||||
|
||||
Reference in New Issue
Block a user