diff --git a/docs/config.json b/docs/config.json index d024eef942..5ad8155d11 100644 --- a/docs/config.json +++ b/docs/config.json @@ -15,6 +15,7 @@ "FeatureBuildingOptions", "Style", "StyleOptions", + "StyleContext", "Label" ], diff --git a/src/Core/Style.js b/src/Core/Style.js index 105c6d51f5..18becb7f85 100644 --- a/src/Core/Style.js +++ b/src/Core/Style.js @@ -158,12 +158,29 @@ function defineStyleProperty(style, category, name, value, defaultValue) { style[category][name] = value; } +/** + * @class + * @classdesc StyleContext is a class to store all informations + * about context to generate the style of each FeatureGeometry. + * + * @property {Coordinates} worldCoord @private Coordinates of the FeatureGeometry in world system. + * @property {Coordinates} localCoordinates @private Are the coordinates systeme origin local or global. + * @property {Feature} feature @private + * @property {FeatureGeometry} geometry @private + * @property {Object} globals + * @property {Object} collections + * @property {Number} type + * @property {Coordinates} coordinates + */ + export class StyleContext { #worldCoord = new Coordinates('EPSG:4326', 0, 0, 0); #localCoordinates = new Coordinates('EPSG:4326', 0, 0, 0); #feature = {}; #geometry = {}; - + /** + * @constructor + */ constructor() { this.globals = {}; }