-
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.
Enable
text-offset
with variable label placement
This PR allows using of `text-offset` together with `text-variable-anchor`, if `text-radial-offset` is not provided. Assuming we got `text-offset` [x, y] the offset is calculated based on the `text-variable-anchor` values as following: "left": [-x, 0] "right": [x, 0] "top": [0, -y] "bottom": [0, y] "top-left": [-x, -y] "top-right": [x, -y] "bottom-left": [-x, y] "bottom-right": [x, y] We allow only positive `text-offset` values for simplicity.
- Loading branch information
1 parent
9a3934c
commit 5edb0b0
Showing
6 changed files
with
232 additions
and
61 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
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
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
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
+2.28 KB
...nder-tests/text-variable-anchor/all-anchors-two-dimentional-offset/expected.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.