Apply a text background color in Adobe Illustrator CS6

I’d like to highlight titles in my text like this:

enter image description here

I’m doing that by adding a blue rectangle behind the text, but every time I change the text which is 16 pages long I have to go and move the placement of all these title boxes. Can I add it so that its attached to that line of text?


Turns out you can do this (sort of) using appearance attributes. The caveat is the lines of text have to be their own text elements rather than a character selection.

How to make the boxes

  1. Open the appearance panel, Window > Appearance
  2. Double click Characters to access the character appearance
  3. Set the Fill to your foreground color
  4. Click Type to get back to the text element
  5. Add New Fill (bottom left hand corner of the the panel)
  6. Set the new fill to your background color
  7. With the new Fill selected, Add New Effect > Convert to Shape > Rectangle…
  8. Set the Rectangle to whatever you want, as long as size is relative it will reflow to your text.

You should have something like this,

Finshed Sample

It also works accross lines,

Two line Sample

Here’s my appearance settings for the text elements. Note you may have to drag the Characters layer above the newly created Fill layer.

Appearance Panel Settings

Pro Tip(s)

  • You can save as a Graphic Style to apply it to any element and synchronise any changes you make to the style.
  • You can do other cool effects with this like capsules using different shapes (e.g. Rounded Rectangle)

Capsule Sample

Source : Link , Question Author : Tom , Answer Author : user8592

Leave a Comment