On this page

    Working with Patterns

    Every map can use its own set of icons for displaying points of interest, highway shields, peaks, etc. In special cases, maps can also include patterns, helping users distinguish between similar polygon features. A set of icons and patterns and a file defining which icon should be used for what purpose is called a sprite.

    Patterns in MapTiler maps

    The Pattern selection dialogue can be found in the Fill properties of your polygon layer. It is best practice to add the pattern to a duplicated layer positioned on top of the original one. This way, you also keep the underlying color of the area.

    fill-pattern.png

    Patterns currently don’t support change of colors! Patterns are saved as rasters, meaning their color is encoded within them and cannot be changed in the interface.

    Patterns prepared by our team can be found in the Aquarelle, Toner, and OpenStreetMap map styles.

    aquarelle.png

    How to create patterns

    Patterns can be created in graphic software such as Inkscape or using HTML & JavaScript. The pattern shape has to be seamless, as it will repeat across your map features. We recommend using an even amount of pixels for better downscaling.

    You can also use patterns from available libraries, such as Hero Patterns, provided you follow the licensing conditions.

    How to upload custom patterns

    We recommend working with raster patterns; vector icons are not suitable for repeating shapes and might distort your graphics. You can upload patterns with the Raster icons (or mixed format) option.

    This upload option allows for either individual PNG files or a zipped format. 

    patterns-upload.png

    When you upload a new set of patterns, you automatically lose the previous one. Map Designer currently doesn’t support multiple icon sets. If you need to combine your patterns with a MapTiler icon set or patterns from the maps, please contact MapTiler Support.

    Patterns in cartography

    Patterns are repeating, often geometric shapes used across maps to enhance the readability or category distinction of polygon areas. Patterns are seamless so that they can be used for various sizes of data and different zoom levels. They are particularly useful for color-blind-friendly maps, helping users to distinguish areas not only by color but also based on texture.

    Patterns can be composed of shapes such as lines, dots, circles, squares, crosses or even symbols like trees or flowers. Hatchings are a special category of patterns that are composed of lines only.

    preview.png

    Patterns usually help to visualize landcover areas against the background. As there are many real-world features with the same color scheme association (green for forests, grass, farmland, vineyards, etc.), users can experience a hard time telling them apart. Such an example is the garden pattern in the OpenStreetMap style that helps to distinguish the garden areas from grass.

    osm-patterns.png

    Patterns can also represent different values within a category, typically for a choropleth map. Different parameters can be used for visualizing the increasing intensity of your data values:

    • thickness (for lines) or size (for points)
    • density
    • direction
    • combination of the above

    Next steps

    Continue to Using Sprites to learn what is a sprite and how to use it in your maps.

    Maps & styles basics
    Layer styling
    GL Style Specification | Sprite
    How to style a pop-art map

    Was this helpful?

    Map design guides
    Sprite patterns: working with patterns
    Sprite patterns