[Date Prev][Date Next] [Thread Prev][Thread Next]
[Date Index] [Thread Index] [New search]

Re: Autonumber matrix discussion needs re-posting...



At 12:07 PM 2/19/99 -0800, Snavely, Deborah wrote:
>Does anyone on this list retain one or more copies of previous postings that
>described Sandy Knox's elegant matrix approach to autonumbering?
######################################################################
This is not Sandy Knox's version, but it's an approach I sent to the Framers
list last March.
########################################################################
Here's a more elegant way to specify autonumbering formats
where headings, figure captions, table captions,
equation captions, and page numbers are all prefixed with the
chapter number followed by a hyphen. It handles a number
of problems, including picking up the chapter number as
the page number prefix in a multi-file chapter, and
inserting a cross reference that includes the chapter
number for a source in the second and succeeding files of
a multi-file chapter.

It's quite easy to expand or contract this autonumbering scheme
for cases where the number of heading levels is greater
or less than 3.

Note that all autonumber formats have the H: (heading) prefix.
That is, chapter numbers, heading numbers, figure numbers,
table numbers, and equation numbers are all part of the same
numbering string. This allows the chapter number to always be
available as a prefix to any heading or caption.
It also allows heading, figure, table, and equation counters
to be gang-reset at the beginning of each chapter,
and allows lower-level resets (e.g., for Heading1 and
Heading2 paragraphs).

Note also that this method assures that paragraph numbering
can be set to "Continue" in each file of the book.

Note also that an em-space (\sm)is used to separate the
autonumber from the text that follows the autonumber (the
em-space could be replaced by an en-space or an ordinary
space, and could be preceded by a period or colon, if
required). 

Note also that unaffected and unused counters in the autonumber
string must always appear, using the <> building block, and that
counters are reset using the < =0> building block.

1. Autonumber for ChapTitle paragraph (increments Chapter No.,
   and resets counters for headings, figures, tables, &
   equations). This paragraph appears only once within each
   chapter of a book (i.e., it must not appear in the second
   & succeeding files of a multi-file chapter):

        H:<n+>< =0>< =0>< =0>< =0>< =0>< =0>\sm
            |    |    |    |    |    |    |
            |    |    |    |    |    |    |___Eqn No.
            |    |    |    |    |    |________Tbl No.
            |    |    |    |    |_____________Fig No.
            |    |    |    |__________________Heading3 No.
            |    |    |_______________________Heading2 No.
            |    |____________________________Heading1 No.
            |_________________________________Chap No.

2. Autonumber for Heading1 Paragraph (increments Heading1 counter
   & resets Heading2 & Heading3 counters):

        H:<n>-<n+>< =0>< =0>< >< >< >\sm

3. Autonumber for Heading2 Paragraph (increments Heading2 counter
   & resets Heading3 counter):

        H:<n>-<n>.<n+>< =0>< >< >< >\sm

4. Autonumber for Heading3 Paragraph (increments Heading3 counter):

        H:<n>-<n>.<n>.<n+>< >< >< >\sm

5. Autonunmber for Figure Caption (increments figure counter):

        H:Figure <n>< >< >< >-<n+>< >< >\sm

6. Autonunmber for Table Caption (increments table counter):

        H:Table <n>< >< >< >< >-<n+>< >\sm

7. Autonunmber for Equation Caption (increments equation counter):

        H:Equation <n>< >< >< >< >< >-<n+>\sm

8. Autonumber for ChapNo (empty except for autonumber)
paragraph (default font is 2-pt white to make it invisible):

        H:<n>< >< >< >< >< >< >

The ChapNo paragraph auto-inserts below the ChapTitle paragraph
in the first file of the chapter. If the chapter is broken into
multiple files, the ChapNo paragraph is inserted as the first
paragraph in the second and succeeding files of the chapter,
thereby solving the problem of how to pick up the chapter number
prefix to the page number in the second and succeeding files of
the chapter.

This allows a single version of the Current Page # variable to be
used in all files of a multi-file chapter. The definition for this
variable is:

        <$paranumonly[ChapNo]>-<$curpagenum>

There's another use for the ChapNo paragraph. Suppose you want
to cross-reference from Chpater 5 to a source in the fourth file of
multi-file chapter 3, and you want the cross-reference to specify not
only the text of the source (e.g., "See Installation"), but
also the chapter number (e.g., "See Installation in Chapter 3").
In this case, you certainly don't want to cross-reference the
ChapTitle paragraph in file 1 when the the source is in file 4.
So, you can set up a cross-reference format as follows:

        See <$paratext> in Chapter <paranumonly[ChapNo]>

This will pick up the autonumber of the preceding ChapNo paragraph
in the same file (file 4) that contains the heading "Installation". 






    
     ____________________
     | Nullius in Verba |
     ********************
Dan Emory, Dan Emory & Associates
FrameMaker/FrameMaker+SGML Document Design & Database Publishing
Voice/Fax: 949-722-8971 E-Mail: danemory@primenet.com
10044 Adams Ave. #208, Huntington Beach, CA 92646


** To unsubscribe, send a message to majordomo@omsys.com **
** with "unsubscribe framers" (no quotes) in the body.   **