3.18. Stroke Path

The Stroke Path command strokes a path in the image. There are two ways you can stroke the path, either by using a paint tool, or without using one. There are various options which you can use to specify how this stroke should look.

[Note] Note

This command is active only if there is a path in your image.

3.18.1. Activating the Command

  • You can access this command from the image menubar through EditStroke Path.

  • You can also access it by clicking on the button with the same name in the Path dialog.

3.18.2. Description of the Dialog Window

Figure 16.20. The Choose Stroke Style dialog window

The “Choose Stroke Style” dialog window

The Choose Stroke Style dialog box allows you to choose between stroking the path with the options you specify or stroking it with a paint tool. If you stroke the path with a paint tool, the current paint tool options are used to draw the stroke.

Stroke line

The stroke is drawn with the current foreground color, set in the Toolbox. By clicking on the triangle next to Line Style however, the dialog expands and you can set several additional options:

Line Width

You can set the width of the stroke using the text box. The default unit is pixels, but you can choose another unit with the drop-down list button.

Solid color / Pattern

You can choose whether the line is drawn in the Solid or the Pattern style. Here, Solid and Pattern are distinct from the dash pattern. If you select a Solid line with no dash pattern, an unbroken line is drawn in the foreground color set in the Toolbox. If you select a Patterned line with no dash pattern, an unbroken line is drawn with the pattern set in the Toolbox. If you select a line with a dash pattern, the color or pattern is still determined by the foreground color or pattern set in the Toolbox. That is, if you select a marbled pattern and Patterned, dashed lines, the dashes are drawn in the marbled pattern

Line Style

This drop-list brings some detailed options :

  • Cap Style : You can choose the shape of the ends of an unclosed path, which can be Butt, Round or Square.

  • Join Style : You can choose the shape of the path corners by clicking on Miter, Round or Bevel.

  • Miter limit : When two segments of a path come together, the mitering of the corner is determined by the Miter Limit. If the strokes were wide, and no mitering were done, there would be pointed ends sticking out at the corner. The Miter Limit setting determines how the gap, formed when the outer edges of the two lines are extended, will be filled. You can set it to a value between 0.0 and 100.0, by using the slider or the associated text box and its arrows.

    Figure 16.21. Example of miter limit

    Example of miter limit

    Left: Limit=0; Right: Limit=5;


  • Dash Pattern : On the pixel level, a dashed line is drawn as a series of tiny boxes. You can modify the pattern of these boxes. The black area with thin vertical lines represents the pixels of the dash. If you click on a black pixel, you remove it from the dash. If you click on a white pixel, you add it to the dash. The gray areas indicate how the pattern will be repeated when a dashed line is drawn.

  • Dash Preset : Instead of making your own dash pattern, you can choose one from the drop-down box. This pattern will then be displayed in the Dash pattern area, so you can get an idea of how it will look.

  • Anti-aliasing : Curved strokes or strokes drawn at an angle may look jagged or stair-stepped. The anti-aliasing option smooths them out.

Stroking with a Paint Tool
Paint Tool

You can select a paint tool to use to draw the stroke from the drop-down box. If you do that, the currently-selected options of the paint tool are used, rather than the settings in the dialog.

Emulate Brush Dynamics

See Brush Dynamics.