Features or Speed… why not both InDesign?

porquenolosdos

After a recent post discussing the complications of indexing a rather large InDesign file (1600+pp), it is worth mentioning another issue encountered with the project, namely the reduced speed of InDesign.

There are already several articles concerning “slowdowns” while working with InDesign, namely:

http://indesignsecrets.com/why-is-indesign-soooo-slow.php

http://forums.adobe.com/message/4815713#4815713

Put simply, the larger the file became, the harder it was to work on. Little things such as placing the text cursor between words resulted in a spinning beachball of death for five minutes before the cursor once again became a text cursor.

Disabling several features in InDesign made the file somewhat workable:

1. Display performance – to these settings :

slowdown01
2. Pages panel – turn off the preview for the actual pages:

slowdown04
3. Turn the preflight panel off:

slowdown05
4. Live screen drawing – never:

slowdown03
5. Dynamic spelling off:

slowdown02
6. Do not use GREP styles or Nested styles
7. Do not use index entries or cross references

While this made the file workable, it was at the expense of the good features of InDesign. The slowdown was to the stage where using a word processor to accomplish the same task was considered!

Within the preferences, there is no ability to control the amount of RAM reserved for InDesign to use, nor is there the ability to control how often InDesign autosaves to its backup… something that is possibly slowing InDesign down even further.

Some of the features of InDesign were not necessary for this task as the project was completely black text supplied by the client, so having a lower quality display performance without seeing the page previews was not an issue. Preflight was not a concern with this particular file given that it was black text within one rather long text-frame and the spelling was to remain as the client provided the artwork.

Initially there was concern that turning GREP styles off would limit the control of “runt lines”. GREP styles had also been used for formatting of particular words, but because no type was going to be added, performing a one-off find/replace using the relevant GREP was able to remove the need for GREP styles. It was amazing to see the difference in speed when the file had the GREP styles turned on, opposed to when they were not applied – in this project the GREP styles were a major contributing factor to the file’s slow performance.

Followers of this blog will be familiar with several GREP styles that have been used to correct names or details within variable data campaigns. After this experience, it would appear that GREP styles are better suited to projects where content will be added dynamically (such as a Data Merged file) or constant alterations need to be made; rather than static documents – especially where no new content will be added.

The project DID have to be indexed (as discussed in a previous post) and found that once the file was indexed, the speed of the file slowed to a crawl.

Wrangle up InDesign index entries… without InDesign.

A recent project involved creating an enormous index… in fact there were over 100,000 index entries to create.

Creating index entries is normally a chore. To create just one index entry, the normal procedure is to:

  • Highlight the text to be indexed
  • Select “New Page Reference” from the index palette (or command + 7)
  • Enter the details and click Add (or Add All) then OK

indexref1

indexref2

In a normal book, indexing is something that is done carefully by the author or staff dedicated to the task – entries in the index often refer to certain instances of a word rather than every instance of its use. This project however used the index as a lookup table instead, so the more advanced features of the index palette (e.g. see also references, index levels) were not necessary.

For this project, the items to be indexed were restaurant names. The name appeared in the same line as the description, so using a Paragraph Style to identify the item for an index entry could not be used. However, the restaurant names DID have a Character Style associated with them.

Because there were 100,000 index entries in this book and each entry had its own character style, there were easier methods to perform this task. There are several scripts online that can create index entries from character styles:

For this project, because there were two character styles used to identify the restaurant names, I used Peter Kahrel’s script. While testing the script on a sample chapter, everything appeared to work correctly… it took time but all the names in character styles were added to the index.

However, when the time came to apply this script to a document 1,628 pages long, the script would run, and then the spinning beach-ball of death would appear. Assuming I was not allowing the script enough time to finish its tasks, an attempt was made to let the script run over a weekend on the fastest machine in the office. Sadly, this did not work. Put simply, there were just too many entries for the machine to handle.

Enter Textwrangler…

Luckily, all the text for this project, while many pages long, was all in one text frame. This provided the option to enter the index entries while the document was in a raw text format. To do this, the text was exported as an Adobe InDesign tagged text file by placing the cursor anywhere in the text and selecting File/Export (command + E).

indexref3

The newly saved text file was then opened in Textwrangler. The a find/change using Textwrangler’s GREP was then made for the following:

indexref4If the code is hard to see in the picture, here is the type:

Find:

(<cstyle:placename>)(.+?)(<cstyle:>)

*placename above refers to the style to index.

Replace:

<Idx:=<IdxEnType:IdxPgEn><IdxEnRngType:kCurrentPage><IdxEnDispStr:\2>>\1\2\3

(make sure the Grep checkbox is ticked)

Once the changes in the text files were saved, the type was imported in place of the old text in the InDesign file, and within moments the document was completely indexed as required.

The only other part that took time was to run the “Generate Index” function from InDesign itself, and considering the amount of index entries in the document, took an hour to generate.

Centering “fit frame to images” using InDesign CS6

In mid February, a post on the Adobe Forums asked the question:

I’m using Data Merge to place a single image on each page.  I have the frame centered on the page and its reference point set to the center.  I have the Data Merge options set to “Fit frame to content”, but when I run the merge all the images align to the top left corner of the frame.  The frame expands or contracts as directed, but I would like for it to expand from the center.  What am I failing to do?
 

The question was answered:

It doesn’t work for “fit frame to images” – instead the frame fitting options take the measurement from the top left.
 

Image fitting options in Data Merge are explored in greater depth in the “Merge Right” article in issue 52 of InDesign Magazine. Ultimately, there is a checkbox in the Content Placement Options dialog box of Data Merge that is misleading – it is the “Center Content” button. This button centres the content within its frame, but not the frame to its relative position on the page. For most of the fitting methods, this is fine, but for the “fit frame to images” option, the frame size will change whenever the image size changes, and when it does, the image resizes from the top left of its position on the page, rather than from the centre point of the image.

A solution was provided to the poster along these lines:

  1. Create a text box larger than the largest image that is part of the merge. Align the text to be centered not only left and right, but top and bottom (from the text frame options). If done correctly, the flashing cursor should be in the center of the textbox.

pic1

  1. Draw a new graphic frame and assign the image field of the data merge to the frame.
  2. Cut and paste it into the textbox. If done correctly the box should be centered within the textbox.

pic3 merged

  1. Make sure that Image Placement dropdown of the Content Placement Options from the Data Merge panel is set to “fit frame to images”

pic2

The solution is also flexible in that the image can be aligned to left, center or right horizontally, and/or top, center or bottom vertically.

pic4 merged

The solution works… provided the text box is big enough for the images within the data merge… otherwise the item becomes overset and the image disappears.

pic5

It is also a somewhat clunky solution as it means having a large textbox in the document simply to position an image.

An alternate solution would be to draw a larger than normal frame with the “Center Content” turned on using the “preserve frame and image size”, but if the content was to have an outline on it then this solution would not be appropriate.

pic6 merged

However, CS6 introduces a new text frame feature called auto size. This is handy for not only making text boxes fit the type only, but for creating minimum sizes and allowing the box to “grow” when more text is added, based on the auto-size instructions in the options.

Using this new feature, we can take the earlier solution and apply the auto-size to the text box that is housing the now inline graphic. I can now also control where the image “grows” from using the auto-size instructions, rather than using the text alignment features of the text box.

pic7

The other great feature is that I can use anchored objects with this image too… something that I could not normally do with an image frame as anchored objects can only anchor to text frames. In this case I’ve added a fancy caption bar that uses anchored objects of its own to grow/shrink the caption as the data comes in.

pic8 merged

So scrolling from record to record, I can see that the images are indeed starting from their reference point in the auto-size dialog box, and that the caption anchored object is always staying in its position at the top right of the picture.

pic9

When merged to single page merges, this trick works fine… however when I merge to multiple records per page… it goes haywire.

pic10

Despite this bug, this trick is also handy even if data merge isn’t being used. As a snippet or a library item, as not only does caption stay in the same relative position to the image regardless of where the image is moved, but there is more flexibility as to how the caption can be positioned or designed.

The file used for this article can be found here. To keep the file size down, the original links have been removed so that substitute the links and merge file can be used to try this out.

Never Break-up on a Date… or a name… or a time…

In issue of 52 of InDesign Magazine, Sandee Cohen provides a brilliant and simple solution to a problem that many designers face – how to control widows and orphans on paragraphs (this is separate to page-defined widows/orphans). Download the issue to read about this handy tip.

Her advice is great, but can go one step further. Her solution can be adapted to not just fixing paragraph widows/orphans, but also any situation where a type should not break, such as:

  • Dates (e.g. 31 July)
  • Names (Mr John Citizen)
  • Times (4.00 pm)

The example here is an article about the Adelaide Phenomenon known as “Mad March”. The dates at the end of the article are breaking, and so is an individual’s name. These have been highlighted in Magenta to illustrate what needs to be fixed.

shot1

Part of Sandee’s fix, without revealing her magic trick, is to create a unique character style that only has the “no-break” attribute turned on and everything else left off.

shot2-first

The paragraphs in this text have a paragraph style applied that will undergo some GREP style magic. To do this, the paragraph style has to be edited, particularly the GREP styles portion of the dialog box.

shot2

Firstly, the dates have to be fixed. Click the “New GREP Style” button and select the “no-break” style that was made earlier, and then in the “To Text” field, type the following:

\d+\s(January|February|March|April|May|June|July|August|September|October|November|December)

This will look for any number followed by one space and followed by any month written in full. Anything that matches this will now have the “no-style” applied. Don’t click OK just yet, but click once in the grey box just underneath the field that was just typed to refresh the page.

shot3

Fixed. Now let’s fix the name Mr Paul McDermott. Still in the same window, click the “New GREP Style” button again, again using the “no-break” style, but this time in the “To Text” field, type the following:

(Mr|Mrs|Miss|Ms|Dr|Sir)\s[\l\u]+\s[\l\u]+

This will look for any name that has a title, initial or name, and surname. Yes, this is a basic GREP code and a better one could be written to encompass all sorts of names, but for this demonstration it will do. Click OK.

shot4

Voila! All fixed. The advantage with using these GREP style fixes as opposed to using non-breaking spaces or forced line breaks is that if the copy changes for whatever reason, many of the forced breaks don’t have to be removed. Non-breaking spaces are a hassle so if they don’t need to be made, why bother?

shot5

This article has focused on two instances where a no-break character style (with some GREP style magic) can keep names and dates together, but there are other uses for this such as times, dollar values… the list is up to you. As usual to see how this was done, feel free to download the sample here.

No links stinks methinks

Recently, my colleagues and I have noticed several InDesign files supplied by clients that contain images that do not appear in the links palette. This creates issues because:

  • The image cannot be edited
  • Its details (resolution, colour space etc) cannot be determined through the links palette
  • Its high-res appearance or PDF output can change from how the image appears in standard preview in InDesign.

When I tried to replicate this fault (having an image with no link in the links palette), the consistent way to achieve this fault was to cut (or drag) content from one application and paste it into InDesign.

To demonstrate this, I have dragged an image from my Facebook page into InDesign. This is how the links palette looks in InDesign:

pic1

Note that the links palette shows no link, so I have no mechanical information about the link from the links palette. When I right click on the image I can’t edit the image from the contextual menu.

Now, if I place the original image from my hard drive using the File/Place command, I can now see the information about the link from the links palette and I can also edit the image from the contextual menu.

pic2

This is where cut and paste (or drag and drop) can become confusing. If I drag the image icon from any folder using Finder (on a Mac) or Explorer (Windows) the image appears in the links and is editable.

pic3

However, if I open Photoshop, select all with my marquee tool, copy and paste (or drag and drop) into InDesign, again no link/edit menu is the result. SO NO GOOD!

pic4

This example is using only one picture, but imagine a parts catalogue or any other picture-rich content that may have this issue.

Disturbingly, it doesn’t show up on the [Basic] preflight profile, nor does it show up as an issue in the package feature.

pic5

However, if use a decent preflight profile such as VIGC_v2.0_Prepare for Sheet CMYK_1v4, it does show up as an error, but only for its resolution and not its colour format.

pic6

Ultimately to avoid this situation, the best solution is to avoid drag/drop or cut and paste between applications.

Data Merging now a headline act

mergeright

The February/March 2013 issue of InDesign Magazine has a new contributor: Me! Yes, this issue has a 12-page special feature about Data Merge, written by yours truly, and features the five essential techniques for using the Data Merge function within Adobe InDesign.

Sadly, no spoilers I’m afraid. If you want to read the article in full, along with all the other useful and must-have information in this issue, you need to go to InDesign Magazine’s site.

Fixing readers spreads: Third time lucky

For print providers, finished art PDFs supplied as readers spreads can create a nuisance. So that the imposition software can correctly impose the pages in the correct order for press, the pages have to be presented as individual pages as opposed to readers spreads. Rather than inconvenience a customer and ask for the file to be prepared again, it is easier to split the PDF into individual pages, but until recently this procedure was a tedious method of copying and pasting a PDF into an InDesign file set as spreads and then preparing an output PDF as individual pages.

However, this blog has provided two solutions so far to do this:

  1. Via two javascripts and a procedure within InDesign (read the full story here);
  2. A javascript within Acrobat (read the full story here)

Now a third method exists. This method uses both Acrobat and an InDesign script.

1)   With the “spreads” PDF open in Adobe Acrobat, save the document as single pages. This can be done (in Acrobat X) by using the split document feature and splitting into 1pp documents;

split

or (in Acrobat 9 or above) by extracting pages as single pages.

extract

Put these PDFs into a folder of their own.

2)   Create a new InDesign file the correct finished trim size, as readers spreads, and the same amount of pages as the intended finished artwork.

3)   Once the file is created, run this script:  A prompt will ask for the folder of PDFs to import – navigate to that folder and click OK.

4)   A prompt will warn once the file is finished. All that is then left to do is tidy up the first and last pages that are centered within the spreads, they only need to be centered within their appropriate pages and any unnecessary pages deleted.

I’m not sure who was the original author of the script but can only credit those who contributed to the forum where the script was adapted for this purpose.

Effects plus live type equals effective VDP

Variable Data Printing (VDP) campaigns can be a great way of not only targeting a particular audience, but also getting their undivided attention. Sadly, much of the marketing utilising the latest and greatest VDP technology to target their audience are still relying on the old-fashioned greeting “Dear your name”.

While this blog isn’t a guide to marketing and nor does it profess to be, I just think that with the technology available in Adobe InDesign’s Data Merge, do VDP campaigns have to be stuck in the 50s style “Mad Men” campaigns?

In the past, the blog has demonstrated how to make contemporary campaigns with salutations displayed as:

  • Pencil-case letters
  • Scrabble letters
  • As part of a cartoon
  • Name badges
  • Street signs

Some of the samples use complex Excel files to break up names into individual letters to create the merge, but others use nothing more than live type to spice up the delivery of the reader’s name. On that note, if type can have an effect applied to it, then any VDP campaign can be taken to the next level.

For this post, I’ve just created a simple example using two live effects: One to look like writing in beach sand, and the other to look like clouds.

beachsplash

Admittedly applying both techniques to one campaign is overkill but the point is to illustrate that so long as effects can be applied to the live type, then creative effects like these can present the reader’s name in a more attention-grabbing fashion. The PDF (that contains all assets that made the PDF) can be downloaded here.

Effects that can be applied to live type are limited in InDesign. Effects such as distortions are limited to type on paths, the gravity effect (as applied on the sample) and the “square peg round hole” trick that can be found elsewhere on this blog. Other effects such as bevel/emboss, outer glows, drop shadows, feathers and satins are still available, as well as how they are applied to the layout such as the multiply effect, screen etc.

One individual who seems to make all text come to life is Mike Rankin who has a regular blog on Lynda.com known as InDesign FX and has other material on the indesignsecrets.com website. Also bringing these campaigns to life is the use of fonts that suit the effect being applied… that is for the beach sand example I decided to use a font that would look like a child’s handwriting as opposed to a serif or sans-serif font that is more appropriate for a letter or book.

I have recently found inspiration from the youtube channel Vsauce that has a regular episode titled DONG: an acronym for Do Online Now Guys. In a recent DONG, host Michael Stevens recommended the site says-it.com, a site for creating one-to-one web to jpg pictures. The site provides ideas – not always original – for VDP campaigns… but sometimes inspiration comes from the strangest places.

The bottom line: targeting a market is one thing, getting their attention is another. InDesign’s Data Merge can be a powerful tool for VDP campaigns, don’t limit communicating with clients with the old and tired “Dear your name” greeting.

When readers should be single… version 2.0

In an earlier post a solution was prepared to create single pages from PDFs supplied as readers spreads. The solution breaks the readers spreads back to single pages via InDesign and two javascripts. While the method works, it’s clunky and not a true turnkey solution to the problem. At the end of the article, there was a link to a post that featured a script available by fellow WordPresser Karl Heinz Kremer, but his solution was not given the attention that it deserved. This is because on first attempts with the script, there were several issues:

  • Acrobat scripts seemed to be harder to install than InDesign scripts;
  • The script kept presenting faults;
  • When the script did work, it seemed to be more appropriate for PDFs that did not contain bleed.
  • The script would not resolve “printers pairs”

However, it paid to persist with Karl’s method because it turns out to be a better solution… with some manipulation.

First thing to do is download the script. It is available from this link.

The first issue to overcome was where to install the script. Different versions of Acrobat on different platforms all have different locations for the script to be installed to. The best advice is to go to any of the online resources that suggest the location for installing the script varied given that it can be a case of trial and error to find the correct location.

Once the location is determined, a minor change may have to be made, depending on the version of Acrobat that is used. In Acrobat X and above, a line in the script has to be changed so that the script can be accessed from the Edit Menu. At the time of writing this article, the script refers to a “Document” menu, that Acrobat X no longer has. To do this, open the downloaded file in a text editor and look for this line:

cParent: "Document",              // this is the parent menu. The file menu would use "File"

now change this line to:

cParent: "Edit",              // this is the parent menu. The file menu would use "File"

 

The next issue to overcome was an error that kept appearing. After some persistence, it seems that the script will only error if the first and last pages are different sizes. In this example, the first page is a different width to the last page in the PDF.

rsfault01

Upon running the script, an error dialog appears.

rsfault02

For the script to work correctly, the first and last pages have to be the same size.

rsfault03

The third issue was that the script seemed to work best for PDFs that did not contain bleed. The reason is that the script works using the Cropbox measurements, but it does not have to. Instead, the script can be changed to use the trim or bleed measurements of the PDF. In the script, look for three lines which look like:

                        var cropRect = newDoc.getPageBox("Crop", i);

and

                                                cBox: "Crop",

this line appears twice.

Now change the word “Crop” to “Trim” and the script will use the Trimbox rather than the cropbox. Similarly, changing the word “Crop” to “Bleed” in these three lines will use the Bleedbox.

Once these amendments to the script are made, the PDF can be successfully split using a more appropriate measurement box. Using the Trimbox is of use to printers given that imposition software tends to refer to these measurements for page imposition but will still retain the original bleed of the file prepared by client.

My final issue was that the script could not fix printers pairs. Again, this is not necessarily true, but it involves more work than a simple click of a menu… but I will save this for another post.

FunDesign from InDesign

While I could sing the praises of InDesign ad infinitum, it is software for creating work… it’s not exactly a Playstation 3 in terms of fun.

There are plenty of ways of goofing-off during work, most involve the internet, smartphones, or both. But is there a way to take a five minute breather from the task ahead, without leaving Adobe InDesign? Well now the answer is yes!

Tetris for InDesign

This popular Russian puzzle game has been available from DTP tools as a free download since the early versions of Creative Suite, and is indeed still available as a free download for both Mac and Windows for versions up to CS6.

Space Invaders for InDesign

Initially a project by Philipp Geuder for the workshop “typography and automation” by Fabian Morón Zirfas, this is more of a demonstration of the power of javascripting rather than an app for entertainment. At the same time, Philipp has done an absolutely amazing job of turning InDesign into an environment to play his take on the popular title “Space Invaders” using only javascripting. While the aim of the workshop was to learn the basics of JavaScript for Adobe applications to apply this in automated layouts and generative art, I think Philipp has missed the mark a little, but clearly demonstrated tremendous scripting talent.

InDesign’s Easter Eggs

There are a few “easter eggs” in Adobe InDesign which have been well documented on the internet, so rather than paraphrase what has been written succinctly  elsewhere, I feel the linked article says it all.

Tomaxxi’s Shortcut Guide

Marijan Tomaxxi is a Graphic Designer, scripter, and certainly a go-to guy in the InDesign community. Based in Serbia, he is the creator of many ingenious scripts which any serious InDesigner should have in their repertoire. Nevertheless, he has created an interactive guide to InDesign Shortcuts (using only Adobe InDesign nonetheless) which, while it isn’t a game, is a lot of fun to prod, click, and draw inspiration from in terms of what can be done with interactivity using only InDesign.

Tomaxxi’s browser within InDesign

Again, Marijan has created his competitor to the likes of Safari, Chrome, Firefox and Internet Explorer – TomaxxiBrowse! OK, sarcasm aside, what Marijan has created is an internet browser which is actually a panel within Adobe InDesign.

These are some brief examples of InDesign being used for recreation rather than work, but if there any others which may be out there, feel free to add them by posting!

Follow

Get every new post delivered to your Inbox.

Join 34 other followers

%d bloggers like this: