diff options
author | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2019-09-02 18:30:40 +0300 |
---|---|---|
committer | Mikhail Pozdnyakov <mikhail.pozdnyakov@mapbox.com> | 2019-09-03 11:45:17 +0300 |
commit | 3b5a43c722e3dda1c05c37787296eab456614a77 (patch) | |
tree | 14bd39ed532a2087f883b5c16ecea51023ad2cf9 /src/mbgl/layout/symbol_instance.cpp | |
parent | 0fa5944f39854f42c86ce478da8869a8d4e3f1fe (diff) | |
download | qtlocation-mapboxgl-3b5a43c722e3dda1c05c37787296eab456614a77.tar.gz |
[core] Enable `text-offset` with variable label placement
Port of https://github.com/mapbox/mapbox-gl-js/pull/8642
Diffstat (limited to 'src/mbgl/layout/symbol_instance.cpp')
-rw-r--r-- | src/mbgl/layout/symbol_instance.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mbgl/layout/symbol_instance.cpp b/src/mbgl/layout/symbol_instance.cpp index ad36e6c38c..41a00e0131 100644 --- a/src/mbgl/layout/symbol_instance.cpp +++ b/src/mbgl/layout/symbol_instance.cpp @@ -87,7 +87,7 @@ SymbolInstance::SymbolInstance(Anchor& anchor_, const float overscaling, const float iconRotation, const float textRotation, - float radialTextOffset_, + const std::array<float, 2>& variableTextOffset_, bool allowVerticalPlacement, const SymbolContent iconType) : sharedData(std::move(sharedData_)), @@ -104,7 +104,7 @@ SymbolInstance::SymbolInstance(Anchor& anchor_, iconOffset(iconOffset_), key(std::move(key_)), textBoxScale(textBoxScale_), - radialTextOffset(radialTextOffset_), + variableTextOffset(variableTextOffset_), singleLine(shapedTextOrientations.singleLine) { // 'hasText' depends on finding at least one glyph in the shaping that's also in the GlyphPositionMap if(!sharedData->empty()) symbolContent |= SymbolContent::Text; |