jps services
  • Home Page
  • GIS Training Courses
    • QGIS Training Courses
    • ArcGIS Training Courses
    • MapInfo Pro Training Courses >
      • MapBasic Training Course
  • About
  • Blog

Modifying labels with QGIS 3

4/3/2019

0 Comments

 
If you have used previous versions of QGIS you may have noticed that most of the icons on the abc labelling feature were greyed out. In these earlier versions a number of steps had to be taken to enable a layer to access abc labelling features such as move, rotate and hide. For instance, fields had to be added to the layer’s attribute table for x and y coordinates for the move feature to work. Similarly a rotate field was needed for the rotation functionality. To hide labels required yet another field. Again these fields also had to be in the correct format. . Having created these fields correctly there were several more steps required to make the labelling function work. Each field had to be connected to the labels property function and then finally, if editing was enabled, the various features of the abc labelling application would become activated. Because of the amount of work involved, in getting these features to work for each individual layer, this functionality was mainly used by geographers who needed to place, move, rotate and hide layers where the standard features were insufficient. If you have previously used software such as MapInfo Pro you would have been surprised that manipulating labels required so many additional options. In MapInfo you can click on a label and move or rotate it without any of the previous steps mentioned. Once a label is moved in this way in MapInfo it is referred to as being personalised.    
With the advent of QGIS 3 the labelling functionality, which was previously only within proprietary software, is now available to open source geographers.   
Here, I have opened a project in QGIS 3 containing layers from the Alaska data set which is available for download with the latest versions of QGIS. As you can see I have moved the Label Toolbar to the map section on this occasion for clarity purposes. Normally it would be positioned on the top menu.
Picture
In this screen shot of the Label Toolbar only one of the icons is currently enabled. In earlier versions of QGIS, as previously discussed, most of these icons would stay greyed out without a lot of extra work being involved. However, if we now click on the regions layer in the Layers panel all of the icons will be enabled as shown in the next screen shot.
Picture
Clicking on the abc icon brings up the Layer Styling dialogue panel. As we have selected a layer with labelling enabled we have a number of options available.   
Picture
If we switch to another layer such as airports we no longer have any features enabled as shown in the next screen shot. You can do this either by selecting airports from the drop down section of Layer Styling dialogue panel or by switching from the regions to the airports layer in the Layers panel.
Picture
To create labels on a layer first you need to select the Show labels for this layer option from the drop down list as shown in the next screen shot. Then select an attribute from the layer’s attribute table to label the map with.
Picture
 On the Label Toolbar there are six buttons for modifying labels. Starting from the left is the Highlight Pinned Labels function which will show those labels which have been modified in some way. The cursor appears as a cross on the map when the Label Toolbar is activated.
Picture
Similarly the Pin/Unpin Labels function will enable labels to be modified as well as reverted to their previous state.
Picture
If you want to hide a label first click on the Show/Hide Labels function as shown in the next screen shot.  
Picture
 Placing the cursor over a label as in the next screen shot. The cursor is represented by a cross.
Picture
 Pressing the Shift key together with a mouse click will hide the label as shown in the next screen shot.
Picture
To hide several layers follow the above process but create a rectangle around the labels you wish to hide. Similarly, to show labels either click or create a rectangle around the area where the labels are hidden.

The Move Label and Diagram icon enables labels to be moved as necessary. In the next screen shot I have clicked on the Northwest Arctic label and moved it to the left.  
Picture
 Once in the desired position letting go of the mouse button will place the label in the new position.
Picture
Enabling the Rotate Label and clicking and holding down the mouse whilst rotating as desired will reposition the label.
Picture
​ Here we have clicked on label and rotated it 24 degrees.
Picture
 Once the mouse is released the label will stay in its new position as shown in the next screen shot.
Picture
The Change label option allows you to modify the look of individual labels. Click on a label and the Label Properties dialogue box for the label will appear as shown in the next screen shot.
Picture
 As you can see there are numerous options for personalising specific labels with this dialogue box. This option enables a label to have a variety of changes simultaneously rather than using the individual options to move, rotate or hide.

As mentioned earlier the improvements to the labelling functions in QGIS 3 makes modifying labels a much easier task than with earlier versions of QGIS.
0 Comments

Your comment will be posted after it is approved.


Leave a Reply.

    Author

    Joe Short BSc has been involved with various mapping solutions for over twenty years.  If you are considering implementing a GIS  or have ArcGIS Pro, MapInfo Pro or QGIS training requirements, jps services would be happy to be of assistance to your organisation. 

    Archives

    April 2020
    March 2020
    October 2019
    September 2019
    August 2019
    July 2019
    March 2019
    November 2018
    October 2018
    August 2018
    July 2018
    November 2017
    October 2017
    September 2017
    July 2017
    February 2017
    January 2017
    December 2016
    November 2016
    October 2016
    May 2016
    February 2016
    September 2015
    August 2015
    April 2015
    February 2015
    November 2014
    October 2014
    July 2014
    June 2014
    May 2014
    March 2014
    February 2014
    December 2013
    November 2013
    October 2013
    September 2013
    August 2013
    June 2013
    May 2013
    April 2013
    February 2013
    December 2012
    October 2012
    September 2012
    August 2012
    July 2012

    Categories

    All
    Arc Gis
    Arcview
    Autodesk
    Cad
    Gis Training
    Local Government
    Mapbasic
    Mapinfo
    Quantum Gis
    Relational Databases
    Saga Gis

    RSS Feed