ShieldSymbolizer dx / dy moves image as well as text #1148

aengus1 opened this Issue Mar 26, 2012 · 4 comments


None yet

4 participants


I have recently upgraded my Mapnik version to 2.1.0_rc1 using the installer available at

I have found some odd behaviour regarding the shieldSymbolizer. dx and dy values appear to shift the entire shield by the specified number of pixels, rather than only the text, as specified in the docs.

Below is an example of the rule I am using:

        <ShieldSymbolizer size="10" fill="#000" dx="-1" dy="-1" placement="point" file="shield.png" minimum-distance="40" fontset-name="book-fonts" halo-radius="1">[ref]</ShieldSymbolizer>
Mapnik member

What happens if you use shield-dx and/or shield-dy?


shield-dx and shield-dy behave as expected, i.e. they also shift the image and the text.

@herm herm was assigned Apr 1, 2012

You may have to set unlock-image="true" (I believe it's incorrectly listed in the shieldsymbolizer as "unlock-imageplacements").

If "false", the symbol is placed relative to the text box center.
If "true", the symbol is placed relative to the point position

Mapnik member

Should work correctly in current master. However for a better interface was defined for new versions.

@herm herm closed this Aug 19, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment