Speaking of graphics software, by pure chance recently I ran across the obvious and thus embarrassing solution to a problem that has vexed me for quite some time. Not only have I wrestled with this conceptual beast on multiple occasions — and lost, even after spending hours using imprecise or generic keywords, thus inevitably drowning in the sea of noise that is rapidly rendering search itself almost useless — but I’ve known for several years that I would have to slay said beast in order to design a graphic for a book I was working on.
Thankfully, said book has proceeded at a snail’s pace, giving the world time to help me despite my obliviousness. (That I came upon the answer by mere happenstance is disheartening given the implications for other aspects of my future, but still — I’ll take it.)
The problem arises when trying to show a single text color across a full background gradient. While it’s likely in practice that such a problem would occur on a page featuring many words, here’s an example using a single word in black text against a full gradient from white to black:
As you can see, on the right side the black text is swallowed by the black background. Just as obviously, switching to white text only shifts the instigation of the problem:
The temptation on a page with many spread-out words would be to switch text colors midway through the gradient, but at best that’s a hack. The simple and elegant fix — which it pains me I was unable to arrive at on my own — is to add a contrasting border around the text:
And here’s the same solution for white text, using a black outline:
If completely bounding your text seems heavy-handed, here’s a slightly offset version that is still readable but also conveys a sense of mood:
The solution also works for two colors, assuming sufficient contrast:
As to how to implement such changes in most graphics programs, the simplest workflow seems to be duplicating the text, changing the color in the copy, then slightly expanding or shrinking one copy until the two can be arranged one on top of the other, thus revealing a consistent border. In Inkscape, however, because all text can be either stroke or fill, you can simply change the fill to one color and stroke to another.
If you’re a total beginner, here’s a GIMP video and one for Inkscape. If you have a little experience with GIMP, here’s a shorter video.
(Note: the current version of Inkscape is 0.91. Prior to version 0.91 the previous stable release was 0.48.5 in July of 2014. Inkscape version history here.)
— Mark Barrett
Comment Policy: Ditchwalk is a wild place, but not without tending. On-topic comments are welcomed, appreciated and preserved. Off-topic or noxious comments are, like invasive species, weeded out.