Cartographic features for Japanese maps

No items found.

Feb 27, 2019

Cartographic features for Japanese maps

Guest

No items found.

Guest

Feb 27, 2019

As we continue to enhance our maps in Japan, here’s a look at our favorite cartographic features available to add to any map or visualization.

GL rendering for CJK glyphs


Global Japanese labels

All maps have Japanese-language labels available anywhere in the world from our global dataset.

Image for post

Image for post

Bilingual labels with formatted text

Display two languages at the same time using a format expression:


map.setLayoutProperty(layer, 'text-field', ['format',
     ['get', 'name_ja'], { 'font-scale': 1.2 },
     '\n', {},
     ['get', 'name_en'], {
          'font-scale': 0.8
     }
]);
Image for post

Local glyph generation for CJK

Using local glyphs for CJK text instead of embedded fonts can have significant performance improvements for your map. CJK glyphs are detailed and heavy in terms of file size, so we offer a feature to bypass remotely loading fonts and default to a local font that’s already on your user’s phone or computer.

Image for post

var map = new mapboxgl.Map({
container: 'map',
style: 'mapbox://styles/mapbox/streets-v9',
center: [120.3049, 31.4751],
zoom: 12,
localIdeographFontFamily: "'Noto Sans', 'Noto Sans CJK SC', sans-serif"
});


Vertical layout for CJK text on line labels

When designing labels for roads or other line-based features, you can display your text vertically along the line’s path.


Image for post

Sign up to get started building your own maps with CJK features.

Heading 1

Heading 2

Heading 3

Heading 4

Heading 5
Heading 6

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.

Block quote

Ordered list

  1. Item 1
  2. Item 2
  3. Item 3

Unordered list

  • Item A
  • Item B
  • Item C

Text link

Bold text

Emphasis

Superscript

Subscript

No items found.
No items found.