summaryrefslogtreecommitdiff
path: root/scripts/generate-style-code.js
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/generate-style-code.js')
-rw-r--r--scripts/generate-style-code.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/generate-style-code.js b/scripts/generate-style-code.js
index b1d0ed28ec..443f0c7cc9 100644
--- a/scripts/generate-style-code.js
+++ b/scripts/generate-style-code.js
@@ -29,6 +29,9 @@ global.evaluatedType = function (property) {
if (/-(rotation|pitch|illumination)-alignment$/.test(property.name)) {
return 'AlignmentType';
}
+ if (/^(text|icon)-anchor$/.test(property.name)) {
+ return 'SymbolAnchorType';
+ }
if (/position/.test(property.name)) {
return 'Position';
}
@@ -183,8 +186,8 @@ for (const layer of layers) {
writeIfModified(`src/mbgl/style/layers/${layerFileName}_layer_properties.cpp`, propertiesCpp(layer));
}
-const propertySettersHpp = ejs.compile(fs.readFileSync('include/mbgl/style/conversion/make_property_setters.hpp.ejs', 'utf8'), {strict: true});
-writeIfModified('include/mbgl/style/conversion/make_property_setters.hpp', propertySettersHpp({layers: layers}));
+const propertySettersHpp = ejs.compile(fs.readFileSync('src/mbgl/style/conversion/make_property_setters.hpp.ejs', 'utf8'), {strict: true});
+writeIfModified('src/mbgl/style/conversion/make_property_setters.hpp', propertySettersHpp({layers: layers}));
// Light
const lightProperties = Object.keys(spec[`light`]).reduce((memo, name) => {