Create document with transparent background. Add the word 'word' as text. Create selection from alpha channel. create new layer. select new layer. (edit menu) stroke selection.

How do I control the aspect of stroking? all new pixels: within selection, over selection, outside selection?

Currently the stroke is over selection; it seems as some of the area inside is consumed by the stroke occluding the text layer below with new pixels.

  • GIMP isn't ideal for work like this. You might be better using a vector image editor such as Inkscape which is also free and open source. It's easy enough to add an outside stroke to text without consuming the inside of the letters, by selecting a different stroke and fill order. Also, the text will remain editable as text. See example
    – Billy Kerr
    Commented Feb 21, 2020 at 14:00
  • I can add this as an answer if you don't mind expanding the question to include other software.
    – Billy Kerr
    Commented Feb 21, 2020 at 14:08

1 Answer 1


"Stroke selection" doesn't restrict the output to the selection, the selection border is used as a location for the stroke, which in effect straddles that border.

At that point a quick and dirty solution is to just hit [delete] which will discard the part that is inside the selection, but this will create a tiny gap between the text and the outline.

A better solution is to move your new layer under the text, so only the part that is outside the text will show (the rest will be hidden by the text).

For better results, stroking a path is cleaner than stroking the selection.

What you want to do is perhaps:

  • Text to path (more accurate path that doing alpha to selection followed by Select>To path
  • Add new layer
  • Remove the selection
  • Edit>Stroke path
  • At that point your outline straddles the text border
  • For an outline that just extends the text, move the outline layer under text layer (in that case you have to use a line width that is twice as big as what your want, since half or it will be hidden).

Otherwise you can use the ofn-outline-layer script.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.