-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Favor previous anchor only when still available
- Loading branch information
Asheem Mamoowala
committed
Jul 15, 2019
1 parent
be7e27f
commit 1791ada
Showing
3 changed files
with
77 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+842 Bytes
.../render-tests/runtime-styling/layout-property-text-variable-anchor/expected.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
73 changes: 73 additions & 0 deletions
73
...on/render-tests/runtime-styling/layout-property-text-variable-anchor/style.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
{ | ||
"version": 8, | ||
"metadata": { | ||
"test": { | ||
"width": 64, | ||
"height": 64, | ||
"operations": [ | ||
[ | ||
"setLayoutProperty", | ||
"symbol", | ||
"text-variable-anchor", | ||
["bottom"] | ||
], | ||
[ | ||
"wait" | ||
] | ||
] | ||
} | ||
}, | ||
"transition": { | ||
"duration": 0 | ||
}, | ||
"sources": { | ||
"geojson": { | ||
"type": "geojson", | ||
"data": { | ||
"type": "FeatureCollection", | ||
"features": [ | ||
{ | ||
"type": "Feature", | ||
"geometry": { | ||
"type": "Point", | ||
"coordinates": [ | ||
0, | ||
0 | ||
] | ||
} | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
"glyphs": "local://glyphs/{fontstack}/{range}.pbf", | ||
"layers": [ | ||
{ | ||
"id": "symbol", | ||
"type": "symbol", | ||
"source": "geojson", | ||
"layout": { | ||
"text-variable-anchor": ["left"], | ||
"text-field": "ABC", | ||
"text-font": [ | ||
"Open Sans Semibold", | ||
"Arial Unicode MS Bold" | ||
], | ||
"symbol-placement": "point" | ||
}, | ||
"paint": { | ||
"text-color": "red" | ||
} | ||
}, | ||
{ | ||
"id" : "dot", | ||
"type": "circle", | ||
"source": "geojson", | ||
"paint": { | ||
"circle-color": "red" | ||
} | ||
|
||
} | ||
] | ||
} | ||
|