Anchored objects allow you to place items like photos and captions next to a specific point in the text of a story, by inserting those items into the story itself. This is essential for ensuring the content order in a reflowable EPUB. Also shown are potential problems with text wrap and layering that can occur when you anchor items.
- [Instructor] In a previous movie, we saw how to choose which InDesign objects will be exported into an EPUB using the Articles panel, and for the most part, you can also use the Articles panel to fix problems with EPUB content order simply by arranging items as you want them in the panel. But you will run into a problem when you have items that need to appear next to a specific point in the text of a story. For that, you need to insert the items into the story itself, and you can do that with anchored objects. Let's see how.
So here's our exercise file, where we've created an article, and added the content in our layout. And we put it in the right order. Now I want to put the photo of the two dogs and the captions here right between the second and third paragraphs on the first page. First, I'll group them, so I only have to anchor one item. Just press command or control G. Then I'll click and drag this blue square just before the first character in the third paragraph, right before and here.
And drop it there. If you didn't see the little blue square, then choose View, Extras, and choose Anchored Object Control. And if I have the item selected, and text thread showing, which I can do by choosing View, Extras, Show Text Threads, then I can see a dash line pointing from the group to the spot where I anchored it. Also notice that in the layout something happened that's not so good. See how the body text is now crashing into the caption here? That's because the caption has text wrap applied to it, but when we anchored the item the text wrap went away.
Why? Well, because text wrap on an anchored item can only affect lines after the one where the anchor appears. Otherwise, InDesign could never figure out how to wrap the text since the anchored item would always be affecting its own position. So to maintain your layout, you'd have to use another item to create the wrap. Like I can drag out an empty rectangle and apply text wrap to approximate what the caption had. Something like that. Now this is great because I've anchored the photo to that spot in the text, so it will come out there in the EPUB.
And anchoring the photo had no effect on its position in my layout. It will, however, move now, if I edit the text before the anchor. Like so. The other thing to note is that if this picture and caption were on a different layer, they'd be moved to the layer containing the main text frame, since they're now part of the content in that text frame. Also if you look in the Articles panel, you might notice that the entries for the photo and its caption are gone. Now that they're part of the main story, they can't be selected or manipulated separately here anymore.
Let's also anchor the photo on the second page. I'll zoom out, scroll down to the second page, and then zoom in a bit again. I'll select the photo with the Selection tool. And drag the anchor marker just before the start of the text on this page. And notice when I anchored the photo, the one that was hidden suddenly came into view. This is because in the Layers panel both photos were above the text frame where we just anchored the top photo. But since this photo wasn't visible in the layout, we probably don't even need it.
So we can just delete it or hide it if we might want it later on. In this case I'll just select it and delete it. Now let's export to re-flowable EPUB again, and make sure we're basing the content order on the Articles panel. I'll press command or control E, export to the desktop, re-flowable EPUB, and click Save. Make sure the content order is Same as Articles Panel, click OK. And we can ignore this warning about the appearance of overlapping objects. And our EPUB looks good.
The first photo and caption appear where we anchored them, and same for the second photo. So here we saw how to make items appear at specific points within a story by anchoring them, and we also talked about how anchoring items can affect your document by changing things like text wrap and layering. Next, we'll take a look at how to control the appearance of graphics in re-flowable EPUB with object export options.
- Overview of interactive document types, including PDF and EPUB
- Creating interactive objects
- Setting up hyperlinks, cross-references, and a table of contents
- Working with media
- Publishing documents with Publish Online
- Creating EPUBs
- Following workflows for interactivity: interactive PDF, reflowable EPUB, and fixed-layout EPUB