Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Module 6.1, updated images and text. #5580

Merged
merged 13 commits into from
Jun 8, 2020
183 changes: 125 additions & 58 deletions docs/training_manual/create_vector_data/create_new_vector.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,18 @@ You'll be presented with the following dialog:
.. figure:: img/create_vector_layer.png
:align: center

* Click :guilabel:`...` for the File name field. A save dialog will appear.
* Navigate to the :kbd:`exercise_data` directory.
* Save your new layer as :kbd:`school_property.shp`.

It's important to decide which kind of dataset you want at this stage. Each
different vector layer type is "built differently" in the background, so once
you've created the layer, you can't change its type.

For the next exercise, we're going to be creating new features which describe
areas. For such features, you'll need to create a polygon dataset.

* Click on the :guilabel:`Polygon` radio button:
* For Geometry Type, select :guilabel:`Polygon` from the drop down menu:

.. figure:: img/polygon_selected.png
:align: center
Expand All @@ -49,14 +53,14 @@ The CRS of this project is WGS84, so it's already correct by default:
.. figure:: img/default_crs.png
:align: center

Next there is a collection of fields grouped under :guilabel:`New attribute`.
Next there is a collection of fields grouped under :guilabel:`New Field`.
By default, a new layer has only one attribute, the :kbd:`id` field (which you
should see in the :guilabel:`Attributes list`) below. However, in order for the
should see in the :guilabel:`Fields list`) below. However, in order for the
data you create to be useful, you actually need to say something about the
features you'll be creating in this new layer. For our current purposes, it
will be enough to add one field called :kbd:`name`.
will be enough to add one field called :kbd:`name` that will hold :kbd:`Text data` and will be limited to text length of :kbd:`80` characters.
milechin marked this conversation as resolved.
Show resolved Hide resolved

* Replicate the setup below, then click the :guilabel:`Add to attributes list`
* Replicate the setup below, then click the :guilabel:`Add to Fields List`
button:

.. figure:: img/new_attribute.png
Expand All @@ -67,9 +71,7 @@ will be enough to add one field called :kbd:`name`.
.. figure:: img/new_attribute_added.png
:align: center

* Click :guilabel:`OK`. A save dialog will appear.
* Navigate to the :kbd:`exercise_data` directory.
* Save your new layer as :kbd:`school_property.shp`.
* Click :guilabel:`OK`

The new layer should appear in your :guilabel:`Layers` panel.

Expand All @@ -92,69 +94,69 @@ or aerial photography.
For our example, you'll be using the digitizing approach. Sample raster datasets
are provided, so you'll need to import them as necessary.

* Click on the :guilabel:`Add Raster Layer` button: |addRasterLayer|

* Click on Data Source Manager button |dataSourceManager| .
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we better use this type of instructions style

Suggested change
* Click on Data Source Manager button |dataSourceManager| .
* Click on |dataSourceManager| :sup:`Data Source Manager` button.

* Select :guilabel:`Raster` on the left side.
* In the :guilabel:`Source` panel, click on the :guilabel:`...` button:
* Navigate to :kbd:`exercise_data/raster/`.
* Select the file :kbd:`3420C_2010_327_RGB_LATLNG.tif`.
* Click :guilabel:`Open`. An image will load into your map.
* Find the new image in the :guilabel:`Layers` panel.
* Click and drag it to the bottom of the list so that you can still see your
other layers.
* Find and zoom to this area:
* Click :guilabel:`Open` to close the dialogue window.

.. figure:: img/add_raster.png
:align: center

* Click :guilabel:`Add` and :guilabel:`Close`. An image will load into your map.

.. figure:: img/raster_added.png
:align: center

* If you don't see an aerial image appear, select the new layer image, right click, and click on :guilabel:`Zoom to Layer`.
milechin marked this conversation as resolved.
Show resolved Hide resolved

.. figure:: img/zoom_to_raster.png
:align: center

* Click on the |zoomIn| button, and zoom to the area highlighted in blue below:

.. figure:: img/map_area_zoom.png
:align: center

.. note:: If your :guilabel:`buildings` layer symbology is covering part or all of the
DelazJ marked this conversation as resolved.
Show resolved Hide resolved
raster layer, you can temporarily disable the layer by deselecting it in the
:guilabel:`Layers panel`. You may also wish to hide the
:guilabel:`roads` symbology if you find it distracting.

You'll be digitizing these three fields:

.. figure:: img/field_outlines.png
:align: center

Before starting to digitize, let's move the :kbd:`school_property` layer above the aerial image.

* Select :kbd:`school_property` layer in the :guilabel:`Layers` pane and drag it to the top.

.. figure:: img/move_school_layer.png
:align: center

In order to begin digitizing, you'll need to enter **edit mode**. GIS software
commonly requires this to prevent you from accidentally editing or deleting
important data. Edit mode is switched on or off individually for each layer.

To enter edit mode for the :guilabel:`school_property` layer:

* Click on the layer in the :guilabel:`Layer list` to select it. (Make very
sure that the correct layer is selected, otherwise you'll edit the wrong
layer!)
* Click on the :guilabel:`Toggle Editing` button: |edit|
* Click on the :kbd:'school_property' layer in the :guilabel:`Layer list` to select it.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

caution: there's use of ' instead of ` here. (but there's use of kbd anyways)

* Click on the :guilabel:`Toggle Editing` button: |toggleEditing|

If you can't find this button, check that the :guilabel:`Digitizing` toolbar is
enabled. There should be a check mark next to the :menuselection:`View -->
Toolbars --> Digitizing` menu entry.

As soon as you are in edit mode, you'll see the digitizing tools are now
As soon as you are in edit mode, you'll see some digitizing tools are now
milechin marked this conversation as resolved.
Show resolved Hide resolved
active:

|capturePolygon| |moveFeature| |vertexToolActiveLayer|
- |capturePolygon|: Add a new feature.
- |vertexToolActiveLayer|: move only one part of a feature.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- |vertexToolActiveLayer|: move only one part of a feature.
- |vertexToolActiveLayer|: move vertice(s) of a feature.

would be clearer imho


Four other relevant buttons are still inactive, but will become active when we
start interacting with our new data:
Other relevant buttons are still inactive, but will become active when we
start interacting with our new data.

|saveEdits| |deleteSelectedFeatures| |editCut| |editCopy|
|editPaste|
You will also notice in the :guilabel:`Layers` pane the layer :kbd:`school_layer` symbol now has the pencil icon, indicating the layer is in edit mode.
milechin marked this conversation as resolved.
Show resolved Hide resolved

From left to right on the toolbar, they are:

- :guilabel:`Save Edits`: saves changes made to the layer.
DelazJ marked this conversation as resolved.
Show resolved Hide resolved
- :guilabel:`Add Feature`: start digitizing a new feature.
- :guilabel:`Move Feature(s)`: move an entire feature around.
- :guilabel:`Vertex Tool`: move only one part of a feature.
- :guilabel:`Delete Selected`: delete the selected feature.
- :guilabel:`Cut Features`: cut the selected feature.
- :guilabel:`Copy Features`: copy the selected feature.
- :guilabel:`Paste Features`: paste a cut or copied feature back into the map.

You want to add a new feature.

* Click on the :guilabel:`Add Feature` button now to begin digitizing our school
* Click on the |capturePolygon| button to begin digitizing our school
fields.

You'll notice that your mouse cursor has become a crosshair. This allows you to
Expand All @@ -172,6 +174,10 @@ The first feature you'll be digitizing is the |schoolAreaType1|:
field.
* Place more points by clicking further along the edge, until the shape you're
drawing completely covers the field.

.. figure:: img/school_field_outline.png
:align: center

* After placing your last point, *right-click* to finish drawing the polygon.
This will finalize the feature and show you the :guilabel:`Attributes` dialog.
* Fill in the values as below:
Expand All @@ -181,25 +187,74 @@ The first feature you'll be digitizing is the |schoolAreaType1|:

* Click :guilabel:`OK` and you've created a new feature!

.. figure:: img/new_feature.png
:align: center

* In the :guilabel:`Layers` pane select the :kbd:`school_property` layer, right click, and click on :guilabel:`Open Attribute Table`.
milechin marked this conversation as resolved.
Show resolved Hide resolved

.. figure:: img/open_attribute_table.png
:align: center

In the table you will see the feature you just added. While in edit mode you can update the attributes data by double click on the cell you want to update.
milechin marked this conversation as resolved.
Show resolved Hide resolved

.. figure:: img/feature_table.png
:align: center

* Close the attribute table.
* To save the new feature we just created click on the Save Edits button: |saveEdits|
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* To save the new feature we just created click on the Save Edits button: |saveEdits|
* To save the new feature we just created, click on the |saveEdits| :sup:`Save Edits` button:


Remember, if you've made a mistake while digitizing a feature, you can always
edit it after you're done creating it. If you've made a mistake, continue
digitizing until you're done creating the feature as above. Then:

* Select the feature with the :guilabel:`Select Single Feature` tool:
* Click on |vertexToolActiveLayer| Vertex Editor tool.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* Click on |vertexToolActiveLayer| Vertex Editor tool.
* Click on |vertexToolActiveLayer| :sup:`Vertex tool`.

* Hover the mouse over a vertex you want to move and *left-click* on the vertex.
* Move the mouse to the correct location of the vertex, and *left-click*. This will move the vertext to the new location.
milechin marked this conversation as resolved.
Show resolved Hide resolved

.. figure:: img/single_feature_select.png
:align: center
.. figure:: img/select_vertex.png
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

any reason of the margin left at the top in the image?

:align: center
.. figure:: img/moved_vertext.png
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does not hurt as long as they are inline but maybe worth fixing this typo in file name ?

Suggested change
.. figure:: img/moved_vertext.png
.. figure:: img/moved_vertex.png

:align: center

The same procedure can be used to move a line segment, but you will need to hover over the midpoint of the line segment.
milechin marked this conversation as resolved.
Show resolved Hide resolved

Another way to edited the feature is by manually entering the coordinates for each vertex.
Copy link
Collaborator

@DelazJ DelazJ May 30, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about moving this procedure to a more advanced level (not sure it's some usual step)?

Suggested change
Another way to edited the feature is by manually entering the coordinates for each vertex.
Another way to edit the feature is to manually enter the coordinates for each vertex.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree, it probably belongs in an advanced level.


* Make sure the Vertex Editor tool |vertexToolActiveLayer| is still active.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* Make sure the Vertex Editor tool |vertexToolActiveLayer| is still active.
* Make sure the |vertexToolActiveLayer| :sup:`Vertex Tool` is still active.

* Move the mouse over the feature and *right-click* on it.
* A :guilabel:`Vertex Editor` pane will appear.

.. figure:: img/vertex_editor_table.png
:align: center

* Click on a row, then look at the feature the corresponding vertex circle color will change to blue.
milechin marked this conversation as resolved.
Show resolved Hide resolved
* Double *left-click* in the table on the x or y coordinate you want to edit and enter the updated value.
milechin marked this conversation as resolved.
Show resolved Hide resolved

.. figure:: img/edit_vertext_in_vertex_editor.png
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same file name "typo"

Suggested change
.. figure:: img/edit_vertext_in_vertex_editor.png
.. figure:: img/edit_vertex_in_vertex_editor.png

:align: center

If you want to undo a change, you can undo changes by pressing the Undo button |undo|.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
If you want to undo a change, you can undo changes by pressing the Undo button |undo|.
If you want to undo a change, you can undo changes by pressing the
|undo| :sup:`Undo` button or pressing :kbd:`Ctrl+Z`.


* Remember to save your changes by clicking the Save Edits button |saveEdits|.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* Remember to save your changes by clicking the Save Edits button |saveEdits|.
* Remember to save your changes by clicking the |saveEdits| :sup:`Save Edits` button.


To enable the remaining feature editing tools, one needs to select the feature.
DelazJ marked this conversation as resolved.
Show resolved Hide resolved

You can use:
* Click on the Select Rectange button |selectRectangle| in the Attributes Toolbar.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* Click on the Select Rectange button |selectRectangle| in the Attributes Toolbar.
* Click on the |selectRectangle| :sup:`Select Features` button in the Attributes Toolbar.

* Click on the feature that was just created and this will enable the remaining buttons.

* the :guilabel:`Move Feature(s)` tool to move the entire feature,
* the :guilabel:`Vertex Tool` to move only one point where you may have
miss-clicked,
* :guilabel:`Delete Selected` to get rid of the feature entirely so you can try
again, and
* the :menuselection:`Edit --> Undo` menu item or the :kbd:`Ctrl+Z` keyboard
shortcut to undo mistakes.
.. figure:: img/all_active_buttons.png
:align: center

Here is a summary of what editing action of these buttons:
milechin marked this conversation as resolved.
Show resolved Hide resolved

- |deleteSelectedFeatures|: delete the selected feature.
- |editCut| : cut the selected feature.
- |editCopy|: copy the selected feature.
- |editPaste|: paste a cut or copied feature back into the map.

* When done editing, click the Toggle Editing button |toggleEditing| to get out of edit mode.
milechin marked this conversation as resolved.
Show resolved Hide resolved


|basic| |TY|
-------------------------------------------------------------------------------

Expand All @@ -215,7 +270,7 @@ Remember that each new feature needs to have a unique :kbd:`id` value!

.. note:: You can style the fill, outline and label placement and formatting
of the :guilabel:`school_property` using techniques learnt in earlier
lessons. In our example, we will use a dashed outline of light purple color
lessons. In our example, we will use a dashed outline of light green color
with no fill.

.. _backlink-create-vector-digitize-1:
Expand All @@ -225,8 +280,10 @@ Remember that each new feature needs to have a unique :kbd:`id` value!

* Create a new line feature called :kbd:`routes.shp` with attributes :kbd:`id`
and :kbd:`type`. (Use the approach above to guide you.)
* We're going to digitize two routes which are not already marked on the roads
layer; one is a path, the other is a track.

We're going to digitize two routes which are not already marked on the roads layer; one is a path, the other is a track.
milechin marked this conversation as resolved.
Show resolved Hide resolved

* If the roads layer is not in your map, then add it from the GeoPackage file :file:`training-data.gpk` included in the :file:`exercise_data` folder of the training data you downloaded.
milechin marked this conversation as resolved.
Show resolved Hide resolved

Our path runs along the southern edge of the suburb of Railton, starting and
ending at marked roads:
Expand All @@ -250,7 +307,7 @@ You'll probably find that only the points are marked; use the
:guilabel:`Layer Properties` dialog to add styling to your routes. Feel free to
give different styles to the path and track.

Save your edits and toggle :guilabel:`Edit` mode.
Save your edits and toggle |toggleEditing| mode.

:ref:`Check your results <create-vector-digitize-1>`

Expand Down Expand Up @@ -308,3 +365,13 @@ be useful.
.. |schoolAreaType1| replace:: athletics field
.. |vertexToolActiveLayer| image:: /static/common/mActionVertexToolActiveLayer.png
:width: 1.5em
.. |toggleEditing| image:: /static/common/mActionToggleEditing.png
:width: 1.5em
.. |dataSourceManager| image:: /static/common/mActionDataSourceManager.png
:width: 1.5em
.. |zoomIn| image:: /static/common/mActionZoomIn.png
:width: 1.5em
.. |undo| image:: /static/common/mActionUndo.png
:width: 1.5em
.. |selectRectangle| image:: /static/common/mActionSelectRectangle.png
:width: 1.5em
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/training_manual/create_vector_data/img/default_crs.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/training_manual/create_vector_data/img/map_area_zoom.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/training_manual/create_vector_data/img/new_attribute.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/training_manual/create_vector_data/img/path_start_end.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/training_manual/create_vector_data/img/polygon_selected.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/training_manual/create_vector_data/img/track_start_end.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.