Skip to content

Files

Latest commit

Feb 21, 2017
201a186 · Feb 21, 2017

History

History
27 lines (15 loc) · 1.39 KB

placement-grid.md

File metadata and controls

27 lines (15 loc) · 1.39 KB

Placement grid and alternating-grid

Allows placing repeated labels on area of a polygon. All possible placements create grid of points. Only placements within given polygon are rendered.

alternating-grid creates pattern similar to bricks in a wall.

Very important is order in which grid is iterated and individual placements placed. The first point is polygon's interior. Subsequent placements go around interior in a spiral. Only CollisionSymbolizer does not work this way, but rather iterates the grid in left-right top-down order.

These are basic use cases:

  • Labeling areas in given density.
  • Trying various positions around interior.
  • Adding areas into collision detector by CollisionSymbolizer.

Grid density can be controlled by grid-cell-width and grid-cell-height properties of the symbolizer.

An example

grid-on-polygon-3.xml

grid-on-polygon-3

grid-on-polygon-1-marker-alternating.xml

grid-on-polygon-1-marker-alternating