Members Only

Create Text Highlighting with a Custom Edge

Use this simple trick to create customizable highlighting to fit any piece of text.

A few days ago one of our customers, who publishes documents in 30-40 different languages, contacted me about a problem they were having with their product catalog. Within these documents they use a label where the text is highlighted (like the one you see in the image below) to indicate new products. The word “New” when translated into other languages might take up more space (in Italian, for example, “New” is “Nuovo”). Consequently, any time this customer downloaded a document in a new language from Redokun, they had to manually modify these labels to make them fit the new language. Imagine having to make this change in 30, 40 or 50 products for 30-40 languages. That is the type of job you don’t want to be doing in InDesign.

The final result

They wanted to automate this task. Every time the text changed, the highlight had to adapt.

First test

InDesign is an amazing piece of software. Every shape you place in a document can be converted into a text frame. So, I tried to:

  1. Create a highlight shape;
  2. Transform the shape into a text frame by clicking on it with the “Type tool”;
  3. Activate the text-frame’s Auto-Sizing option so that the frame could automatically enlarge and adapt to its content (more on this later).

Unfortunately, the result was not the best. With this method, when the text changed, the label adapted in width. But with this solution, I was facing the issue that is shown in the image above. The right side of the label didn’t stay consistent when the text frame width changed.

The solution

I had to come up

with a new solution. And luckily, this proved successful. So here is how I solved the issue, and how you can re-create the same label:

  1. Create two shapes (a rectangle and a triangle).
  2. Transform the rectangle to an auto-sizing text frame.
  3. Anchor the triangle to the rectangle.

Easy right?! Let’s see the process step-by-step.

Create two shapes (a rectangle and a triangle)

  1. The first step is to split up the more complex shape into two different objects.

This will allow you to make sure the text frame adapts its width automatically and at the same time, the corner will maintain the correct shape.

Transform the rectangle to an auto-sizing text frame

Now we have to transform the rectangle into a text frame and then set it up so it adapts its width automatically when the text changes.

  1. Select the Type tool and click on the rectangle. This will transform your rectangle into a text frame.

At this point, I’d suggest you place some text inside and to apply the correct formatting to the text. In my case, I want it to look like this.

  1. Right-click on the rectangle and select Text Frame Options.
  2. Click on Auto-Size on the top of the pop-up.
  3. Change Auto-Sizing to Width Only.

Anchor the triangle to the rectangle

The last step is to anchor the triangle to the text frame and make sure that it moves every time the text frame changes its width.

  1. Select the triangle.
  2. At the top, you can see a little blue square. Press the Option/Alt key and click on the little square, now drag the square into the text frame. As soon as the mouse pointer meets the frame, you’ll see a black line that will follow your movements. That black line indicates where you are placing the anchor. Make sure to place it after the text.

When you release, InDesign opens a new pop-up. This pop-up allows you to adjust how the anchored object (the triangle) should behave when the text frame changes size or position.

  1. Let’s change the options. (A) Set Position to Custom. (B) In Anchored Object change the Reference point so that InDesign will use the left-center point of the triangle. (C) In Anchored Position change the Reference point so that InDesign will use the right-center point of the rectangle to position the triangle. (D) Change both the options for X and Y to Text Frame and 0 mm, in this way, the triangle will be attached to the text frame. (E) Finally, activate Prevent Manual Positioning to make sure nobody can manually change the position of the triangle.

If you look closely at the image above, you’ll notice that the triangle is cutting away a bit of my text. To change this, we have to add some space on the right side of the text frame. You can do this by changing the Right Indent, in my case, I’ll add 1 mm.

Conclusion

InDesign is an amazing tool, full of functionalities that can help you simplify and automate most of your daily tasks. As you probably noticed from the example in this post, discovering all the features and learning how to use them correctly might save you a huge amount of time. Nowadays, there are a lot of great, cheap (below US$100) options for learning InDesign. Here is a list of my favorite InDesign courses that you can use right away to improve your skills!

Bookmark
Please login to bookmark Close

Not a member yet?

Get unlimited access to articles and member-only resources with a CreativePro membership.

Become a Member

Comments (21)

Leave a Reply

Your email address will not be published. Required fields are marked *

  1. Mary Boland

    Hi. I tried it using a paragraph rule below (so it went behind the text) using text width and a right indent and then the anchored object and it worked well also. The same concept but I could put it in a paragraph style and have other paras below and above.

  2. Rainer Klute

    If you have a slant on both left and right sides of the NEW/NUOVO, you can do it easier by (1) applying an angle to the text frame and (2) apply the same but negative angle to the text.


    (If my English is hard to understand, maybe this screenshot helps: https://klute.d.pr/5vmxlp)

    1. Mike Rankin

      Nice tip, Rainer. Thanks!

  3. Roland Dreger

    Here you will find a more detailed video and an IDML file: https://vimeo.com/368965388

    1. Roland Dreger

      Oops, misfiled. Should be the answer to Patrick’s question above.

  4. Scott Citron

    Magnifico! Mille grazie, Stefano!

  5. Olaf Nelson

    All I want to do now is find places to use this technique. Sadly nothing I’m working on right now needs it.

  6. Hi, Patrick T: Creating the anchor and settings was new for me, but if you follow the instructions exactly, it will work. Even when anchored, the triangle won’t snap to the rectangle until the Anchored Object Options are adjusted, as per the instructions.

    1. Patrick Toebosch

      indeed, it worked fine for me too, but I was looking to the way Roland Dreger did it. He placed the anchored object on the path. But that way didn’t work for me, and I was asking how to he did it?

      1. Olaf Nelson

        I’m curious about this too.

  7. Siddalingayya

    Very tricky… Nice and very use full.. Cheers

  8. Stefan De Pauw

    Awesome tip! Thanks! I just updated the company template with some auto sizing flow chart arrows with points and tails. And added an instruction not to do a “select all” to the text and start typing or the elements magically dissapear ;-)

    1. Roland Dreger

      If you insert the anchored object into the path of the textframe (create type on path), you can delete the entire content: https://vimeo.com/367240323

      1. Patrick Toebosch

        I’ve tried this, but I can’t anchored an object on the path. How did you do it?

      2. Stefan De Pauw

        Thanks for the extra tip and file Roland.

  9. Peter Laely

    Cool stuff – and that simple – grat idea

  10. Laurie Ruhlin

    Anchored Objects to the rescue again! Love this solution!

    1. I totally agree with you and with Stefano! Welldone! :-)

    2. Stefano Bernardi

      You can say it, Laurie! Anchored Objects are a blessing :)

  11. miles linklater

    Absolutely brilliant!

  12. Very cool. I could see this coming in handy when looking to add an interesting design element to headlines or pull quotes.