diff options
author | Fabian Guerra Soto <fabian.guerra@mapbox.com> | 2019-03-15 16:10:27 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-15 16:10:27 -0700 |
commit | 7939ff213a98de055e93ddd893ccae40b82a7d16 (patch) | |
tree | f23371b62e4ce1e4964361a04c0b11a39ede8569 /platform/darwin/docs/guides/Predicates and Expressions.md | |
parent | c8cfdb1ced822711e772dfcc8f708b1a7a68b5fc (diff) | |
download | qtlocation-mapboxgl-7939ff213a98de055e93ddd893ccae40b82a7d16.tar.gz |
[ios, macos] Add format expression convenience methods support. (#14094)
Added the ios/macos format expression bindings.
The equivalent is mgl_attributed: or mgl_attributed({}) when making an expression using the expressionForFormat selector.
A new constructor called mgl_expressionForAttributedExpressions:(NSArray<NSExpression*>*)attributedExpressions was added to NSExpression+MGLAdditions category.
Updated the symbol style layer text test to use the bindings.
Updated the Predicates and Expressions.md and For Style Authors.md.ejs template with the bindings.
Diffstat (limited to 'platform/darwin/docs/guides/Predicates and Expressions.md')
-rw-r--r-- | platform/darwin/docs/guides/Predicates and Expressions.md | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/platform/darwin/docs/guides/Predicates and Expressions.md b/platform/darwin/docs/guides/Predicates and Expressions.md index 0bb26b3bfd..5f5d9a22a8 100644 --- a/platform/darwin/docs/guides/Predicates and Expressions.md +++ b/platform/darwin/docs/guides/Predicates and Expressions.md @@ -534,6 +534,22 @@ This function corresponds to the [`coalesce`](https://www.mapbox.com/mapbox-gl-js/style-spec/#expressions-coalesce) operator in the Mapbox Style Specification. +### `mgl_attributed:` + +<dl> +<dt>Selector:</dt> +<dd><code>mgl_attributed:</code></dd> +<dt>Format string syntax:</dt> +<dd><code>mgl_attributed({x, y, z})</code></dd> +</dl> + +Concatenates and returns the array of `MGLAttributedExpression` objects, for use +with the `MGLSymbolStyleLayer.text` property. + +This function corresponds to the +[`format`](https://www.mapbox.com/mapbox-gl-js/style-spec/#expressions-types-format) +operator in the Mapbox Style Specification. + ### `MGL_LET` <dl> |