Graphics Reference
In-Depth Information
Adding lines and polygons
To add a LineString or a Polygon geometry, the user will draw the desired shape by click-
ing on each vertex in turn. Appropriate feedback will be displayed as the user clicks on
each vertex. For example, a LineString geometry would be displayed in the following way:
To draw the outline of a Polygon geometry, the user will once again click on each vertex in
turn. This time, however, the polygon itself will be displayed to make the resulting shape
clear, as the following image shows:
In both cases, the basic logic of clicking on each vertex and displaying appropriate feed-
back is the same.
QGIS includes a map tool named QgsMapToolCapture , which handles exactly this be-
havior: it allows the user to draw a LineString or the outline of a Polygon geometry by
Search WWH ::




Custom Search