Embedded/Editable Fonts in SVG/PDF output #535

artemp opened this Issue Oct 11, 2011 · 3 comments


None yet

3 participants

Mapnik member

Mapnik currently supports SVG/PDF/PS output through the Cairo rendering backend.

Cairo's pdf surface supports embedding true fonts in the output, but the svg surface does not yet support this is included as glyphs (the characters get drawn as a bunch of vectors/lines).

Additionally, even with PDF output, text halos are not true fonts, and get vectorized like SVG.

This limitation is two part: 1) in the case of line placement mapnik passes each character separately to cairo, and 2) SVG output in Cairo is limited to glyphs: https://bugs.freedesktop.org/show_bug.cgi?id=38516. Frequently SVG and PDF are export from the OSM Export tab with the intention of later editing in Inkscape or Illustrator - to target paper/printed maps. Text labels that are true fonts, and can be selected as groups (rather than individual characters), is necessary to make further tweaking possible.

This ticket is meant to flag and explain this issue. Two solutions are possible:

1) Patch the svg surface of Cairo (potential short term option):


2) Write a native SVG renderer for Mapnik (longer term plan, will also address layering, grouping, and pattern support issues)


this does not prevent text being included as <text>, but not rendered as such, which impacts discoverability.

Mapnik member

tracked at #1669

@springmeyer springmeyer closed this Sep 6, 2014
Mapnik member

er more at #2229

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