mapbox / mapbox/mapbox-gl-js

Account for character descenders in text-radial-offset

Open
#8,560 13 comments 0 reactions 3 assignees View on GitHub

@zmiao is already working on this.

Since Sep 19, 2019.

cross-platform :tv: feature :green_apple:
Dominant language
TypeScript
Stars
12.4k
Forks
2.4k
PR merge metrics
No merged PRs in 30d

Description

## Motivation

Like `text-offset` that accepts number or an array of two numbers that adjusts the `x` and `y` coordinates, it would be great if `text-radial-offset` allowed the same functionality. That would account for the extra distance top positioned labels need for characters with descenders (i.e `g, p, q`):

Screen Shot 2019-07-26 at 10 09 31 AM

## Design Alternatives

Not provide `top` as a list of possible positions to `text-variable-anchor` but that's a little limiting.

## Design

```js
{
text-radial-offset: [0.5, 1] // x, y
}
```

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.