diff --git a/src/ol/style/Circle.js b/src/ol/style/Circle.js index 64dc96cd3a..190d8f5f20 100644 --- a/src/ol/style/Circle.js +++ b/src/ol/style/Circle.js @@ -38,11 +38,10 @@ class CircleStyle extends RegularShape { } /** - * Clones the style. - * @return {CircleStyle} The cloned style. - * @override - * @api - */ + * Clones the style. + * @return {CircleStyle} The cloned style. + * @api + */ clone() { const style = new CircleStyle({ fill: this.getFill() ? this.getFill().clone() : undefined, diff --git a/src/ol/style/Icon.js b/src/ol/style/Icon.js index 9882e4e274..60f6ddd7b7 100644 --- a/src/ol/style/Icon.js +++ b/src/ol/style/Icon.js @@ -225,7 +225,9 @@ class Icon extends ImageStyle { } /** - * @inheritDoc + * Get the anchor point in pixels. The anchor determines the center point for the + * symbolizer. + * @return {Array} Anchor. * @api */ getAnchor() { @@ -293,7 +295,6 @@ class Icon extends ImageStyle { * Get the image icon. * @param {number} pixelRatio Pixel ratio. * @return {HTMLImageElement|HTMLCanvasElement} Image or Canvas element. - * @override * @api */ getImage(pixelRatio) { @@ -301,35 +302,37 @@ class Icon extends ImageStyle { } /** - * @override + * @return {import("../size.js").Size} Image size. */ getImageSize() { return this.iconImage_.getSize(); } /** - * @override + * @return {import("../size.js").Size} Size of the hit-detection image. */ getHitDetectionImageSize() { return this.getImageSize(); } /** - * @override + * @return {import("../ImageState.js").default} Image state. */ getImageState() { return this.iconImage_.getImageState(); } /** - * @override + * @param {number} pixelRatio Pixel ratio. + * @return {HTMLImageElement|HTMLCanvasElement} Image element. */ getHitDetectionImage(pixelRatio) { return this.iconImage_.getHitDetectionImage(pixelRatio); } /** - * @inheritDoc + * Get the origin of the symbolizer. + * @return {Array} Origin. * @api */ getOrigin() { @@ -371,7 +374,8 @@ class Icon extends ImageStyle { } /** - * @inheritDoc + * Get the size of the icon (in pixels). + * @return {import("../size.js").Size} Image size. * @api */ getSize() { @@ -379,7 +383,7 @@ class Icon extends ImageStyle { } /** - * @override + * @param {function(import("../events/Event.js").default): void} listener Listener function. */ listenImageChange(listener) { this.iconImage_.addEventListener(EventType.CHANGE, listener); @@ -390,7 +394,6 @@ class Icon extends ImageStyle { * When rendering a feature with an icon style, the vector renderer will * automatically call this method. However, you might want to call this * method yourself for preloading or other purposes. - * @override * @api */ load() { @@ -398,7 +401,7 @@ class Icon extends ImageStyle { } /** - * @override + * @param {function(import("../events/Event.js").default): void} listener Listener function. */ unlistenImageChange(listener) { this.iconImage_.removeEventListener(EventType.CHANGE, listener); diff --git a/src/ol/style/IconImage.js b/src/ol/style/IconImage.js index 38ca4cda5c..cde9a86523 100644 --- a/src/ol/style/IconImage.js +++ b/src/ol/style/IconImage.js @@ -170,6 +170,7 @@ class IconImage extends EventTarget { } /** + * Get the size of the icon (in pixels). * @return {import("../size.js").Size} Image size. */ getSize() { diff --git a/src/ol/style/Image.js b/src/ol/style/Image.js index 3e01ddc84f..700792b4a1 100644 --- a/src/ol/style/Image.js +++ b/src/ol/style/Image.js @@ -233,7 +233,6 @@ class ImageStyle { /** * @abstract * @param {function(import("../events/Event.js").default): void} listener Listener function. - * @template T */ listenImageChange(listener) { abstract(); @@ -250,7 +249,6 @@ class ImageStyle { /** * @abstract * @param {function(import("../events/Event.js").default): void} listener Listener function. - * @template T */ unlistenImageChange(listener) { abstract(); diff --git a/src/ol/style/RegularShape.js b/src/ol/style/RegularShape.js index 30f017ef91..463d99d353 100644 --- a/src/ol/style/RegularShape.js +++ b/src/ol/style/RegularShape.js @@ -171,7 +171,9 @@ class RegularShape extends ImageStyle { } /** - * @inheritDoc + * Get the anchor point in pixels. The anchor determines the center point for the + * symbolizer. + * @return {Array} Anchor. * @api */ getAnchor() { @@ -197,14 +199,17 @@ class RegularShape extends ImageStyle { } /** - * @inheritDoc + * @param {number} pixelRatio Pixel ratio. + * @return {HTMLImageElement|HTMLCanvasElement} Image element. */ getHitDetectionImage(pixelRatio) { return this.hitDetectionCanvas_; } /** - * @inheritDoc + * Get the image icon. + * @param {number} pixelRatio Pixel ratio. + * @return {HTMLImageElement|HTMLCanvasElement} Image or Canvas element. * @api */ getImage(pixelRatio) { @@ -212,28 +217,29 @@ class RegularShape extends ImageStyle { } /** - * @inheritDoc + * @return {import("../size.js").Size} Image size. */ getImageSize() { return this.imageSize_; } /** - * @inheritDoc + * @return {import("../size.js").Size} Size of the hit-detection image. */ getHitDetectionImageSize() { return this.hitDetectionImageSize_; } /** - * @inheritDoc + * @return {import("../ImageState.js").default} Image state. */ getImageState() { return ImageState.LOADED; } /** - * @inheritDoc + * Get the origin of the symbolizer. + * @return {Array} Origin. * @api */ getOrigin() { @@ -268,7 +274,8 @@ class RegularShape extends ImageStyle { } /** - * @inheritDoc + * Get the size of the symbolizer (in pixels). + * @return {import("../size.js").Size} Size. * @api */ getSize() { @@ -285,17 +292,17 @@ class RegularShape extends ImageStyle { } /** - * @inheritDoc + * @param {function(import("../events/Event.js").default): void} listener Listener function. */ listenImageChange(listener) {} /** - * @inheritDoc + * Load not yet loaded URI. */ load() {} /** - * @inheritDoc + * @param {function(import("../events/Event.js").default): void} listener Listener function. */ unlistenImageChange(listener) {}