|
One of the major tasks while completing a book such as Laughing at the Devil is creating the index. If you are fortunate, you will work with a professional indexer at some point, because it takes skill to know what to ignore and what to include. (If you do this yourself, and have never had any training, the question to keep in the forefront of your mind while performing this job is "What will the reader really want to look up?" Place a lot of emphasis on the word 'really' in that sentence, as a neophyte will tend to include too many subjects.)
For those creating their index in Microsoft Word, Seth Maislin's tips at http://taxonomist.tripod.com/indexing/wordproblems.html will be a great boon. (He is one of those professionals, and might be able to help you with that 'really' item in the last paragraph, or possibly more. His site also contains links to help you find other indexers.) In addition to Maislin's tips, the following two tools might also be useful.
The first of these is a macro for finding sequential page numbers. It is helpful in the final task of manually marking page ranges.
In his work, Maislin points out that creating index page ranges in Word can't be done automatically, but it can be done if the individual {XE} fields are manually erased and then replaced with a bookmark range. He also mentions that the index Word creates can be manually edited, but he doesn't recommend doing so because if the index is updated, all the manual labor will be lost.
If your book creation process mirrors my own in any way, your index entries will be started well before your work is completed. (That is because you will mistakenly believe that you are finished when you aren't. Sometimes it takes more rounds of editing than you ever imagined, simply because new information makes its way into your life.) In this case, both methods Maislin outlines are fraught with peril.
The only time to perform manual editing or bookmark ranging of your index is as the very last step of the book creation process. If the bookmarks are created earlier, there is a high probability that the bookmark ranges will not be updated correctly during further edits. There is also the possibility of erasing the beginning or ending of a bookmark range, with unknown, but probably undesirable, consequences.
For these reasons, I recommend leaving the {XE} fields alone and manually massaging the index as the very last step. The index has to be edited anyway, to place "(continued)" on the topics that get split across multiple columns, and if you want your index to conform to style guides such as the Chicago Manual of Style, you must move some "See also" entries to the end of the topic, which Word doesn't do. (The proper order to perform these tasks is to do those outlined on this tip page first, then relocate the 'See also' entries, then place the 'continued's. This makes it unnecessary to continually move the 'continued's around when the collumns wrap in different places because of the other changes.)
To facilitate this manual editing, the following macro searches for sequential numbers starting from the current cursor location. When it finds a sequential pair, it highlights the second number and exits from the macro. At that point you can quickly change what needs to be changed. In some cases this may be nothing, as the macro doesn't search for text between the entries, so a scenario like "topic1...12 / topic2...13" will highlight the '13'.
In other cases, simply select the commas and digits that are unnecessary and type 'Ctrl' + '-' on the keypad (assuming a Windows US keyboard layout). This inserts the correct en-dash, so an entry like "topic1...28, 32, 33, 34, 40" becomes "topic1...28, 32–34, 40."
Before running this macro for the first time, it is necessary to open Word's 'Find' box, enter "[0-9]{1,3}" as the find text, check the 'Use wildcards' option, and perform a single search to get these options into Word's memory. Don't ask me why that had to be done (nor how much frustration ensued while determining this fact!). After doing that, simply place the cursor at the top of the index (or wherever you want to start searching from) and run the macro. To make this process quicker, keep the macro editor open as a small window on your screen and hit its 'Run' button to proceed to the next instance after making an index change. It also helps to have Word non-maximized so that both windows are visible at once.
I have seen cases in which this process wouldn't find sequential numbers, due to some bug deep within the bowels of MS Word, but closing and reopening the macro editor fixed that problem.
Here is the macro:
Sub FindSequentialNumbers()
'
' FindSequentialNumbers Macro
' Macro recorded 8/4/2008 by David O'Neil
' After creating a macro called 'FindSequentialNumbers,' copy the following lines into it:
'
Dim TextToFind As String ' number pattern to search for
Dim FirstPatternStringFound As Range ' first number pattern string found
Dim FirstNum As Double ' first number found
Dim SecondNum As Double ' second number found
Dim startRge As Range 'To save initial selection
TextToFind = "[0-9]{1,3}"
Set startRge = Selection.Range
Application.ScreenUpdating = False
With Selection.Range.Find
.Text = TextToFind
.Forward = True
.MatchWildcards = True
End With
Do While Selection.Find.Execute
If FirstPatternStringFound Is Nothing Then
Set FirstPatternStringFound = Selection.Range
Else
FirstNum = FirstPatternStringFound
SecondNum = Selection.Text
If SecondNum = FirstNum + 1 Then
StatusBar = "Pattern Matched"
Exit Sub
End If
Set FirstPatternStringFound = Selection.Range
End If
Loop
startRge.Select
Application.ScreenRefresh
Application.ScreenUpdating = True
' End copy
End Sub
The other tool is for those who use '...' to separate the index entry from the page numbers, as I have (scroll to the end of that PDF to see the index). You will see that Word sometimes uses single dots in those locations. To me, that looks terrible, and if you agree, and want to get rid of those isolated dots, the only way I found to accomplish that was to make a PDF of the index using Adobe Acrobat (or whatever PDF creation tool you have available) and then copy/paste that PDF text into a new Word document. In the copy, do a search for "[!.].[!.]", again selecting the 'Use wildcard' option.
This will find all instances of isolated dots in that document. It is necessary to then add a space or two before the 'tab' that is at that location in the original document. (That is assuming it is an unwanted dot, and not a period that follows an abbreviation, such as 'Dr.'.) After all the instances have been massaged in this manner, it is a good idea to repeat the process to make certain that the 'spaces' of the spaces have really gotten rid of the extraneous dots.
I've read that the newest version of Word opens PDFs, making the 'copy/paste' step unnecessary – just open the created PDF with Word.
As you can tell, Word is not a wonderful tool for creating indexes, but it is good enough to get the job done. I hope that you find these tips useful in that endeavor.
Comments? Post them here.
|