UNPKG

carto

Version:

Mapnik Stylesheet Compiler

663 lines (591 loc) 118 kB
<!DOCTYPE html> <!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]--> <!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]--> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>2.2.0 &mdash; carto documentation</title> <link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" /> <link rel="index" title="Index" href="../../genindex.html"/> <link rel="search" title="Search" href="../../search.html"/> <link rel="top" title="carto documentation" href="../../index.html"/> <script src="../../_static/js/modernizr.min.js"></script> </head> <body class="wy-body-for-nav" role="document"> <div class="wy-grid-for-nav"> <nav data-toggle="wy-nav-shift" class="wy-nav-side"> <div class="wy-side-scroll"> <div class="wy-side-nav-search"> <a href="../../index.html" class="icon icon-home"> carto </a> <div role="search"> <form id="rtd-search-form" class="wy-form" action="../../search.html" method="get"> <input type="text" name="q" placeholder="Search docs" /> <input type="hidden" name="check_keywords" value="yes" /> <input type="hidden" name="area" value="default" /> </form> </div> </div> <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation"> <p class="caption"><span class="caption-text">Contents:</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../../installation_usage.html">Installation &amp; Usage</a></li> <li class="toctree-l1"><a class="reference internal" href="../../language_elements.html">Language Elements</a></li> <li class="toctree-l1"><a class="reference internal" href="../../styling_concepts.html">Styling Concepts</a></li> <li class="toctree-l1"><a class="reference internal" href="../../mapnik_api.html">Mapnik API documentation</a></li> </ul> </div> </div> </nav> <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"> <nav class="wy-nav-top" role="navigation" aria-label="top navigation"> <i data-toggle="wy-nav-top" class="fa fa-bars"></i> <a href="../../index.html">carto</a> </nav> <div class="wy-nav-content"> <div class="rst-content"> <div role="navigation" aria-label="breadcrumbs navigation"> <ul class="wy-breadcrumbs"> <li><a href="../../index.html">Docs</a> &raquo;</li> <li>2.2.0</li> <li class="wy-breadcrumbs-aside"> <a href="../../_sources/api/mapnik/2.2.0.rst.txt" rel="nofollow"> View page source</a> </li> </ul> <hr/> </div> <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article"> <div itemprop="articleBody"> <div class="section" id="id1"> <h1>2.2.0<a class="headerlink" href="#id1" title="Permalink to this headline">¶</a></h1> <div class="section" id="all-elements"> <h2>All elements<a class="headerlink" href="#all-elements" title="Permalink to this headline">¶</a></h2> <div class="section" id="image-filters"> <h3>image-filters<a class="headerlink" href="#image-filters" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">functions</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">agg-stack-blur</span></code> <code class="docutils literal"><span class="pre">emboss</span></code> <code class="docutils literal"><span class="pre">blur</span></code> <code class="docutils literal"><span class="pre">gray</span></code> <code class="docutils literal"><span class="pre">sobel</span></code> <code class="docutils literal"><span class="pre">edge-detect</span></code> <code class="docutils literal"><span class="pre">x-gradient</span></code> <code class="docutils literal"><span class="pre">y-gradient</span></code> <code class="docutils literal"><span class="pre">invert</span></code> <code class="docutils literal"><span class="pre">sharpen</span></code> <code class="docutils literal"><span class="pre">colorize-alpha</span></code></p> <p>Default Value: none <em>(no filters)</em></p> <p>A list of image filters that will be applied to the active rendering canvas for a given style. The presence of one more more <code class="docutils literal"><span class="pre">image-filters</span></code> will trigger a new canvas to be created before starting to render a style and then this canvas will be composited back into the main canvas after rendering all features and after all <code class="docutils literal"><span class="pre">image-filters</span></code> have been applied. See <code class="docutils literal"><span class="pre">direct-image-filters</span></code> if you want to apply a filter directly to the main canvas.</p> </div> <hr class="docutils" /> <div class="section" id="direct-image-filters"> <h3>direct-image-filters<a class="headerlink" href="#direct-image-filters" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">functions</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">agg-stack-blur</span></code> <code class="docutils literal"><span class="pre">emboss</span></code> <code class="docutils literal"><span class="pre">blur</span></code> <code class="docutils literal"><span class="pre">gray</span></code> <code class="docutils literal"><span class="pre">sobel</span></code> <code class="docutils literal"><span class="pre">edge-detect</span></code> <code class="docutils literal"><span class="pre">x-gradient</span></code> <code class="docutils literal"><span class="pre">y-gradient</span></code> <code class="docutils literal"><span class="pre">invert</span></code> <code class="docutils literal"><span class="pre">sharpen</span></code> <code class="docutils literal"><span class="pre">colorize-alpha</span></code></p> <p>Default Value: none <em>(no filters)</em></p> <p>A list of image filters to apply to the main canvas (see the <code class="docutils literal"><span class="pre">image-filters</span></code> doc for how they work on a separate canvas)</p> </div> <hr class="docutils" /> <div class="section" id="comp-op"> <h3>comp-op<a class="headerlink" href="#comp-op" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">clear</span></code> <code class="docutils literal"><span class="pre">src</span></code> <code class="docutils literal"><span class="pre">dst</span></code> <code class="docutils literal"><span class="pre">src-over</span></code> <code class="docutils literal"><span class="pre">dst-over</span></code> <code class="docutils literal"><span class="pre">src-in</span></code> <code class="docutils literal"><span class="pre">dst-in</span></code> <code class="docutils literal"><span class="pre">src-out</span></code> <code class="docutils literal"><span class="pre">dst-out</span></code> <code class="docutils literal"><span class="pre">src-atop</span></code> <code class="docutils literal"><span class="pre">dst-atop</span></code> <code class="docutils literal"><span class="pre">xor</span></code> <code class="docutils literal"><span class="pre">plus</span></code> <code class="docutils literal"><span class="pre">minus</span></code> <code class="docutils literal"><span class="pre">multiply</span></code> <code class="docutils literal"><span class="pre">screen</span></code> <code class="docutils literal"><span class="pre">overlay</span></code> <code class="docutils literal"><span class="pre">darken</span></code> <code class="docutils literal"><span class="pre">lighten</span></code> <code class="docutils literal"><span class="pre">color-dodge</span></code> <code class="docutils literal"><span class="pre">color-burn</span></code> <code class="docutils literal"><span class="pre">hard-light</span></code> <code class="docutils literal"><span class="pre">soft-light</span></code> <code class="docutils literal"><span class="pre">difference</span></code> <code class="docutils literal"><span class="pre">exclusion</span></code> <code class="docutils literal"><span class="pre">contrast</span></code> <code class="docutils literal"><span class="pre">invert</span></code> <code class="docutils literal"><span class="pre">invert-rgb</span></code> <code class="docutils literal"><span class="pre">grain-merge</span></code> <code class="docutils literal"><span class="pre">grain-extract</span></code> <code class="docutils literal"><span class="pre">hue</span></code> <code class="docutils literal"><span class="pre">saturation</span></code> <code class="docutils literal"><span class="pre">color</span></code> <code class="docutils literal"><span class="pre">value</span></code></p> <p>Default Value: src-over <em>(add the current layer on top of other layers)</em></p> <p>Composite operation. This defines how this layer should behave relative to layers atop or below it.</p> </div> <hr class="docutils" /> <div class="section" id="opacity"> <h3>opacity<a class="headerlink" href="#opacity" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(no separate buffer will be used and no alpha will be applied to the style after rendering)</em></p> <p>An alpha value for the style (which means an alpha applied to all features in separate buffer and then composited back to main buffer)</p> </div> </div> <hr class="docutils" /> <div class="section" id="map"> <h2>map<a class="headerlink" href="#map" title="Permalink to this headline">¶</a></h2> <div class="section" id="background-color"> <h3>background-color<a class="headerlink" href="#background-color" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">color</span></code></p> <p>Default Value: none <em>(transparent)</em></p> <p>Map Background color</p> </div> <hr class="docutils" /> <div class="section" id="background-image"> <h3>background-image<a class="headerlink" href="#background-image" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">uri</span></code></p> <p>Default Value: <em>(transparent)</em></p> <p>An image that is repeated below all features on a map as a background.</p> </div> <hr class="docutils" /> <div class="section" id="srs"> <h3>srs<a class="headerlink" href="#srs" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">string</span></code></p> <p>Default Value: +proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs <em>(The proj4 literal of EPSG:4326 is assumed to be the Map&#8217;s spatial reference and all data from layers within this map will be plotted using this coordinate system. If any layers do not declare an srs value then they will be assumed to be in the same srs as the Map and not transformations will be needed to plot them in the Map&#8217;s coordinate space)</em></p> <p>Map spatial reference (proj4 string)</p> </div> <hr class="docutils" /> <div class="section" id="buffer-size"> <h3>buffer-size<a class="headerlink" href="#buffer-size" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0 <em>(No buffer will be used)</em></p> <p>Extra tolerance around the map (in pixels) used to ensure labels crossing tile boundaries are equally rendered in each tile (e.g. cut in each tile). Not intended to be used in combination with &#8220;avoid-edges&#8221;.</p> </div> <hr class="docutils" /> <div class="section" id="base"> <h3>base<a class="headerlink" href="#base" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">string</span></code></p> <p>Default Value: <em>(This base path defaults to an empty string meaning that any relative paths to files referenced in styles or layers will be interpreted relative to the application process.)</em></p> <p>Any relative paths used to reference files will be understood as relative to this directory path if the map is loaded from an in memory object rather than from the filesystem. If the map is loaded from the filesystem and this option is not provided it will be set to the directory of the stylesheet.</p> </div> <hr class="docutils" /> <div class="section" id="font-directory"> <h3>font-directory<a class="headerlink" href="#font-directory" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">uri</span></code></p> <p>Default Value: none <em>(No map-specific fonts will be registered)</em></p> <p>Path to a directory which holds fonts which should be registered when the Map is loaded (in addition to any fonts that may be automatically registered).</p> </div> </div> <hr class="docutils" /> <div class="section" id="polygon"> <h2>polygon<a class="headerlink" href="#polygon" title="Permalink to this headline">¶</a></h2> <div class="section" id="polygon-fill"> <h3>polygon-fill<a class="headerlink" href="#polygon-fill" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">color</span></code></p> <p>Default Value: rgba(128,128,128,1) <em>(gray and fully opaque (alpha = 1), same as rgb(128,128,128))</em></p> <p>Fill color to assign to a polygon</p> </div> <hr class="docutils" /> <div class="section" id="polygon-opacity"> <h3>polygon-opacity<a class="headerlink" href="#polygon-opacity" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(opaque)</em></p> <p>The opacity of the polygon</p> </div> <hr class="docutils" /> <div class="section" id="polygon-gamma"> <h3>polygon-gamma<a class="headerlink" href="#polygon-gamma" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(fully antialiased)</em> Range: 0-1 Level of antialiasing of polygon edges</p> </div> <hr class="docutils" /> <div class="section" id="polygon-gamma-method"> <h3>polygon-gamma-method<a class="headerlink" href="#polygon-gamma-method" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">power</span></code> <code class="docutils literal"><span class="pre">linear</span></code> <code class="docutils literal"><span class="pre">none</span></code> <code class="docutils literal"><span class="pre">threshold</span></code> <code class="docutils literal"><span class="pre">multiply</span></code></p> <p>Default Value: power <em>(pow(x,gamma) is used to calculate pixel gamma, which produces slightly smoother line and polygon antialiasing than the &#8216;linear&#8217; method, while other methods are usually only used to disable AA)</em></p> <p>An Antigrain Geometry specific rendering hint to control the quality of antialiasing. Under the hood in Mapnik this method is used in combination with the &#8216;gamma&#8217; value (which defaults to 1). The methods are in the AGG source at <a class="reference external" href="https://github.com/mapnik/mapnik/blob/master/deps/agg/include/agg_gamma_functions.h">https://github.com/mapnik/mapnik/blob/master/deps/agg/include/agg_gamma_functions.h</a></p> </div> <hr class="docutils" /> <div class="section" id="polygon-clip"> <h3>polygon-clip<a class="headerlink" href="#polygon-clip" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">boolean</span></code></p> <p>Default Value: true <em>(geometry will be clipped to map bounds before rendering)</em></p> <p>geometries are clipped to map bounds by default for best rendering performance. In some cases users may wish to disable this to avoid rendering artifacts.</p> </div> <hr class="docutils" /> <div class="section" id="polygon-simplify"> <h3>polygon-simplify<a class="headerlink" href="#polygon-simplify" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0 <em>(geometry will not be simplified)</em></p> <p>geometries are simplified by the given tolerance</p> </div> <hr class="docutils" /> <div class="section" id="polygon-simplify-algorithm"> <h3>polygon-simplify-algorithm<a class="headerlink" href="#polygon-simplify-algorithm" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">radial-distance</span></code> <code class="docutils literal"><span class="pre">zhao-saalfeld</span></code> <code class="docutils literal"><span class="pre">visvalingam-whyatt</span></code></p> <p>Default Value: radial-distance <em>(geometry will not be simplified using the radial distance algorithm)</em></p> <p>geometries are simplified by the given algorithm</p> </div> <hr class="docutils" /> <div class="section" id="polygon-smooth"> <h3>polygon-smooth<a class="headerlink" href="#polygon-smooth" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0 <em>(no smoothing)</em> Range: 0-1 Smooths out geometry angles. 0 is no smoothing, 1 is fully smoothed. Values greater than 1 will produce wild, looping geometries.</p> </div> <hr class="docutils" /> <div class="section" id="polygon-geometry-transform"> <h3>polygon-geometry-transform<a class="headerlink" href="#polygon-geometry-transform" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">functions</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">matrix</span></code> <code class="docutils literal"><span class="pre">translate</span></code> <code class="docutils literal"><span class="pre">scale</span></code> <code class="docutils literal"><span class="pre">rotate</span></code> <code class="docutils literal"><span class="pre">skewX</span></code> <code class="docutils literal"><span class="pre">skewY</span></code></p> <p>Default Value: none <em>(geometry will not be transformed)</em></p> <p>Allows transformation functions to be applied to the geometry.</p> </div> <hr class="docutils" /> <div class="section" id="polygon-comp-op"> <h3>polygon-comp-op<a class="headerlink" href="#polygon-comp-op" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">clear</span></code> <code class="docutils literal"><span class="pre">src</span></code> <code class="docutils literal"><span class="pre">dst</span></code> <code class="docutils literal"><span class="pre">src-over</span></code> <code class="docutils literal"><span class="pre">dst-over</span></code> <code class="docutils literal"><span class="pre">src-in</span></code> <code class="docutils literal"><span class="pre">dst-in</span></code> <code class="docutils literal"><span class="pre">src-out</span></code> <code class="docutils literal"><span class="pre">dst-out</span></code> <code class="docutils literal"><span class="pre">src-atop</span></code> <code class="docutils literal"><span class="pre">dst-atop</span></code> <code class="docutils literal"><span class="pre">xor</span></code> <code class="docutils literal"><span class="pre">plus</span></code> <code class="docutils literal"><span class="pre">minus</span></code> <code class="docutils literal"><span class="pre">multiply</span></code> <code class="docutils literal"><span class="pre">screen</span></code> <code class="docutils literal"><span class="pre">overlay</span></code> <code class="docutils literal"><span class="pre">darken</span></code> <code class="docutils literal"><span class="pre">lighten</span></code> <code class="docutils literal"><span class="pre">color-dodge</span></code> <code class="docutils literal"><span class="pre">color-burn</span></code> <code class="docutils literal"><span class="pre">hard-light</span></code> <code class="docutils literal"><span class="pre">soft-light</span></code> <code class="docutils literal"><span class="pre">difference</span></code> <code class="docutils literal"><span class="pre">exclusion</span></code> <code class="docutils literal"><span class="pre">contrast</span></code> <code class="docutils literal"><span class="pre">invert</span></code> <code class="docutils literal"><span class="pre">invert-rgb</span></code> <code class="docutils literal"><span class="pre">grain-merge</span></code> <code class="docutils literal"><span class="pre">grain-extract</span></code> <code class="docutils literal"><span class="pre">hue</span></code> <code class="docutils literal"><span class="pre">saturation</span></code> <code class="docutils literal"><span class="pre">color</span></code> <code class="docutils literal"><span class="pre">value</span></code></p> <p>Default Value: src-over <em>(add the current symbolizer on top of other symbolizer)</em></p> <p>Composite operation. This defines how this symbolizer should behave relative to symbolizers atop or below it.</p> </div> </div> <hr class="docutils" /> <div class="section" id="line"> <h2>line<a class="headerlink" href="#line" title="Permalink to this headline">¶</a></h2> <div class="section" id="line-color"> <h3>line-color<a class="headerlink" href="#line-color" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">color</span></code></p> <p>Default Value: rgba(0,0,0,1) <em>(black and fully opaque (alpha = 1), same as rgb(0,0,0))</em></p> <p>The color of a drawn line</p> </div> <hr class="docutils" /> <div class="section" id="line-width"> <h3>line-width<a class="headerlink" href="#line-width" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1</p> <p>The width of a line in pixels</p> </div> <hr class="docutils" /> <div class="section" id="line-opacity"> <h3>line-opacity<a class="headerlink" href="#line-opacity" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(opaque)</em></p> <p>The opacity of a line</p> </div> <hr class="docutils" /> <div class="section" id="line-join"> <h3>line-join<a class="headerlink" href="#line-join" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">miter</span></code> <code class="docutils literal"><span class="pre">round</span></code> <code class="docutils literal"><span class="pre">bevel</span></code></p> <p>Default Value: miter</p> <p>The behavior of lines when joining</p> </div> <hr class="docutils" /> <div class="section" id="line-cap"> <h3>line-cap<a class="headerlink" href="#line-cap" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">butt</span></code> <code class="docutils literal"><span class="pre">round</span></code> <code class="docutils literal"><span class="pre">square</span></code></p> <p>Default Value: butt</p> <p>The display of line endings</p> </div> <hr class="docutils" /> <div class="section" id="line-gamma"> <h3>line-gamma<a class="headerlink" href="#line-gamma" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(fully antialiased)</em> Range: 0-1 Level of antialiasing of stroke line</p> </div> <hr class="docutils" /> <div class="section" id="line-gamma-method"> <h3>line-gamma-method<a class="headerlink" href="#line-gamma-method" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">power</span></code> <code class="docutils literal"><span class="pre">linear</span></code> <code class="docutils literal"><span class="pre">none</span></code> <code class="docutils literal"><span class="pre">threshold</span></code> <code class="docutils literal"><span class="pre">multiply</span></code></p> <p>Default Value: power <em>(pow(x,gamma) is used to calculate pixel gamma, which produces slightly smoother line and polygon antialiasing than the &#8216;linear&#8217; method, while other methods are usually only used to disable AA)</em></p> <p>An Antigrain Geometry specific rendering hint to control the quality of antialiasing. Under the hood in Mapnik this method is used in combination with the &#8216;gamma&#8217; value (which defaults to 1). The methods are in the AGG source at <a class="reference external" href="https://github.com/mapnik/mapnik/blob/master/deps/agg/include/agg_gamma_functions.h">https://github.com/mapnik/mapnik/blob/master/deps/agg/include/agg_gamma_functions.h</a></p> </div> <hr class="docutils" /> <div class="section" id="line-dasharray"> <h3>line-dasharray<a class="headerlink" href="#line-dasharray" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">numbers</span></code></p> <p>Default Value: none <em>(solid line)</em></p> <p>A pair of length values [a,b], where (a) is the dash length and (b) is the gap length respectively. More than two values are supported for more complex patterns.</p> </div> <hr class="docutils" /> <div class="section" id="line-dash-offset"> <h3>line-dash-offset<a class="headerlink" href="#line-dash-offset" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">numbers</span></code></p> <p>Default Value: none <em>(solid line)</em></p> <p>valid parameter but not currently used in renderers (only exists for experimental svg support in Mapnik which is not yet enabled)</p> </div> <hr class="docutils" /> <div class="section" id="line-miterlimit"> <h3>line-miterlimit<a class="headerlink" href="#line-miterlimit" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 4 <em>(Will auto-convert miters to bevel line joins when theta is less than 29 degrees as per the SVG spec: &#8216;miterLength / stroke-width = 1 / sin ( theta / 2 )&#8217;)</em></p> <p>The limit on the ratio of the miter length to the stroke-width. Used to automatically convert miter joins to bevel joins for sharp angles to avoid the miter extending beyond the thickness of the stroking path. Normally will not need to be set, but a larger value can sometimes help avoid jaggy artifacts.</p> </div> <hr class="docutils" /> <div class="section" id="line-clip"> <h3>line-clip<a class="headerlink" href="#line-clip" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">boolean</span></code></p> <p>Default Value: true <em>(geometry will be clipped to map bounds before rendering)</em></p> <p>geometries are clipped to map bounds by default for best rendering performance. In some cases users may wish to disable this to avoid rendering artifacts.</p> </div> <hr class="docutils" /> <div class="section" id="line-simplify"> <h3>line-simplify<a class="headerlink" href="#line-simplify" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0 <em>(geometry will not be simplified)</em></p> <p>geometries are simplified by the given tolerance</p> </div> <hr class="docutils" /> <div class="section" id="line-simplify-algorithm"> <h3>line-simplify-algorithm<a class="headerlink" href="#line-simplify-algorithm" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">radial-distance</span></code> <code class="docutils literal"><span class="pre">zhao-saalfeld</span></code> <code class="docutils literal"><span class="pre">visvalingam-whyatt</span></code></p> <p>Default Value: radial-distance <em>(geometry will not be simplified using the radial distance algorithm)</em></p> <p>geometries are simplified by the given algorithm</p> </div> <hr class="docutils" /> <div class="section" id="line-smooth"> <h3>line-smooth<a class="headerlink" href="#line-smooth" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0 <em>(no smoothing)</em> Range: 0-1 Smooths out geometry angles. 0 is no smoothing, 1 is fully smoothed. Values greater than 1 will produce wild, looping geometries.</p> </div> <hr class="docutils" /> <div class="section" id="line-offset"> <h3>line-offset<a class="headerlink" href="#line-offset" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0 <em>(no offset)</em></p> <p>Offsets a line a number of pixels parallel to its actual path. Positive values move the line left, negative values move it right (relative to the directionality of the line).</p> </div> <hr class="docutils" /> <div class="section" id="line-rasterizer"> <h3>line-rasterizer<a class="headerlink" href="#line-rasterizer" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">full</span></code> <code class="docutils literal"><span class="pre">fast</span></code></p> <p>Default Value: full</p> <p>Exposes an alternate AGG rendering method that sacrifices some accuracy for speed.</p> </div> <hr class="docutils" /> <div class="section" id="line-geometry-transform"> <h3>line-geometry-transform<a class="headerlink" href="#line-geometry-transform" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">functions</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">matrix</span></code> <code class="docutils literal"><span class="pre">translate</span></code> <code class="docutils literal"><span class="pre">scale</span></code> <code class="docutils literal"><span class="pre">rotate</span></code> <code class="docutils literal"><span class="pre">skewX</span></code> <code class="docutils literal"><span class="pre">skewY</span></code></p> <p>Default Value: none <em>(geometry will not be transformed)</em></p> <p>Allows transformation functions to be applied to the geometry.</p> </div> <hr class="docutils" /> <div class="section" id="line-comp-op"> <h3>line-comp-op<a class="headerlink" href="#line-comp-op" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">clear</span></code> <code class="docutils literal"><span class="pre">src</span></code> <code class="docutils literal"><span class="pre">dst</span></code> <code class="docutils literal"><span class="pre">src-over</span></code> <code class="docutils literal"><span class="pre">dst-over</span></code> <code class="docutils literal"><span class="pre">src-in</span></code> <code class="docutils literal"><span class="pre">dst-in</span></code> <code class="docutils literal"><span class="pre">src-out</span></code> <code class="docutils literal"><span class="pre">dst-out</span></code> <code class="docutils literal"><span class="pre">src-atop</span></code> <code class="docutils literal"><span class="pre">dst-atop</span></code> <code class="docutils literal"><span class="pre">xor</span></code> <code class="docutils literal"><span class="pre">plus</span></code> <code class="docutils literal"><span class="pre">minus</span></code> <code class="docutils literal"><span class="pre">multiply</span></code> <code class="docutils literal"><span class="pre">screen</span></code> <code class="docutils literal"><span class="pre">overlay</span></code> <code class="docutils literal"><span class="pre">darken</span></code> <code class="docutils literal"><span class="pre">lighten</span></code> <code class="docutils literal"><span class="pre">color-dodge</span></code> <code class="docutils literal"><span class="pre">color-burn</span></code> <code class="docutils literal"><span class="pre">hard-light</span></code> <code class="docutils literal"><span class="pre">soft-light</span></code> <code class="docutils literal"><span class="pre">difference</span></code> <code class="docutils literal"><span class="pre">exclusion</span></code> <code class="docutils literal"><span class="pre">contrast</span></code> <code class="docutils literal"><span class="pre">invert</span></code> <code class="docutils literal"><span class="pre">invert-rgb</span></code> <code class="docutils literal"><span class="pre">grain-merge</span></code> <code class="docutils literal"><span class="pre">grain-extract</span></code> <code class="docutils literal"><span class="pre">hue</span></code> <code class="docutils literal"><span class="pre">saturation</span></code> <code class="docutils literal"><span class="pre">color</span></code> <code class="docutils literal"><span class="pre">value</span></code></p> <p>Default Value: src-over <em>(add the current symbolizer on top of other symbolizer)</em></p> <p>Composite operation. This defines how this symbolizer should behave relative to symbolizers atop or below it.</p> </div> </div> <hr class="docutils" /> <div class="section" id="markers"> <h2>markers<a class="headerlink" href="#markers" title="Permalink to this headline">¶</a></h2> <div class="section" id="marker-file"> <h3>marker-file<a class="headerlink" href="#marker-file" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">uri</span></code></p> <p>Default Value: <em>(An ellipse or circle, if width equals height)</em></p> <p>An SVG file that this marker shows at each placement. If no file is given, the marker will show an ellipse.</p> </div> <hr class="docutils" /> <div class="section" id="marker-opacity"> <h3>marker-opacity<a class="headerlink" href="#marker-opacity" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(The stroke-opacity and fill-opacity will be used)</em></p> <p>The overall opacity of the marker, overrides both the opacity of the fill and the opacity of the stroke.</p> </div> <hr class="docutils" /> <div class="section" id="marker-fill-opacity"> <h3>marker-fill-opacity<a class="headerlink" href="#marker-fill-opacity" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(opaque)</em></p> <p>The fill opacity of the marker</p> </div> <hr class="docutils" /> <div class="section" id="marker-line-color"> <h3>marker-line-color<a class="headerlink" href="#marker-line-color" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">color</span></code></p> <p>Default Value: black</p> <p>The color of the stroke around a marker shape.</p> </div> <hr class="docutils" /> <div class="section" id="marker-line-width"> <h3>marker-line-width<a class="headerlink" href="#marker-line-width" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0.5</p> <p>The width of the stroke around a marker shape, in pixels. This is positioned on the boundary, so high values can cover the area itself.</p> </div> <hr class="docutils" /> <div class="section" id="marker-line-opacity"> <h3>marker-line-opacity<a class="headerlink" href="#marker-line-opacity" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 1 <em>(opaque)</em></p> <p>The opacity of a line</p> </div> <hr class="docutils" /> <div class="section" id="marker-placement"> <h3>marker-placement<a class="headerlink" href="#marker-placement" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">point</span></code> <code class="docutils literal"><span class="pre">line</span></code> <code class="docutils literal"><span class="pre">interior</span></code></p> <p>Default Value: point <em>(Place markers at the center point (centroid) of the geometry)</em></p> <p>Attempt to place markers on a point, in the center of a polygon, or if markers-placement:line, then multiple times along a line. &#8216;interior&#8217; placement can be used to ensure that points placed on polygons are forced to be inside the polygon interior</p> </div> <hr class="docutils" /> <div class="section" id="marker-multi-policy"> <h3>marker-multi-policy<a class="headerlink" href="#marker-multi-policy" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">each</span></code> <code class="docutils literal"><span class="pre">whole</span></code> <code class="docutils literal"><span class="pre">largest</span></code></p> <p>Default Value: each <em>(If a feature contains multiple geometries and the placement type is either point or interior then a marker will be rendered for each)</em></p> <p>A special setting to allow the user to control rendering behavior for &#8216;multi-geometries&#8217; (when a feature contains multiple geometries). This setting does not apply to markers placed along lines. The &#8216;each&#8217; policy is default and means all geometries will get a marker. The &#8216;whole&#8217; policy means that the aggregate centroid between all geometries will be used. The &#8216;largest&#8217; policy means that only the largest (by bounding box areas) feature will get a rendered marker (this is how text labeling behaves by default).</p> </div> <hr class="docutils" /> <div class="section" id="marker-type"> <h3>marker-type<a class="headerlink" href="#marker-type" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">arrow</span></code> <code class="docutils literal"><span class="pre">ellipse</span></code></p> <p>Default Value: ellipse</p> <p>The default marker-type. If a SVG file is not given as the marker-file parameter, the renderer provides either an arrow or an ellipse (a circle if height is equal to width)</p> </div> <hr class="docutils" /> <div class="section" id="marker-width"> <h3>marker-width<a class="headerlink" href="#marker-width" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 10</p> <p>The width of the marker, if using one of the default types.</p> </div> <hr class="docutils" /> <div class="section" id="marker-height"> <h3>marker-height<a class="headerlink" href="#marker-height" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 10</p> <p>The height of the marker, if using one of the default types.</p> </div> <hr class="docutils" /> <div class="section" id="marker-fill"> <h3>marker-fill<a class="headerlink" href="#marker-fill" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">color</span></code></p> <p>Default Value: blue</p> <p>The color of the area of the marker.</p> </div> <hr class="docutils" /> <div class="section" id="marker-allow-overlap"> <h3>marker-allow-overlap<a class="headerlink" href="#marker-allow-overlap" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">boolean</span></code></p> <p>Default Value: false <em>(Do not allow makers to overlap with each other - overlapping markers will not be shown.)</em></p> <p>Control whether overlapping markers are shown or hidden.</p> </div> <hr class="docutils" /> <div class="section" id="marker-ignore-placement"> <h3>marker-ignore-placement<a class="headerlink" href="#marker-ignore-placement" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">boolean</span></code></p> <p>Default Value: false <em>(do not store the bbox of this geometry in the collision detector cache)</em></p> <p>value to control whether the placement of the feature will prevent the placement of other features</p> </div> <hr class="docutils" /> <div class="section" id="marker-spacing"> <h3>marker-spacing<a class="headerlink" href="#marker-spacing" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 100</p> <p>Space between repeated markers in pixels. If the spacing is less than the marker size or larger than the line segment length then no marker will be placed</p> </div> <hr class="docutils" /> <div class="section" id="marker-max-error"> <h3>marker-max-error<a class="headerlink" href="#marker-max-error" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0.2</p> <p>The maximum difference between actual marker placement and the marker-spacing parameter. Setting a high value can allow the renderer to try to resolve placement conflicts with other symbolizers.</p> </div> <hr class="docutils" /> <div class="section" id="marker-transform"> <h3>marker-transform<a class="headerlink" href="#marker-transform" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">functions</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">matrix</span></code> <code class="docutils literal"><span class="pre">translate</span></code> <code class="docutils literal"><span class="pre">scale</span></code> <code class="docutils literal"><span class="pre">rotate</span></code> <code class="docutils literal"><span class="pre">skewX</span></code> <code class="docutils literal"><span class="pre">skewY</span></code></p> <p>Default Value: <em>(No transformation)</em></p> <p>SVG transformation definition</p> </div> <hr class="docutils" /> <div class="section" id="marker-clip"> <h3>marker-clip<a class="headerlink" href="#marker-clip" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">boolean</span></code></p> <p>Default Value: true <em>(geometry will be clipped to map bounds before rendering)</em></p> <p>geometries are clipped to map bounds by default for best rendering performance. In some cases users may wish to disable this to avoid rendering artifacts.</p> </div> <hr class="docutils" /> <div class="section" id="marker-smooth"> <h3>marker-smooth<a class="headerlink" href="#marker-smooth" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">float</span></code></p> <p>Default Value: 0 <em>(no smoothing)</em> Range: 0-1 Smooths out geometry angles. 0 is no smoothing, 1 is fully smoothed. Values greater than 1 will produce wild, looping geometries.</p> </div> <hr class="docutils" /> <div class="section" id="marker-geometry-transform"> <h3>marker-geometry-transform<a class="headerlink" href="#marker-geometry-transform" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">functions</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">matrix</span></code> <code class="docutils literal"><span class="pre">translate</span></code> <code class="docutils literal"><span class="pre">scale</span></code> <code class="docutils literal"><span class="pre">rotate</span></code> <code class="docutils literal"><span class="pre">skewX</span></code> <code class="docutils literal"><span class="pre">skewY</span></code></p> <p>Default Value: none <em>(geometry will not be transformed)</em></p> <p>Allows transformation functions to be applied to the geometry.</p> </div> <hr class="docutils" /> <div class="section" id="marker-comp-op"> <h3>marker-comp-op<a class="headerlink" href="#marker-comp-op" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">keyword</span></code></p> <p>Possible values: <code class="docutils literal"><span class="pre">clear</span></code> <code class="docutils literal"><span class="pre">src</span></code> <code class="docutils literal"><span class="pre">dst</span></code> <code class="docutils literal"><span class="pre">src-over</span></code> <code class="docutils literal"><span class="pre">dst-over</span></code> <code class="docutils literal"><span class="pre">src-in</span></code> <code class="docutils literal"><span class="pre">dst-in</span></code> <code class="docutils literal"><span class="pre">src-out</span></code> <code class="docutils literal"><span class="pre">dst-out</span></code> <code class="docutils literal"><span class="pre">src-atop</span></code> <code class="docutils literal"><span class="pre">dst-atop</span></code> <code class="docutils literal"><span class="pre">xor</span></code> <code class="docutils literal"><span class="pre">plus</span></code> <code class="docutils literal"><span class="pre">minus</span></code> <code class="docutils literal"><span class="pre">multiply</span></code> <code class="docutils literal"><span class="pre">screen</span></code> <code class="docutils literal"><span class="pre">overlay</span></code> <code class="docutils literal"><span class="pre">darken</span></code> <code class="docutils literal"><span class="pre">lighten</span></code> <code class="docutils literal"><span class="pre">color-dodge</span></code> <code class="docutils literal"><span class="pre">color-burn</span></code> <code class="docutils literal"><span class="pre">hard-light</span></code> <code class="docutils literal"><span class="pre">soft-light</span></code> <code class="docutils literal"><span class="pre">difference</span></code> <code class="docutils literal"><span class="pre">exclusion</span></code> <code class="docutils literal"><span class="pre">contrast</span></code> <code class="docutils literal"><span class="pre">invert</span></code> <code class="docutils literal"><span class="pre">invert-rgb</span></code> <code class="docutils literal"><span class="pre">grain-merge</span></code> <code class="docutils literal"><span class="pre">grain-extract</span></code> <code class="docutils literal"><span class="pre">hue</span></code> <code class="docutils literal"><span class="pre">saturation</span></code> <code class="docutils literal"><span class="pre">color</span></code> <code class="docutils literal"><span class="pre">value</span></code></p> <p>Default Value: src-over <em>(add the current symbolizer on top of other symbolizer)</em></p> <p>Composite operation. This defines how this symbolizer should behave relative to symbolizers atop or below it.</p> </div> </div> <hr class="docutils" /> <div class="section" id="shield"> <h2>shield<a class="headerlink" href="#shield" title="Permalink to this headline">¶</a></h2> <div class="section" id="shield-name"> <h3>shield-name<a class="headerlink" href="#shield-name" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">string</span></code></p> <p>Default Value:</p> <p>Value to use for a shield&#8221;s text label. Data columns are specified using brackets like [column_name]</p> </div> <hr class="docutils" /> <div class="section" id="shield-file"> <h3>shield-file<a class="headerlink" href="#shield-file" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">uri</span></code></p> <p>Default Value: none</p> <p>Image file to render behind the shield text</p> </div> <hr class="docutils" /> <div class="section" id="shield-face-name"> <h3>shield-face-name<a class="headerlink" href="#shield-face-name" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">string</span></code></p> <p>Default Value:</p> <p>Font name and style to use for the shield text</p> </div> <hr class="docutils" /> <div class="section" id="shield-unlock-image"> <h3>shield-unlock-image<a class="headerlink" href="#shield-unlock-image" title="Permalink to this headline">¶</a></h3> <p>Type: <code class="docutils literal"><span class="pre">boolean</span></code></p> <p>Default Value: false <em>(text alignment relative to the shield image uses the center of the image as the anchor for text positioning.)</em></p> <p>This parameter should be set to true if you are trying to position text beside rather than on top of the shield image</p> </div>