Skip navigation
Currently Being Moderated

cross-references and list levels

Aug 29, 2009 3:57 PM

I write documents in which there are numbered series of examples. Sometimes there's only one example to a number, sometimes two or three, in which case letters are used to sub-classify. So I might have this:

 

on page 1,

 

(1) blah blah blah

 

but a few pages later

 

(2)     a. yada yada

          b. yada yada yada

 

and so on. I have two questions.

 

(A) What's the best way of setting up the paragraph styles for this? At the moment I'm thinking that I want a single list, Examples, and three para styles, one for paras like (1) above, one for (2a), and one for (2b) (where the "2" shouldn't appear on the line).

 

(B) How do I get cross-references to work? I can do them easily enough for "(1)", but I'm not sure about "(2a)" or "(2b)" (in the x-ref, the "2" does appear with the "b"). To make things more interesting, the parens and the letter in the x-ref are to be in the regular para font, but the number will be an old-style figure.

 

Any pointers gratefully received.

 

Graeme Forbes

 
Replies
  • Currently Being Moderated
    Aug 30, 2009 2:03 AM   in reply to Graeme Forbes

    You won't be able to do the subnumbering you want for your example sentences in a straightforward way. This is easy:

     

    (1)   Axcvbx cb
            a.  Ccxvb
            b.  Dcvcvxb

     

    But this is a bit more complicated:

     

    (2)   a.  Ccxvb
            b.  Dcvcvxb

     

    You need three numbered paragraph styles for this. One style deals with numbers, so you'd set this:

     

    (1)  Abcdef
    (2)

     

    The second style is for the subnumbers of level a. In the style you set the required left indent, set the number style, set "Start at" to 1, and set leading to 0. Setting the leading to zero will move the line up, so that

     

    (2)  
            a.  Ccxvb

     

    Will be displayed as

     

    (2)   a.  Ccxvb

     

    What looks like one paragraph is therefore in fact two separate paragraphs stacked on each other.

     

    The third paragraph style is for subnumbers b. and following. It is based on the a-subnumbers; the only difference is that "Start at" should be set to "Contuinue from previous" and leading set back to whatever the leading normally is in the examples.

     

    It's fairly easy to set up. To use it, you can either set a paragraph style's "Next style", though I think that that works only when you're typing. Otherwise a script can quicly apply the styles.

     

    Cross-references to such paragraphs need some setting up, too. When you include both parentheses in the paragraph style's numbering, any cross-reference to that number will always have the parentheses tight against the number. References to subnumbers would therefore always have the subnumber outside the parens: (2)a -- you can't insert anything between the number and the closing parenthesis.

     

    To get around this, in the paragraph style's number format use just the opening parenthesis, so that your examples will look like this with just the styles applied:

     

    (1   Axcvnb
    (2   a.   Bzxg
          b.

     

    Cross-references to those numbers now look like (1 and (2. To create a cross-ref to a sub-number, you need to create two cross-references: one to the main number (2, the other to the sub-number. Finally, add the closing parens to the example numbers and the cross-references manually. A script could sort that out quickly.

     

    At this stage you might wonder if it's worth the trouble... (A detailed description of numbered paragraph styles and x-refs is at http://blogs.adobe.com/indesigndocs/2009/04/)

     

    Peter

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 30, 2009 2:18 AM   in reply to Graeme Forbes

    > References to subnumbers would therefore always have the subnumber outside the parens: (2)a -- you can't insert anything between the number and the closing parenthesis

     

    I just noticed that that's not true. When you include the closing parens in the paragraph style's number format, which would create cross-references of the form (2), you can indeed insert text between "2" and ")" -- but not another cross-reference, unfortunately. So you need to create a cross-ref of the form (2)a and then swap ")" and "a".

     

    Peter

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 30, 2009 2:38 AM   in reply to Peter Kahrel

    "Look before you leap." (Confusius)

     

    You have to include the ) in the paragraph style's number format because you can't enter it manually, so the form of the cross-reference is always (2)b. Now you can delete ")" and insert a ) after "b". But each cross-reference update will insert ")" after the number again, so after each update you need to move ")" and subnumber.

     

    Peter

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 31, 2009 1:50 AM   in reply to Graeme Forbes

    Graeme,

     

    >as soon as you delete the paren the x-ref  becomes "unresolved" and presumably won't update correctly

     

    No, they're updated correctly, but the parens are re-inserted by the update so you'd have to remove them again.

     

    >the real paragraph number for the numbered paras is a simple numeral, it goes at the end of the paragraph, is in a tiny point size, and is set to Invisible

     

    I thought of that, too, and it's probably a better way to go. To make you life a bit easier, use a character style for those dummy numbers and use "Paper" for colour (probably combined with tiny point size). When you use a character style and when at some stage you wonder which examples have xref targets and which not, then you simply change the character style to use black and all your dummy numbers become visible. The only drawback is that those dummy numbers are static, so that when you add or remove example sentences, the dummy numbers bear no relation any longer with the real numbers. But that's always a problem, Frame and Latex have that, too.

     

    Use character styles for the xrefs, too. It then becomes easy to find these and to format them using a script.

     

    Because of all this hassle I gave up on using xrefs long ago and returned to static numbers.

     

    Peter

     
    |
    Mark as:
  • Currently Being Moderated
    Aug 31, 2009 1:19 PM   in reply to Graeme Forbes

    IIRC, DTP Tools' cross-reference plug-in for ID can do the FM-like "look before the x-ref for the last instance of a different style" behavior. dtptools.com

     

    HTH

     

    Regards,

     

    Peter Gold

    KnowHow ProServices

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 1, 2009 12:29 AM   in reply to Graeme Forbes

    > I hope I'm misunderstanding this. I don't see why the dummy numbers, i.e., the *real* autonumbers at the end of the paragraph, wouldn't update properly

     

    There's only one place for the automatic paragraph number, and that's the beginning of the paragraph. Unfortunately, you can't have a setup where you get the number at the beginning and a copy of the number at the end of it. So that's the end of that idea.

     

    Please keep us informed on what you find about the DTP Tools.

     

    Peter

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 1, 2009 9:22 AM   in reply to Graeme Forbes

    GREP styles can be used to apply character styles to text you find using GREP expressions -- you can't change anything in the text you find (like deleting or inserting text) so that's no good for you. But what you can do is a simple GREP find/replace. Assuming you set the xref format to use a character style called "xref", do as follows to sort out cross-references of the form (2)a:

     

    Find what: \)(\l)

    Change to: $1)

     

    And set the xref character style in the Find Format pane. Then do "Replace All" and store the contents of the Find/Change dialog as a query on disk. The GREP expressions say "Find ) followed by a lower-case letter and when both have char. style "xref", swap them."

     

    Peter

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 18, 2009 5:41 AM   in reply to Graeme Forbes

    Graeme Forbes wrote:

     

    So  finally I got an authoritative answer from DTP Tools, Their Cross References Pro plug-in does indeed have a FrameMaker-style "look back to the previous paragraph of style such-and-such" building block. It's "<paranum precedingpstyle="stylename" numberonly="true"/>". It's a pity they don't have  --- or at least I couldn't find -- an exhaustive list of their building-blocks anywhere on their website, or I'd have arrived at a solution a lot faster. Anyway, even tho' I could get the xrefs I want just using ID CS4's capacities, as I described in the previous post on this thread, the method's a bit ofa kludge and you need use "insert xref" twice to build, e.g., "(2c)" from "(2" and "c)". The plug-in is much better, and should also smooth conversion of old FM docs to ID, when I eventually get around to that.

    Hi, Graeme:

     

    The precedingstyle building block is noted on page 17 of the Cross-References User Guide that's downloadable from this page:

     

    http://www.dtptools.com/product.asp?id=crin

     

    It's the last link at the bottom of the page.

     

    HTH

     

    Regards,

     

     

    Peter

    ______________________

    Peter Gold

    KnowHow ProServices

     
    |
    Mark as:
  • Currently Being Moderated
    Sep 18, 2009 12:27 PM   in reply to Graeme Forbes

    Graeme Forbes wrote:

     

    Thanks, Peter. Thought I'd read that page.

     

    Graeme

    I suggested making a list to dtptools folks.


    Regards,

    Peter Gold
    KnowHow ProServices

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points