Important

La traduction est le fruit d’un effort communautaire auquel vous pouvez vous joindre. Cette page est actuellement traduite à 66.08%.

4. Le panneau explorateur

Le panneau explorateur de QGIS est un bon moyen d’explorer, chercher, inspecter, copier et charger des ressources QGIS. Seuls les ressources que QGIS sait manipuler sont disponibles dans l’explorateur.

En utilisant le panneau Explorateur, vous pouvez localiser, inspecter et ajouter une donnée, comme décrit dans la section Le panneau Explorateur. En plus, le panneau Explorateur supporte le glisser et déplacer de nombreuses ressources QGIS, telles que les fichiers projet, les scripts Python, les scripts de traitement et les modèles de traitement.

Les scripts Python, les scripts de traitement et les modèles de traitement peuvent également être ouverts pour l’édition dans un éditeur extermine et le modeleur graphique.

You can drag and drop layers from the Layers panel to the Browser panel, for instance into a GeoPackage or a PostgreSQL database.

../../../_images/browser_panel1.png

Fig. 4.1 Le panneau explorateur

Le panneau explorateur (Fig. 4.1) est organisé selon une hiérarchie extensible avec un niveau supérieur qui organise les ressources disponibles pour l’explorateur. Les nœuds en entrée sont développés en cliquant sur browserExpand à gauche du nom de l’entrée. Une branche se plie en cliquant sur browserCollapse. Le bouton collapseTree Tout replier plie tout les entrées du niveau supérieur.

Dans Préférences ► Personnalisation de l’interface il est possible de désactiver des ressources. Si, par exemple, vous ne souhaitez pas voir les scripts Python dans l’explorateur, vous pouvez décocher l’entrée Browser ► py et, si vous voulez retirer votre répertoire utilisateur de l’explorateur, vous pouvez décocher l’entrée Browser ► special:Home.

Un filtre (filterMap Filtrer l’explorateur) peut être utilisé pour effectuer une recherche sur les éléments visibles (les entrées fichier et les entrées de nœud dans la hiérarchie). En utilisant les options Options du menu déroulement, vous pouvez

  • Basculer vers une recherche Sensible à la casse

  • Mettre la syntaxe du filtre sur

    • Normal

    • Joker(s)

    • Expression régulière

L outil des propriétés affichant des informations utiles sur certaines entrées / ressources, peut être activé / désactivé à l’aide du metadata Activer/désactiver le bouton des propriétés. Quand il est activé, cela ouvre en bas du panneau d’exploration ce que l’on peut voir ici Fig. 4.2.

../../../_images/browser_p_properties_w.png

Fig. 4.2 L’outil propriétés

Un deuxième panneau explorateur peut être ouvert en activant le panneau Explorateur(2) dans Vue ► Panneaux. Avoir deux panneaux d’exploration peut être utile pour copier des couches entre deux ressources localisées dans différentes branches de la hiérarchie de l’explorateur.

4.1. Ressources qui peuvent être ouvertes / lancées depuis l’explorateur.

Beaucoup peuvent être utilisées dans le panneau explorateur

  • Ajouter des couches vecteur, raster ou maillées dans votre carte en double cliquant, glissant dans le canevas de la carte ou en cliquant sur le bouton addLayer Ajouter les couches sélectionnées (après avoir sélectionné les couches).

  • Lancer les scripts Python (incluant les traitements algorithmiques) en double cliquant ou glissant dans le canevas de la carte.

  • Lancer les modèles en double cliquant ou glissant dans le canevas de la carte

  • Extraire les symboles… des fichiers du projet QGIS en utilisant le menu contextuel

  • Ouvrir des fichiers avec leur application par défaut (Ouvrir <file type> avec une application externe… dans le menu contextuel). Exemples : fichiers HTML, classeurs, images, PDF, fichiers texte…

  • Copier les entrées

  • Rename and delete (multiple) layers (context menu: Manage ►)

  • Open a file explorer window and directly select the file Show in Files

Les actions spécifiques aux ressources sont répertoriées pour les différents groupes de ressources triés sous les entrées de premier niveau énumérées ci-dessous.

4.2. Entrées de haut niveau du panneau navigateur

4.2.1. Marque-pages

Les emplacements des systèmes de fichier souvent utilisés peuvent être marqués comme marque-pages. Ceux que vous avez marqués apparaîtront ici.

En plus des opérations décrites sous Accueil, le menu contextuel vous permet de Renommer le marque-page… et Supprimer le marque-page.

4.2.2. Signets spatiaux

This is where you will find your spatial bookmarks, divided into Project Bookmarks and User Bookmarks.

Tableau 4.1 available actions for spatial bookmarks

Niveau

Contextual menu

Spatial Bookmarks

New Spatial Bookmark…

Show the Spatial Bookmark Manager

Import Spatial Bookmarks…

Export Spatial Bookmarks…

Bookmark group

(Project Bookmarks and User Bookmarks)

New Spatial Bookmark…

Import Spatial Bookmarks…

Export Spatial Bookmarks…

Individual bookmark

Zoom to Bookmark

Edit Spatial Bookmark…

Delete Spatial Bookmark

4.2.3. Project Home

Available once the project file has been saved, the Project home entry is a folder containing data and other contents (scripts, models, text, …) that may be used within the current project. Displayed in the Browser panel, it allows you to quickly access data and other files of the project.

It defaults to the project file folder but can be changed through the Project ► Properties… ► General ► Project home option, or by right-clicking on the Project Home item of the Browser panel and selecting Set project home…. Customizing that folder is especially useful in contexts where QGIS projects are not stored in the root folder of an organisational “project”, along with datasets.

4.2.4. Disques et système de fichiers

The next items of the Browser panel depend on the OS in use and concern the top level entries of its file system.

Il s’agit essentiellement de :

  • The Home folder, pointing to the current user home folder

  • on Unix-based machines, the root / folder

  • the connected drives, either local or network. Depending on the OS, they are directly listed (eg, C:\, D:\) or through the /Volumes entry.

From the contextual menu of each of these folders or drives, you can:

  • rafraîchir le contenu

  • créer un Nouveau ► sous-item qui serait un Répertoire, ou un jeu de données au format GeoPackage ou ESRI Shapefile

  • cacher le répertoire (masquer depuis le navigateur)

  • Set color: customize the folder icon color, aiding in rapid browser navigation of complex folder structures

  • enable Scanning:

    • checkbox Monitor for changes: allows to manually control whether a particular directory should be monitored and automatically updated. This setting applies to the selected directory and all subdirectories. This means that you can manually opt-in to monitoring of network drives if you know there’s no issue, or manually opt-out of monitoring of large directories which you don’t want monitored for other reasons. By default, remote or network drives are not automatically monitored.

    • unchecked Fast scan this directory

  • open the directory in your file manager (Open Directory…)

  • open the directory in a terminal window (Open in Terminal…)

  • inspect the Properties… or the parent Directory Properties…

4.2.5. Data type

Tableau 4.2 Available actions for plain layer files

Level and Context menu

Types of layers

Ajouter une couche raster Raster

(Reference)

addOgrLayer Vector

(Reference)

addPointCloudLayer Point clouds

(Reference)

addMeshLayer Mesh

(Reference)

File

Delete File <dataset name>

checkbox

checkbox

Afficher dans les fichiers

checkbox

checkbox

checkbox

checkbox

Manage

checkbox

checkbox

checkbox

checkbox

File Properties…

checkbox

checkbox

checkbox

checkbox

Open <file type> Externally…

checkbox

Layer

Ajouter une couche au projet

checkbox

checkbox

checkbox

checkbox

Export Layer

checkbox

checkbox

Layer Properties…

checkbox

checkbox

checkbox

checkbox

Open with Data Source Manager…

checkbox

checkbox

Execute SQL…

checkbox

4.2.6. Database entries

Selon votre système d’exploitation et les pilotes installés, vous pourriez avoir accès à d’autres types de base de données dans QGIS. La liste ci-après indique les entrées du menu contextuel à chacun des niveaux de l’arborescence de la base de données

Tableau 4.3 Available actions for database entries

Level and Context menu

Type de base de données

geoPackage

GeoPackage ([1])

spatialite

SpatiaLite

postgis

PostgreSQL

hana

SAP HANA

mssql

MS SQL Server

oracle

Oracle

Top menu

Create a New Connection… to an existing database

checkbox

checkbox

checkbox

checkbox

checkbox

checkbox

Créer base de données

checkbox

checkbox

Create Database and Layer…

checkbox

Save Connections… details to a file

checkbox

checkbox

checkbox

Charger des connexions…

checkbox

checkbox

checkbox

Connection / Database

Rafraîchir une connexion

checkbox

checkbox

checkbox

checkbox

Edit Connection… settings

checkbox

checkbox

checkbox

checkbox

Duplicate Connection

checkbox

checkbox

checkbox

checkbox

Remove Connection…

checkbox

checkbox

checkbox

checkbox

checkbox

checkbox

Import Vector Layer…

checkbox

checkbox

checkbox

checkbox

checkbox

New Field Domain ► New Range Domain

checkbox

New Field Domain ► New Coded Values Domain

checkbox

New Field Domain ► New Glob Domain

checkbox

Supprimer <database_name>

checkbox

checkbox

Compact Database (VACUUM)

checkbox

Créer un Nouveau Schéma…

checkbox

checkbox

checkbox

Créer une Nouvelle Table…

checkbox

checkbox

checkbox

checkbox

Exécuter SQL…

checkbox

checkbox

checkbox

checkbox

Schema

Rafraîchir un schéma

checkbox

checkbox

checkbox

Opérations de schéma ► Renommer un schéma…

checkbox

checkbox

checkbox

Opérations de schéma ► Supprimer un schéma…

checkbox

checkbox

checkbox

Créer une Nouvelle Table…

checkbox

checkbox

Exécuter SQL…

checkbox

checkbox

Table / Layer

Opérations de table ► Renommer une table…

checkbox

checkbox

checkbox

Opérations de table ► Vider une table…

checkbox

checkbox

Exécuter SQL…

checkbox

checkbox

checkbox

Exporter la couche ► Vers fichier…

checkbox

checkbox

checkbox

checkbox

checkbox

Gérer ► Renommer la couche <layer_name>…

checkbox

checkbox

checkbox

Gérer ► Supprimer la couche <layer_name>…

checkbox

checkbox

checkbox

checkbox

checkbox

Gérer ► Supprimer les couches sélectionnées

checkbox

checkbox

checkbox

checkbox

checkbox

Gérer ► Ajouter la couche au projet

checkbox

checkbox

checkbox

checkbox

checkbox

Gérer ► Ajouter les couches sélectionnées au projet

checkbox

checkbox

checkbox

checkbox

checkbox

Manage ► Move to Another Schema

checkbox

checkbox

Ouvrir la fenêtre Propriétés de la couche…

checkbox

checkbox

checkbox

checkbox

checkbox

Ouvrir la fenêtre Propriétés du fichier…

checkbox

Ouvrir avec le Gestionnaire de source de données

checkbox

checkbox

Fields

Ajouter un nouveau champ…

checkbox

checkbox

checkbox

checkbox

Field

Définir le domaine du champ

checkbox

Rename Field ([2])

checkbox

checkbox

checkbox

Définir un alias…

checkbox

Définir un commentaire…

checkbox

checkbox

Supprimer champ…

checkbox

checkbox

checkbox

checkbox

Note

When loading vector layers into QGIS, fields with sourceFields Field Domains (such as those defined in a GeoPackage or ESRI File Geodatabase) are automatically detected. These domains are database-level constraints, meaning they are enforced by the database itself and apply across different applications, not just QGIS.

4.2.6.1. Importing vector layers into databases using Browser panel

QGIS allows you to import vector layers directly into a database from the Browser panel. This provides a simple way to transfer datasets into supported database formats without using dbManager DB Manager (see Extension DB Manager).

You can start the import in two ways:

  • Drag and drop a single vector layer from the Browser panel or from the Project into a database connection or schema item.

  • Right-click on a database connection or schema item and choose Import Vector Layer… from the context menu.

Note

When multiple layers are dragged into a database, they are imported immediately without further options. All imports run in the background, so the QGIS interface remains responsive during the process.

../../../_images/importvector_dialog.png

Fig. 4.3 Import Vector Layer dialog

To add a layer using Import Vector Layer… follow these steps:

  1. Add Source layer: the layer to import, chosen from the current QGIS project. To import only selected features of the source layer use the checkbox Selected features only option.

  2. Set the Table name: the name of the destination table in the database. By default, it is taken from the source layer name but can be modified. You can also use the checkbox Replace destination table (if exists) to overwrite an existing table.

  3. Define the Output CRS: the coordinate reference system of the destination table. By default, it is the CRS of the source layer, but it can be changed using the CRS selector.

  4. Configure the Attributes:

    • Source expression: expression used to populate the field. By default, this corresponds to the original source field.

    • Name: name of the field in the destination table.

    • Type: field data type (integer, text, real, etc.).

    • Length and Precision: length and precision of the field, where applicable.

    • Constraints: rules to enforce on the field values (e.g. NOT NULL, UNIQUE, DEFAULT). Support depends on the destination database.

    • Alias: an alternate display name for the field.

    • Comment: a description or note attached to the field.

    You can use buttons on the right side to:

    • newAttribute Add new field to add a new field to the destination table.

    • deleteAttribute Delete selected field to remove a field from the destination table.

    • arrowUp Move selected field up or arrowDown Move selected field down to reorder fields.

    • clearText Reset all fields to clear all fields and start from scratch.

    • settings Convert All Fields To Lowercase or settings Convert All Fields To Uppercase, to change the case of all field names.

  5. Optionally, apply a spatial filter with Filter by Extent. This restricts the import to features within a defined bounding box.

  6. Optionally, apply an attribute filter with Feature filter. This allows you to use an expression to select which features are imported.

4.2.7. Tuiles et services web

Tableau 4.4 Available actions for web services (1)

Level and Context menu

Type de services

wms

WMS / WMTS

(Référence)

xyz

XYZ Tiles

(Référence)

wcs

WCS

(Référence)

wfs

WFS / OGC API - Features

(Référence)

afs

ArcGIS REST Servers

(Référence)

Top menu

Créer une Nouvelle connexion…

checkbox

checkbox

checkbox

checkbox

checkbox

Save Connections… details to a file

checkbox

checkbox

checkbox

checkbox

checkbox

Charger des connexions…

checkbox

checkbox

checkbox

checkbox

checkbox

Connection

Rafraîchir la connexion

checkbox

checkbox

checkbox

checkbox

checkbox

Edit Connection… settings

checkbox

checkbox

checkbox

checkbox

checkbox

Duplicate Connection

checkbox

checkbox

checkbox

checkbox

checkbox

Remove Connection…

checkbox

checkbox

checkbox

checkbox

checkbox

Voir les infos du service dans un navigateur web

checkbox

Table / Layer

Exporter la couche ► Vers fichier…

checkbox

checkbox

checkbox

checkbox

checkbox

Ajouter une couche au projet

checkbox

checkbox

checkbox

checkbox

checkbox

Add Filtered Layer to Project…

checkbox

Ouvrir la fenêtre Propriétés de la couche…

checkbox

checkbox

checkbox

checkbox

checkbox

Voir les infos du service dans un navigateur web

checkbox

Tableau 4.5 Available actions for web services (2)

Level and Context menu

Type de services

vectorTileLayer

Vector Tiles

(Référence)

tiledSceneLayer

Scene

(Référence)

cloud

Cloud

(Référence)

sensor

SensorThings

(Référence)

stac

STAC

(Reference)

Top menu

Créer une Nouvelle connexion…

checkbox

checkbox

checkbox

checkbox

Créer une Nouvelle connexion générique…

checkbox

Créer une Nouvelle connexion au service de tuile vectorielle ArcGIS…

checkbox

Save Connections… details to a file

checkbox

checkbox

checkbox

checkbox

checkbox

Charger des connexions…

checkbox

checkbox

checkbox

checkbox

checkbox

Connection

Edit Connection… settings

checkbox

checkbox

checkbox

checkbox

checkbox

Duplicate Connection

checkbox

checkbox

checkbox

checkbox

Delete Connection…

checkbox

checkbox

checkbox

checkbox

checkbox

Refresh

checkbox

Details…

checkbox

Table / Layer

Exporter la couche ► Vers fichier…

checkbox

Ajouter une couche au projet

checkbox

checkbox

checkbox

Ouvrir la fenêtre Propriétés de la couche…

checkbox

checkbox

checkbox

Refresh

checkbox

Download assets…

checkbox

Details…

checkbox

4.2.8. Project and supported file types

Tableau 4.6 Available actions for various supported files :class: longtable

File type

Menu contextuel

QGIS Project file (.qgz, .qgs)

Open Project

Extract Symbols… (opens Style Manager to export symbols to XML, add to default style, or export as PNG/SVG)

File Properties…

QGIS Layer Definition (.qlr)

Exporter la couche ► Vers fichier…

Add Layer to Project

Layer Properties…

Processing Model (.model3)

Run Model…

Edit Model…

Print Composer Template (.qpt)

New Layout from Template

Python script (.py)

Run Script…

Open in External Editor