2.3. La fenêtre des chemins

Voyez Section 5, «  Chemins  » si vous ne savez pas ce qu’est un chemin.

Figure 15.12. La fenêtre de dialogue des « Chemins »

La fenêtre de dialogue des « Chemins »

La fenêtre des chemins sert à gérer les chemins : création, suppression, enregistrement, conversion en sélection…etc. Le terme anglais pour Chemin est « Path ».

2.3.1. Accès au dialogue

La fenêtre du Presse-papiers est une fenêtre ancrable, voyez la section Dialogues, fenêtres et onglets sur l’utilisation des ancrages.

Vous pouvez y accéder :

  • From the main menu, as WindowsDockable DialogsPaths.

  • from the Tab menu in any dockable dialog by clicking on and selecting Add TabPaths.

In the Windows menu, there is a list of detached windows which exists only if at least one dialog remains open. In this case, you can raise the « Paths » dialog from the main menu: WindowsPaths.

2.3.2. Utilisation du dialogue des chemins

Each path belongs to one image: paths are components of images just like layers. The Paths dialog shows you a list of all paths belonging to the currently active image: switching images causes the dialog to show a different list of paths. In multi-window mode, you can show the name of the active image at the top of the dock by choosing « Show Image Selection » from the Tab menu.

If you are familiar with the Layers dialog, you have a head start, because the Paths dialog is in several ways similar.

At the top, there are two « Lock » icons:

Lock Path

A « path » icon tells us whether editing the current path is locked (disabled) or not. Clicking the icon toggles between enabled and disabled.

[Note] Note

Until GIMP 2.10.32 this was called Lock Path Strokes. That name was considered ambiguous, because the term strokes is also used for stroking lines along a path, which this option does not change.

Lock Path Position

A « cross with arrows » icon tells us whether the current path position is locked (disabled) or not. When the path position is locked, the path can't be moved. Clicking the icon toggles between enabled and disabled.

The Paths dialog itself shows a list of all paths that exist in the image, with four items for each path:

Visibilité du chemin

Une icône « œil ouvert » si le chemin est visible, ou un espace blanc s’il ne l’est pas. « Visible » signifie que la marque du chemin figure sur l’image, mais cela ne signifie pas que cette marque figure effectivement dans les pixels de l’image elle-même, à moins qu’elle n’ait été « tracée » (Tracer le chemin) ou traitée d’une autre façon. On fait apparaître l’œil en cliquant sur l’espace symbole de l’œil (bascule).

Enchaîner les chemins

Un symbole « chaîne » peut figurer à droite de l’espace symbole de l’œil si le chemin est verrouillé pour les transformations. « Verrouillé pour les transformations » signifie que le chemin fait partie d’un groupe d’éléments (calques, canaux…etc) qui seront solidairement affectés de la même façon par une transformation (un changement d’échelle, une rotation…etc) appliquée à l’un d’entre eux. L’espace-symbole-de-chaîne est une bascule : le clic y fait apparaître/disparaître le symbole de chaîne.

Aperçu du chemin

C’est une petite icône affichant un croquis du chemin. Vous pouvez cliquer-glisser cette icône sur une image, ce qui créera une copie du chemin dans cette image.

Nom du chemin

Un nom de chemin doit être unique dans l’image. Un double clic sur un nom de chemin permettra d’éditer ce nom. Si le nom que vous donnez existe déjà, il sera distingué par une extension de type « #1 ».

Si liste n’est pas vide, il y aura toujours un bandeau de chemin surligné, indiquant le chemin actif, celui sur lequel s’appliqueront les transformations que vous effectuerez à l’aide du menu du dialogue ou des boutons du bas. Cliquer sur un nom de chemin active ce chemin.

Un clic droit sur une entrée de la liste ouvre le Menu local des chemins. Vous pouvez aussi y accéder par le menu onglets du dialogue.

2.3.3. Boutons

Les boutons en bas de la fenêtre correspondent tous à une entrée du menu des chemins obtenu par clic droit sur une entrée de la liste des chemins, mais certains disposent d’options supplémentaires obtenus en pressant en même temps une touche de contrôle.

Nouveau chemin

See New Path. Holding down Shift makes a new (empty) path with the last used values, without opening the New Path dialog.

Monter le chemin

See Raise Path. Holding down Shift moves the path to the top of the list.

Descendre le chemin

See Lower Path. Holding down Shift moves the path to the bottom of the list.

Duplicate Paths

See Duplicate Paths.

Paths to Selection

Converts paths into a selection; see Paths to Selection for a full explanation. You can use modifier keys to set the way the new selection interacts with the existing selection:

Touches de contrôle Action
Aucune Remplacer la sélection existante
Maj Ajouter à la sélection
Ctrl Soustraire de la sélection
Maj+Ctrl Intersecter avec la sélection.
Sélection vers chemin

Holding down Shift brings up the Advanced Options dialog, which probably is only useful to GIMP developers.

Paint along the paths

See Stroke Paths. Holding down Shift strokes the path based on the last used values without opening the Stroke Paths dialog.

Supprimer le chemin

Delete Path deletes the currently selected path.

2.3.4. Le menu local des chemins

Figure 15.13. Le menu local des chemins

Le menu local des chemins

Le menu des chemins peut être appelé par un clic droit sur un bandeau de chemin dans la liste du Dialogue des chemins, ou en le choisissant dans le menu onglets. Il donne accès à la plupart des opérations concernant les chemins.

Edit Path

Edit Path is an alternative way to activate the Paths tool, used for creating and manipulating paths. It can also be activated from the Toolbox, or by using the keyboard shortcut B.

Modifier les Attributs du chemin

Modifier les Attributs du chemin ouvre un petit dialogue qui vous permet de changer le nom d’un chemin. Vous pouvez aussi le faire par un double clic sur la liste du dialogue des chemins.

Color Tag

Color Tag brings up a sub menu, similar to the one in the Layers Dialog, that allows you to select a color tag for the selected path.

Nouveau chemin

Nouveau chemin crée un nouveau chemin, l’ajoute à la liste des chemins et le rend actif pour l’image. Ouvre un dialogue pour le nommer. Le nouveau chemin est créé sans point d’ancrage : vous devrez utiliser l’outil Chemins pour lui en donner et l’utiliser.

Monter le chemin

Monter le chemin monte le chemin d’un rang dans la liste du dialogue des chemins. Sa position dans la liste n’a aucune importance, ce n’est qu’une facilité.

Descendre le chemin

Descendre le chemin descend le chemin d’un rang dans la liste du dialogue des chemins. Sa position dans la liste n’a aucune importance, ce n’est qu’une facilité.

Dupliquer le chemin

Duplicate Path creates a copy of the active path, assigns it a unique name, adds it to the list in the Paths dialog, and makes it the active path for the image. The copy will be visible only if the original path was visible.

Supprimer le chemin

Supprimer le chemin : supprime le chemin courant.

Fusionner les chemins visibles

Fusionner les chemins visibles fusionne en un seul chemin tous les chemins possédant l’« œil » dans le dialogue des chemins. C’est pratique si vous voulez les Tracer de la même façon.

Paths to Selection; Add Paths to Selection; Subtract Paths from Selection; Intersect Paths with Selection

These commands all convert the active paths into a selection, and then combine it with the existing selection in the specified ways. (Paths to Selection discards the existing selection and replaces it with one formed from the path.) If necessary, any unclosed components of the path are closed by connecting the last anchor point to the first anchor point with a straight line. The « marching ants » for the resulting selection should closely follow the path, but don't expect the correspondence to be perfect.

Sélection vers chemin

On peut accéder à cette fonction de différentes façons :

  • From the main menu, as SelectTo Path

  • À partir du menu du dialogue des chemins, par Sélection vers chemin.

  • From the Selection to Path button at the bottom of the Paths dialog.

Sélection vers chemin crée un nouveau chemin à partir d’une sélection de l’image. Dans la plupart des cas, le chemin suivra les pointillés mobiles délimitant la sélection mais la correspondance n’est pas parfaite.

Converting a two-dimensional selection mask into a one-dimensional path involves some rather tricky algorithms: you can alter the way it is done using the Advanced Options, which are accessed by holding down the Shift key while pressing the Selection to Path button at the bottom of the Paths dialog. This brings up the Advanced Options dialog, which allows you to set 20 different options and variables, all with cryptic names. The Advanced Options are really intended for developers only, and help with them goes beyond the scope of this documentation. Generally speaking, Selection to Path will do what you expect it to, and you don't need to worry about how it is done (unless you want to).

Fill Paths

On peut accéder à cette fonction de différentes façons :

  • From the main menu, as EditFill Paths…

  • From the Paths dialog menu, as Fill Paths….

  • From the Fill Path button in the Tool Options for the Paths tool.

Fill Path fills all areas delimited by the path with the current foreground color or currently selected pattern. See the section about Fill Path for more information.

Stroke Paths…

On peut accéder à cette fonction de différentes façons :

  • From the main menu, as EditStroke Paths…

  • From the Paths dialog menu, as Stroke Paths….

  • From the Paint along the path button at the bottom of the Paths dialog.

  • From the Stroke Path button in the Tool Options for the Paths tool.

Stroke Path renders the active path on the active layer of the image, permitting a wide variety of line styles and stroking options. See the sections about Stroke Path and Stroking for more information.

Copy Paths

Copy Paths copies the active path to the Paths Clipboard, enabling you to paste it into a different image.

[Astuce] Astuce

Vous pouvez aussi copier-coller le chemin en faisant glisser son icône depuis le dialogue des des chemins jusque dans l’image cible.

[Note] Note

When you copy a path to an image, it is not visible. You have to make it visible in the Paths dialog.

Coller le chemin

Paste Path creates a new path from the contents of the Path Clipboard, adds it to the list in the Paths dialog, and makes it the active path for the image. If no path has previously been copied into the clipboard, the menu entry will be disabled.

Export Paths

Export Paths… allows you to save a path to a file: it pops up a file save dialog that allows you to specify the file name and location. You can later add this path to any GIMP image using the Import Path command. The format used for saving paths is SVG: this means that vector-graphics programs such as Sodipodi or Inkscape will also be able to import the paths you save. See the Paths section for more information on SVG files and how they relate to GIMP paths.

Importer un chemin

Import Path… creates a new path from an SVG file: it pops up a file chooser dialog that allows you to navigate to the file. See the Paths section for information on SVG files and how they relate to GIMP paths.