Thanks for coming to InDesignSecrets.com, the world's #1 resource for all things InDesign!

Locking Objects For Easier Aligning

After reading some of the comments on David’s post about Building an Org Chart or Flowchart in InDesign, I thought I?d offer up a quick tip on how to force objects to align the way you want. Basically, I just wanted to draw more attention to Anne-Marie’s comment that locking an object is the key to making it, well, the key object.

It’s true that InDesign’s aligning abilities aren’t quite as convenient as Illustrator?s; you can?t simply click on an object to make it the one others align to. But in most cases, it?s still quite easy to align objects to any other object on a spread. The trick is to temporarily lock the position of the object you want to align to. When the position of an object is fixed, other objects have no choice but to align to it. After you do your aligning, you can unlock the object and go about your business. The whole operation takes only a couple seconds.

You have to be able to select an object in order to force others into alignment with it. So if you?re using CS5, open Preferences and in the General Preferences panel uncheck Prevent Selection of Locked Objects. This makes CS5?s Lock command behave more like the Lock Position command of earlier versions of InDesign. If you?re using an earlier version, you can skip this trip to Preferences.

In the example below, say you wanted to align the right edges of the red and blue objects to the right edge of the green one.

First, make sure Align to Selection is chosen in the Control panel.

By default, if you now select all three and click on the Align right edges button, all three objects will right align on the right-most edge. In this case, that belongs to the blue object.

But if you lock the green object (command-l), it becomes immovable.

Now when you click the Align right edges button, the red and blue objects will right align to the right edge of the green one.

If you have no further need for the green object to be locked, unlock it by choosing Object > Unlock All On Spread, or pressing command-option-l. If you?re using CS4 or earlier, make sure the green object is selected and choose Unlock Position (also command-option-l).

Tags
Related Articles
Comments

12 Comments on “Locking Objects For Easier Aligning

  1. Lots of love for the Align panel. I agree that the ID team could borrow a few tweaks from Illustrator in this regard, but it is still great.

    The new preference setting that by default prevents locked elements from being selected has been one of the perplexing CS5 changes for me. I found early on that I could turn it off (to allow selection of locked objects), but I don’t really understand why they would make not being able to select locked objects the default behavior. Do they really think that most people in most situations want their locked objects to become un-selectable?

  2. Another way to lock and unlock items in InDesign CS5 is through the layers panel. If you expand the layer you will see what objects are on each layer, and each can be locked or unlocked there too. :)

  3. Mike: Thanks for taking my comment further in this post, it’s great.

    Mark: The new Lock behavior in CS5 is a feature. Items are truly locked — position *and* contents — when you can’t select them. (To unlock them, you can click the little padlock icon on the object, or unlock their sublayer in the Layers panel.)

    In prior versions, and if you disable the Prevent Selecting Locked Objects pref in CS5, you can lock an item but still edit its contents. Which to many people didn’t really mean “locked” you know? ;-)

    In CS5 it’s up to you whether locked items are truly locked or just their positions are locked.

  4. One funny little trick involving locked objects in CS5: As Anne-Marie pointed out, you can click the padlock icon to unlock an object. But if you’re in Preview mode, you can’t the see the padlock. However, it actually still works: You just have to hover the cursor in the place the padlock icon would be. (This doesn’t work when frame edges are hidden however. Drat.)

    Thanks, Mike, for bringing this up. But ultimately, I’m sticking with Smart Guides for my alignment needs 99% of the time.

  5. What I’d like to know is how many more little icons can they fit around a text frame … :) and when will they move the outport?

  6. I have all the align functions set up as shortcuts: 7,8,9 in the number pad are horizontal align and 0,1,4 are vertical. I simply cannot work without this!

  7. Thanks for the post. I’ve been trying to suss this one out for a while and it keeps catching me out.

    Thanks again, I’m going to use this from now on.

  8. Thanks for the note about the padlock icon. I have a (bad?) habit of working with the frame edges turned off, so I didn’t see the little icon.

  9. A belated thank you. I had ‘argue’ with my InDesign instructor a few iterations back that there had to be a way to make one object the main item, but she insisted there wasn’t. And maybe at the time there wasn’t. Glad there is now. I need this.

Leave a Reply

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

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>