Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Make gl-native handling of newlines conform to gl-js behavior #7253

Closed

Description

@ChrisLoer

When I ported my recent gl-native line breaking changes to gl-js, I found that gl-js has tests for labels with newlines in them (https://github.com/mapbox/mapbox-gl-js/blob/master/test/js/symbol/shaping.test.js). The gl-js tests expect each newline to cause a new line to be created, while gl-native will just treat them like whitespace (so two newlines in the middle of your label will be collapsed down to just one breaking point instead of inserting a blank line).

I'm not sure when we would expect labels to have newlines in them, but we should probably standardize on one behavior or the other.

cc @ansis @1ec5

Activity

  1. added
    GL JS parity
    on Dec 1, 2016
  2. self-assigned this
    on Dec 1, 2016
  3. 1ec5 commented on Dec 1, 2016

    @1ec5
    Contributor

    The GL JS behavior sounds more correct.

  4. ChrisLoer commented on Dec 1, 2016

    @ChrisLoer
    ContributorAuthor

    Ah, I just had to look through the file history to see it was recently added as an enhancement: mapbox/mapbox-gl-js#955

  5. ChrisLoer commented on Dec 14, 2016

    @ChrisLoer
    ContributorAuthor

    I'll address this with a port of mapbox/mapbox-gl-js#3743 to gl-native. I have the code ready, but waiting for the first PR to go in before making a new PR to keep the test changes from conflicting.

  6. 1ec5 commented on Dec 29, 2016

    @1ec5
    Contributor

    This is happening in #7446.

  7. ChrisLoer commented on Jan 5, 2017

    @ChrisLoer
    ContributorAuthor

    Closed with #7446.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

GL JS paritytext rendering

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions