Footnote assembly management4503515Abstract A method of, and system for, managing assembly and formatting of footnotes and body text. Following preparation and separate storage of both body and footnote text, assembly of the footnote text with the body text can be accomplished in one pass for a review of the appearance of the document in its to-be-printed format. Two techniques are available for assembly of the document. The technique selected will be the one which will provide optimum performance and will be determined by the amount of footnote text being assembled and/or the body and footnote text edited. If any editing is performed, the new and/or edited footnote text can be re-assembled in one pass. Claims We claim: Description DESCRIPTION
TABLE 1
______________________________________
FOOTNOTE FORMAT ROUTINE
______________________________________
BEGIN (FN FMT)
INITIALIZE WORK SPACE AND CONTROL BLOCKS
COPY CURRENT VALUE OF ALL MENU OPTIONS
INITIALIZE DFD (DYNAMIC FRAME DESCRIPTOR)
WITH MENU OPTION VALUES
UNTIL MENU IS SUCCESSFULLY EXITED OR
CANCELLED DO DISPLAY FOOTNOTE FORMAT MENU
UNTIL MENU MANAGER RETURNS
VALIDATE/COMPARE VALUES
IF THE "CHANGE FOOTNOTE TYPING OPTIONS"
DIRECTIVE OPTION WAS SELECTED THEN
DISPLAY FOOTNOTE TYPING OPTIONS MENU AND
SAVE OPERATOR INPUT FOR LEADING/TRAILING
CHARACTERS AND "FOOTNOTE CONTINUED" TEXT
ELSE
IF A PARAMETER CONFLICT EXISTS THEN
POST OPERATOR MESSAGE
ELSE
INDICATE FOOTNOTE FORMAT MENU HAS
SUCCESSFULLY EXITED
ENDIF
ENDIF
ENDDO
FREE WORK SPACE
RETURN
END TABLE 1 (FN FMT)
______________________________________
FOOTNOTE FORMAT If a "Change Footnote Format" option is selected in a Format Selection menu presented to the operator for any number of tasks, then the system displays a Footnote Format menu as shown in MENU 1 below. The Footnote Format is a part of both the Document and Alternate Document Format of the document. The Document and Alternate Document Format are two independent sets of formats which the operator may begin using at the top of any page in the document. Unless specified otherwise, the system defaults to the Document Format.
______________________________________
MENU 1
______________________________________
Chg Document Fmt
Brief Ins
DSK001 Kyb 1 Pitch 12
______________________________________
FOOTNOTE FORMAT
YOUR POSSIBLE
ID ITEM CHOICE CHOICES
______________________________________
a Typestyle Number 1-31 (10 Pitch)
80-111 (12 Pitch)
154-175
(Proportional)
215-230 (15 Pitch)
b Separator Character
-- Any available
character
c Number of Separator
20 1-450
Characters
d Maximum Number of
48 1-999
Footnote Text Lines
Per Page
e Number of Lines
0 0-999
Between Footnotes
f Footnote Numbering
1 1 = Document
2 = Page
g Footnote Numbering
Graphic Any available
character, or none
h Footnote Placement
2 1 = Document
2 = Page
i Change Footnote
Typing Options
When Finished with this menu, press ENTER.
Type ID letter to choose ITEM; press ENTER:
______________________________________
Each ITEM in MENU 1 is briefly described below. Typestyle Number: A plurality of choices of fonts including a variety of typestyles and pitches are available from MENU 1. Both typestyle and pitch are determined by a Font ID selected by the operator from POSSIBLE CHOICES. If no ID is specified, the system will use a Line Format typestyle default value. Separator Character: Any graphic character available on a selected font can be specified or selected by the operator to form a separator line separating body and footnote text. Number of Separator Characters: The operator can specify the number of characters to be used in making up the separator line. The number will only be measure limited. It is to be noted that a blank line will always precede and follow the separator line. Maximum Number of Footnote Text Lines per Page: The number specified by the operator will be the maximum number of lines available at the bottom of the page for footnote text. Included with this number will be a specified number of lines between footnotes. Not included in the specified number are the blank lines before and following the separator line, the separator line, and a dedicated line at the bottom of the page. Although not included in the maximum number of footnote text lines, these lines are included in the total page line count. Number of Lines Between Footnotes: The operator can specify the interfootnote line spacing for formatting purposes to improve aesthetics. Footnote text will always be single spaced. Footnote Numbering: An operator can specify whether or not footnote numbering is to be reset at page boundaries. Footnote Numbering Graphic: If footnote numbering is to be reset at page boundaries and a non-numeric graphic character such as an asterisk is specified, the first footnote will be numbered "*", the second will be numbered "**", etc. Footnote Placement: The operator can specify whether or not footnotes are formatted and placed at the bottom of each page or the end of the document. Range: 1=Yes 2=No Following selections from MENU 1 and depression of the ENTER key, a Footnote Typing Options Format menu will be presented to the operator. This is illustrated below as MENU 2 wherein choices are available for the fixed portion of both footnote and footnote reference designations. The type of the variable portions of the footnote and footnote reference designations is selected from MENU 1.
______________________________________
MENU 2
______________________________________
Chg Document Fmt
Brief Ins
DSK001 Kyb 1 Pitch 12
______________________________________
FOOTNOTE TYPING OPTIONS
YOUR POSSIBLE
ID ITEM CHOICE CHOICES
______________________________________
For Body Text:
a Leading Characters
"1/2 INX UP" Up to 8
characters,
or none
b Trailing Characters
"1/2 INX DOWN"
Up to 8
characters,
or none
For Footnote Text:
c Leading Characters
"1/2 INX UP" Up to 8
characters,
or none
d Trailing Characters
"1/2 INX DOWN"
Up to 8
characters,
or none
e `Continued Footnote`
(Footnote Continued)
Message Characters
When finished with this menu, press ENTER.
Type ID letter to choose ITEM; press ENTER:
______________________________________
An explanation of each ITEM listed in MENU 2 is set out below. Leading Characters: These characters include both controls and graphics to be generated by the system immediately before the variable portion of the footnote and footnote reference designation both in body and footnote text. Trailing Characters: These characters include both controls and graphics to be generated by the system immediately after the variable portion of the footnote and footnote reference designation both in body and footnote text. `Continued Footnote` Message Characters: Any character, tab, indent tab, space, required space, required backspace, or word underscore can be selected for system placement (1) following the last footnote line on a page, and (2) before the first footnote line on the next page when a footnote "spills over" from one page to the next. When the operator completes entry of all desired choices and depresses the Enter key against a prompt to type the ID to choose an item displayed on the Prompt Line, the system will update the Document or Alternate Format of the document with the values selected by the operator and re-display the Format Selection menu. Following the above set up routine, the operator is now ready to begin preparing a footnoted document. Footnotes are created during the normal Create/ Revise Document task via a Footnote instruction. When the operator selects "Footnote" from an Instruction Menu and depresses the Enter key, a Footnote Menu illustrated below as MENU 3 will be presented.
______________________________________
MENU 3
______________________________________
Create Document
Brief Ins
DISK01 Pg. 1 Ln. 13 Kyb 1
______________________________________
FOOTNOTE
YOUR POSSIBLE
ID ITEM CHOICE CHOICES
______________________________________
a Create/Revise 1 1 = Yes
Footnote Text 2 = No
b Reset Footnote Number
or Character
c Document Name
d Diskette Name
e System Page Number
When finished with this menu, press ENTER.
Type ID letter to choose ITEM; press ENTER:
______________________________________
The ITEMS against which the operator makes choices are described below. Create or Revise Footnote Text: Operator selection here is for calling a blank Footnote Typing Frame illustrated as FRAME 1 later herein if typing a new footnote is in order, or a Footnote Typing Frame with an existing footnote as illustrated in FRAME 2 later herein in order for the operator to make revisions. Reset Footnote Number or Character: This option is selected whenever the operator desires to override the automatic system-generated sequence of footnote numbering or designations (i.e., 1, 2, 3, . . .) by specifying a specific number or other graphic character or characters. If a number is entered, then footnote numbering by the system will be reset to that value. If a graphic is entered, when the automatic sequencing of numeric values will be suspended until the next "null" or numeric value is encountered. The following two items should only be selected if footnotes are to be stored in a document other than the editing document. Document Name: Selection here is to (1) store footnote text to be created, (2) locate footnote text to be revised, or (3) locate existing footnote text to be included in the document. Diskette Name: The name of the diskette on which the above document resides is entered by the operator. System Page Number: An entry here is for calling a page which contains the footnote text. If both the Document Name and Diskette Name are blank, then the system will assume that footnote text is to be stored with the document being created or edited. The system will store the footnote text on the next available page on or above 9000 (i.e., 9000, 9000.0.1, 9000.0.2, . . . ) and after existing footnote pages. If the operator specifies another Document Name/Diskette Name, then any page number of that document may be used to store the footnote text. If no page number is specified, then the first available page will be used. The operator may also specify that a particular existing page number be used by selecting this ITEM and entering the page number. The Footnote Instruction thus created in memory will have the following makeup: (1) Footnote Reference Control (FTR) followed by the following controls: (2) Begin Formatted Text Control (BFT) (3) Leading characters (4) Footnote number (5) Trailing characters (6) End Formatted Text Control (EFT) The BFT/EFT control pair is used by the system to identify data that was generated by the system and may be later updated or modified by the system. The value of the footnote number itself may be: (1) Sequentially assigned by the system when the footnote instruction is created (and prior to assembly for merging and paginating the footnote and body text). (2) Explicitly assigned by the operator when the footnote instruction is created. (3) Determined by the system during the assembly operation. As a result, a footnote number (together with any leading and/or trailing characters) will always appear in the body text after a footnote instruction is created. Upon revising a footnote instruction, the Footnote Instruction can be altered by placing the cursor on the Footnote Instruction and pressing the Enter key. The Footnote Menu (MENU 3) will be recalled. During creation or revision of footnote text, if "Create or Revise Footnote Text" is set to "Yes" in the Footnote Menu (MENU 3), a Footnote Typing Frame (Frames 1 and 2) will be displayed when the ENTER key is depressed.
______________________________________
FRAME 1
(Footnote Typing Frame - Create)
______________________________________
Create Footnote
Brief Ins
DISK01 Pg. 1 Ln. 13
Kyb 1 Pitch 12
______________________________________
When finished, press ENTER.
______________________________________
The format of the footnote text and the page presentation characteristics for footnotes are determined by the Document or Alternate Format and the Footnote Format. After the footnote and body text have been assembled, the footnote text will always be single spaced regardless of the line spacing of the body text. The Context Field on the First Status Line of the Footnote Typing Frames will display either "Create Footnote" or "Revise Footnote", as appropriate. In order to create a reference to an already existing footnote, operator procedure is to specify the diskette name, document name, and page number for the footnote and set "Create or Revise Footnote Text" to "No" in the Footnote Menu (MENU 3). After the operator has specified the document name and diskette name the first time a footnote was included, the default will be the previous document and diskette name used. During document assembly, body text and footnote text was resolved. Resolution requires combined pagination and merge operations if both body and footnote text are to appear on the same page. Footnote text is formatted for output to a display for review or to a printer by either a Paginate Document task, a Merge task, or a Paginate/Hyphenate option of a Check Document task. The Paginate Document task will assemble the document to permit the operator to view the pages of the document made up of body and footnote text exactly as it will be printed. The makeup of the footnote text at the bottom of the page will be: Begin Formatted Text Control (BFT) Line Format Change (to set footnote format) Begin Keep Control Required Carrier Return (for blank line above separator line) Separator line, Required Carrier Return Required Carrier Return (for blank line below separator line) Footnote Text Line Format Change (to return to format prior to footnote) "n" number of indent tabs (where "n" is determined from the indent level at the Begin Formatted Text control). End Keep Control End Formatted Text Control (EFT) The footnote reference number or other designation in the body text will be used to determine the footnote number or other designation to be printed and displayed. The system will automatically insert footnote designations together with any leading and trailing characters at the beginning of the footnotes automatically during assembly only. Ordinarily, the system will assign footnote numbers in sequential order. However, if the operator has specified that a particular number be used, the system will assign that number to the footnote, and subsequent system assigned numbers will be determined using that number as a base. Automatic sequencing may be interrupted by the presence of non-numeric footnote reference designations. The next numeric footnote reference will resume the automatic sequencing by the system. If footnotes are inserted, moved, or deleted from the assembled document, then the document must be reassembled to renumber the footnotes. Table 2 describes the routine performed by the assembly supervisor 100. This is the main routine that controls the pagination and merge operations. This main routine (DOCPA) invokes other routines to adjust lines, make page ending decisions, and process, format, and renumber footnotes.
TABLE 2
______________________________________
BEGIN (DOCPA)
OBTAIN FORMATTING INFORMATION FOR
DOCUMENT
INITIALIZE CONTROL BLOCKS AND WORK AREAS
GO TO STARTING PAGE
IF PRESERVE PAGE ENDINGS IS NOT INDICATED
THEN UNTIL END OF DOCUMENT OR CANCEL
PRESSED DO
IF READJUSTING LINE AND A FOOTNOTE WAS
ENCOUNTERED ON THAT LINE THEN
INVOKE (FNNUM) - UPDATE/INSERT FOOTNOTE
NUMBER IN BODY TEXT
ENDIF
IF SPELL-ASSISTED HYPHENATION IS ON THEN
PERFORM SPELLING-ASSISTED HYPHENATION WITH
LINE ADJUST
ELSE
PERFORM LINE ADJUST
ENDIF
IF THE LINE IS NOT TO BE READJUSTED THEN
CALL (LINEPOS) TO DETERMINE IF LINE POSITION
CAUSES A PAGE END DECISION
IF PAGE END DECISION THEN
DETERMINE LOCATION OF PAGE END
ELSE
IF LINE END CODE IS A PE OR RPE THEN
INDICATE PAGE END DECISION
ENDIF
ENDIF
IF PAGE END DECISION THEN
CALL (PAGEEND) TO INSERT A PAGE END AND
INCREMENT THE POINT OF OPERATION TO NEXT
PAGE
ELSE
INCREMENT PAST LINE END CODE
ENDIF
ENDIF
ENDDO
INVOKE (EDOC) - FOOTNOTE END OF DOCUMENT
PROCESSOR
ENDIF
CLEANUP AFTER TERMINATING PAGINATE
CLEANUP FOOTNOTE PROCESSING
FREE WORK AREAS
END TABLE 2 (DOCPA) RETURN TO CALLER
______________________________________
Table 3 describes a subroutine (LINEPOS) of the routine DOCPA. This subroutine calculates the positional change caused by line ending codes. The paginator (DOCPA) uses this information in determining where to make page ending decisions. The subroutine (LINEPOS) also invokes a routine (RSOLVE) to fetch and resolve footnote text.
TABLE 3
______________________________________
BGNPROC (LINEPOS)
DETERMINE LINE POSITION CHANGE
IF THE LINE END CAUSES THE LINE POSITION TO
CHANGE THEN UPDATE THE LINE POSITION CHANGE
BY THE LINE SPACING
SAVE LINE SPACING
ENDIF
OBTAIN THE LINE DENSITY FOR 1 LINE
SAVE THE LINE DENSITY FOR THE LINE SPACING
CALCULATE AND SAVE THE LINE POSITION CHANGE
AT THE END OF THE LINE
IF A FOOTNOTE REFERENCE WAS ENCOUNTERED
ON THE LINE THEN
INVOKE (RSOLVE) - RESOLVE FOOTNOTE INTO THE
FOOTNOTE BUFFER
ENDIF
IF FOOTNOTE ROUTINE WANTS PAGE END DECISION
THEN SET PAGE END DECISION
ENDIF
ADD LINE POSITION ESCAPEMENTS TO PENDING
FOOTNOTE ESCAPEMENTS
DETERMINE NUMBER OF LINES FROM BOTTOM
OF PAGE
DETERMINE NEW LINE POSITION
ENDPROC TABLE 3 LINEPOS
______________________________________
Table 4 describes a subroutine (PAGEEND) of the routine DOCPA that makes page ending decisions by inserting a page end code into the document TSB 240. Prior to inserting the page end code, the subroutine (PAGEEND) invokes a routine (EPAG) to process and insert all footnote text accumulated in the formatted footnote TSB 140 or stored on diskette unit 24 into document TSB 240.
TABLE 4
______________________________________
BGNPROC PAGEEND
IF THERE IS PENDING FOOTNOTE TEXT THEN
INVOKE (EPAG) - FOOTNOTE END OF PAGE
PROCESSOR
ENDIF
IF NOT A PAGE END CODE THEN
INSERT THE PAGE END CODE
ELSE
MOVE ACROSS PAGE END
EXIT IF END OF TEXT PAGES
MOVE TO START OF TEXT ON NEXT PAGE
ENDIF
IF PRINT INDICATED THEN
PRINT PAGE
ENDIF
ENDPROC TABLE 4 PAGEEND
______________________________________
Table 5 describes the routine (FNNUM) which determines the type of footnote numbering or designations to be used and when to reset and/or increment the numbering or designations.
TABLE 5
______________________________________
BEGIN (FNNUM)
IF FOOTNOTE REFERENCE RESETS THE FOOTNOTE
NUMBERING THEN
RESET THE FOOTNOTE COUNTER TO THE SPECIFIED
VALUE
INSERT THE COUNTER INTO THE BODY TEXT
ELSE
IF THIS IS THE FIRST FOOTNOTE OF THE DOCUMENT
AND NUMBERING IS NOT BEING DONE ON A PER
PAGE BASIS
THEN
SET THE FOOTNOTE COUNTER TO 1
INSERT THE COUNTER INTO THE BODY TEXT
ELSE
INCREMENT THE FOOTNOTE COUNTER
IF THIS IS THE FIRST FOOTNOTE OF A PAGE AND
NUMBERING IS BEING DONE ON A PER PAGE BASIS
THEN SET THE FOOTNOTE COUNTER TO 1
ENDIF
IF FOOTNOTE GRAPHIC NUMBER IS NOT SPECIFIED
THEN
INSERT THE COUNTER INTO THE BODY TEXT
ELSE
SET I = FOOTNOTE COUNTER
DO UNTIL I = 0
INSERT FOOTNOTE GRAPHIC
I = I - 1
ENDDO
ENDIF
ENDIF
ENDIF
END TABLE 5 (FNNUM)
______________________________________
The routine RSOLVE in Table 6 is invoked by the paginator routine (DOCPA) if the footnote placement is specified to be "bottom of page" not "bottom of document". If the footnote placement is specified to be "bottom of document", then resolution occurs in the routine EDOC. Its function is to resolve one or more footnote reference controls that the paginator encountered after adjusting the cursored body text line during document pagination. Note that the paginator (DOCPA) invokes this routine only after completing the line adjustment of the cursored line and additionally determining that the cursored line will fit on the current page. This routine: (a) insures that the footnote format values are in a range that will enable feasible resolution. These include the maximum number of footnote text lines, and the number of blank lines between footnotes, (b) determines whether the current page is to be terminated prematurely. This occurs when the first footnote text line for the footnote reference that is being processed will not appear on the same page as its reference. This usually occurs when there is enough footnote text pending such that the maximum number of footnote text lines is surpassed, (c) resolves the footnote references encountered on the current line via the invocation of routine GETFN to fetch and resolve each footnote reference.
TABLE 6
______________________________________
BEGIN (RSOLVE)
IF THERE ARE FOOTNOTES TO RESOLVE FOR THE
CURRENT LINE THEN
IF AT LEAST ONE MORE FOOTNOTE TEXT LINE WILL
FIT AT THE BOTTOM OF THE CURRENT PAGE BEING
PAGINATED THEN
IF THE RESOLUTION ALGORITHM TO BE USED IS THE
LIMITED TSB ALGORITHM THEN
INITIALIZE THE FORMATTED FOOTNOTE LIMITED
TSB
INVOKE GETFN - RESOLVE/FORMAT FOOTNOTES ON
THIS LINE
IF THE FORMATTED FOOTNOTE LIMITED TSB
BECAME FULL THEN
RESTORE POINT OF OPERATION TO THE FIRST
FOOTNOTE OF THIS PAGE
RE-INITIALIZE PARAMETERS FOR THE FIRST
FOOTNOTE OF THIS PAGE
INVOKE GETFN - RESOLVE/FORMAT FOOTNOTES ON
THIS LINE USING INDEFINITE LENGTH ALGORITHM
ENDIF
ELSE
INVOKE GETFN - RESOLVE/FORMAT FOOTNOTES ON
THIS LINE USING THE INDEFINITE LENGTH
ALGORITHM
ENDIF
ELSE
INDICATE PREMATURE PAGE TERMINATION DUE TO
INSUFFICIENT ROOM AT THE BOTTOM OF THE PAGE
FOR ONE MORE FOOTNOTE TEXT LINE
ENDIF
ENDIF
RETURN
END TABLE 6 (RSOLVE)
______________________________________
The routine GETFN in Table 7 is invoked by the routine RSOLVE to perform the actual resolution of footnote references. Its function is to resolve each footnote reference control that the paginator encountered after adjusting the cursored body text line. It is already assumed that there is room at the bottom of the page for at least one more footnote text line and that the footnote placement is the bottom of page, not bottom of document. Resolution is performed one of two ways: If all of the footnotes on a page can be copied and formatted into the formatted footnote TSB (140), then the limited footnote algorithm is used. This method does a minimal amount of diskette accessing and performs almost all processing in memory. The result is fast formatting and resolution of each footnote reference since all of the formatted footnotes will be in memory when the routine EPAG is called at the end of the page to insert the footnotes at the bottom of the page. This method is used most of the time for footnote placement at the bottom of a page unless very large footnotes are being processed. If not all the footnotes on a page will fit into the formatted footnote TSB 140, then the indefinite footnote algorithm is used. This involves storing the current body text page back onto the diskette unit 24 and moving the TSB point of operation to the page that contains the footnote text to be formatted and resolved (even if the page is an in another document). Once the footnote is formatted it is stored back onto the diskette and the TSB point of operation is moved back to its original point in the body text page. With this approach the routine EPAG will fetch the footnote text from diskette unit 24 to the bottom of the page. Resolution typically involves the following items: Formatting the footnote text based on the active footnote format. This implies that the Document or Alternate Document Format (whichever is active) will be scanned in order to obtain the parameters required to format the footnote text correctly. Inserting the appropriate footnote number bracketed within a BFT/EFT control sequence with the appropriate leading/trailing text and/or controls prior to the footnote text. Calculating the number of footnote text lines corresponding to the footnote reference being processed. Updating the number of pending footnotes on the current line to be inserted. Calculating the total vertical escapement due to footnote text that is to be inserted at the bottom of the page. This value is used by the paginator in its page ending decision logic.
TABLE 7
______________________________________
BEGIN
OBTAIN ADDRESSABILITY TO THE FIRST FOOTNOTE
REFERENCE TO BE RESOLVED
UNTIL THERE ARE NO MORE FOOTNOTES TO BE
RESOLVED DO
IF PERFORMING LIMITED RESOLUTION AND BLANK
LINES MUST BE INSERTED TO DELIMIT THIS
FOOTNOTE THEN
INSERT THE BLANK LINES VIA PROGRAM SEGMENT
BLANK.sub.-- LN
ENDIF
COPY THE FOOTNOTE TEXT INTO THE LIMITED TSB
AND DETERMINE THE NUMBER OF FOOTNOTE TEXT
LINES VIA THE PROGRAM SEGMENT COPY.sub.-- FN
IF PERFORMING LIMITED RESOLUTION AND THE
ENTRY COULD NOT BE RESOLVED SUCCESSFULLY
THEN
INSERT INTO THE LIMITED TSB THE APPROPRIATE
ERROR MESSAGE
ENDIF
OBTAIN THE NUMBER OF LINES FOR THIS FOOTNOTE
REFERENCE
CALCULATE THE VERTICAL ESCAPEMENT THAT
WILL BE GENERATED FOR THE FOOTNOTE TEXT
LINES CORRESPONDING TO THIS FOOTNOTE
REFERENCE
UPDATE THE TOTAL VERTICAL ESCAPEMENTS
FOR ALL FOOTNOTES ON THIS PAGE
SETUP TO PROCESS THE NEXT FOOTNOTE
ENDDO
UPDATE THE ESCAPEMENT VALUES FOR THE
PAGINATOR VIA PROGRAM SEGMENT UPDATE
SET AN APPROPRIATE EXIT RETURN CODE
RETURN
BEGSEG (BLANK.sub.-- LN)
DETERMINE HOW MANY BLANK LINES MUST BE
INSERTED TO PROVIDE FOOTNOTE SPACING
IF THE PREVIOUS FOOTNOTE DID NOT END WITH
A LINE ENDING CONTROL THEN
INSERT A REQUIRED CARRIER RETURN TO FORCE
THE POINT OF INSERTION FOR THE BLANK
DELIMITER LINES TO THE START OF A LINE
ENDIF
UNTIL ALL THE BLANK LINES ARE INSERTED INTO
THE LIMITED TSB BUFFER DO
INSERT A REQUIRED CARRIER RETURN PRIOR TO
THE POINT OF OPERATION
ENDDO
ENDSEG (BLANK.sub.-- LN)
BEGSEG (COPY.sub.-- FN)
IF PERFORMING LIMITED FOOTNOTE ALGORITHM
RESOLUTION THEN COPY THE FOOTNOTE TEXT INTO
THE FORMATTED FOOTNOTE LIMITED TSB
ELSE
GO TO THE FOOTNOTE PAGE VIA THE INDEFINITE
LENGTH DOCUMENT TSB BY MOVING THE TEXT
STORAGE BUFFER POINT OF OPERATION TO THE
DESIRED FOOTNOTE PAGE
ENDIF
INSERT THE FOOTNOTE NUMBER SEQUENCE PRIOR
TO THE FOOTNOTE TEXT
SETUP A COUNTER THAT WILL KEEP TRACK OF THE
NUMBER OF FOOTNOTE TEXT LINES FOR THE
FOOTNOTE REFERENCE CONTROL
UNTIL THE END OF THE FOOTNOTE TEXT IS
FOUND DO
ADJUST THE FOOTNOTE TEXT LINE BETWEEN THE
LEFT AND RIGHT MARGINS
INCREMENT THE COUNTER THAT IS KEEPING TRACK
OF THE NUMBER OF FOOTNOTE TEXT LINES
ENDDO
IF THERE ARE NO LINES IN THE FOOTNOTE TEXT
PAGE THEN
INSERT A REQUIRED CARRIER RETURN
SET THE NUMBER OF LINES FOR THIS ENTRY TO 1
ENDIF
SAVE THE NUMBER OF TEXT LINES CALCULATED IN
THE ENTRY'S LINE COUNT FIELD
IF NOT PERFORMING LIMITED TSB MODE
RESOLUTION THEN
IF THE FOOTNOTE TEXT PAGE'S PAGE ENDING
CONTROL IS NOT AT THE START OF A LINE THEN
INSERT A REQUIRED CARRIER RETURN PRIOR TO
THE PAGE END CONTROL
ENDIF
MOVE THE POINT OF OPERATION TO THE START OF
THE FOOTNOTE TEXT PAGE
DELETE THE FOOTNOTE NUMBER SEQUENCE. THE
ROUTINE EPAG WILL INSERT LATER
STORE THE FORMATTED FOOTNOTE TEXT PAGE
BACK TO THE FOOTNOTE DISKETTE
ENDIF
ENDSEG (COPY.sub.-- FN)
BEGSEG (UPDATE)
DETERMINE THE MAXIMUM NUMBER OF FOOTNOTE
TEXT LINES THAT MAY BE INSERTED IN A PAGE
IF THE NUMBER OF AVAILABLE LINES TO INSERT IS
GREATER THAN THE MAXIMUM NUMBER OF
FOOTNOTE TEXT LINES THAT MAY BE INSERTED IN
A PAGE THEN
SET THE NUMBER OF AVAILABLE LINES TO INSERT
EQUAL TO THE MAXIMUM NUMBER OF FOOTNOTE
TEXT LINES THAT MAY BE INSERTED IN A PAGE
ENDIF
UPDATE THE NEW VALUE FOR NUMBER OF TEXT
LINES TO INSERT
UPDATE THE NEW VALUE FOR ESCAPEMENT DUE TO
TEXT LINES THAT ARE TO BE INSERTED
INSURE THAT THE CALCULATED ESCAPEMENT WILL
ALL FIT IN THE CURRENT PAGE. ADJUST VALUE IF
THE ESCAPEMENT IS TOO MUCH
ENDSEG (UPDATE)
END (GETFN)
______________________________________
The purpose of the routine EPAG in Table 8 is to move FORMATTED footnote text to the end of the current page. The footnote text resides either in the formatted footnote TSB 140 (if the limited algorithm is used) or on pages in the footnote library (in a separate document or on page 9000 or above if in the same document). Upon invocation, a page end decision has been made by the paginator and the TSB point of operation is at the start of a line. This line will be forced to the next page via the insertion of a page end control, but before the page end control is inserted, this routine must insert (prior to the TSB point of operation) the appropriate number of formatted footnote text lines along with all the necessary formatting controls. All the information required for these insertions is available in the footnote control block 108 and footnote reference buffer 110. After determining how many lines it must insert, this routine inserts the necessary formatting controls to precede the footnote text, the separator line, and the formatting controls to following the footnote text. After the formatting controls are inserted, this routine either fetches all of the formatted footnote text from the formatted footnote TSB 140 (if the limited algorithm was able to be used) or (if the indefinite length algorithm had to be used) then it fetches in the footnote text for the first footnote. The footnote's respective entry in the footnote reference buffer 110 contains the pointers to each footnote text page. Note that the footnote reference buffer 110 causes the system to have an "internal resolution limit" of about 20 footnotes per page if each footnote is stored in a separate document and up to 142 footnotes per page if each footnote is stored on page 9000 or above of the same document that contains the body text with the corresponding footnote references. If necessary, lines that have been inserted in the previous page will be deleted after the entire footnote text is fetched. If the entire footnote fits and more footnote text is pending, the insertion sequence will continue with the next footnote. If the entire footnote won't fit, then the footnote text that will not fit will be deleted. These lines will appear on the next page. After the insertion is complete, the necessary pointers in the footnote resolution control block 108 are updated. The footnote resolution buffer will also be updated to reflect the insertions.
TABLE 8
______________________________________
BEGIN
MODIFY THE VERTICAL ESCAPEMENT DUE TO
PENDING FOOTNOTE TEXT LINES THAT ARE TO BE
INSERTED AT THE BOTTOM OF THIS CURRENT PAGE
DUE TO ANY "WIDOW" OR "ORPHAN" LINE
DECISIONS MADE BY THE PAGINATOR
IF IT HAS BEEN DETERMINED THAT THERE ARE
FORMATTED FOOTNOTE TEXT LINES TO INSERT AT
THE BOTTOM OF THIS CURRENT PAGE THEN
SAVE THE CURRENT PAGE END LOCATION
INSERT PRIOR TO THE CURRENT POINT OF
OPERATION THE FOOTNOTE TEXT FORMATTING
SEQUENCE THAT WILL ENCAPSULATE THE PENDING
FOOTNOTE TEXT
IF PERFORMING LIMITED MODE TSB
ALGORITHM THEN
INSERT THE PENDING FOOTNOTE TEXT VIA
PROGRAM SEGMENT LIMITED
ELSE
INSERT THE PENDING FOOTNOTE TEXT VIA
PROGRAM SEGMENT INDEF
ENDIF
RESTORE POINT OF OPERATION TO PAGE END
LOCATION
ENDIF
RETURN
BEGSEG (LIMITED)
OBTAIN THE VERTICAL ESCAPEMENT OF THE
FOOTNOTE TEXT LINES TO BE INSERTED
IF THE INTERNAL RESOLUTION LIMIT HAS NOT BEEN
REACHED AND ALL OF THE PENDING FOOTNOTE
TEXT WILL FIT THEN
INSERT ALL OF THE PENDING FOOTNOTE TEXT
ELSE
ADVANCE TO THE TOP OF THE LIMITED TSB BUFFER
MOVE THE POINT OF OPERATION TO THE END OF
THE LAST FOOTNOTE LINE THAT IS TO BE COPIED
INSERT INTO PAGE THE FOOTNOTE TEXT THAT IS
BOUNDED BY THE TOP OF LIMITED TSB BUFFER AND
THE POINT OF OPERATION
ENDIF
UPDATE THE FOOTNOTE CONTROL BLOCK AND
FOOTNOTE REFERENCE BUFFER TO REFLECT THE
NUMBER OF FOOTNOTE TEXT LINES INSERTED
ENDSEG (LIMITED)
BEGSEG
OBTAIN THE VERTICAL ESCAPEMENT DUE TO
FOOTNOTE TEXT LINES THAT ARE TO BE INSERTED
OBTAIN THE OFFSET TO THE FIRST FOOTNOTE
ENTRY IN THE FOOTNOTE RESOLUTION BUFFER
SETUP A COUNTER FOR THE NUMBER OF LINES
INSERTED UNTIL ALL THE FOOTNOTE TEXT LINES
THAT ARE TO APPEAR ON THIS PAGE ARE
INSERTED DO
IF THE FOOTNOTE REFERENCE WAS RESOLVED
SUCCESSFULLY THEN
INSERT THE FOOTNOTE TEXT
ELSE
INSERT INTO TEXT THE APPROPRIATE FOOTNOTE
RESOLUTION ERROR MESSAGE
ENDIF
ADD TO THE COUNTER KEEPING TRACK OF HOW
MANY LINES HAVE BEEN INSERTED THE NUMBER
OF INSERTED LINES FOR THIS FOOTNOTE
SUBTRACT FROM THE COUNTER KEEPING TRACK OF
HOW MUCH ESCAPEMENT REMAINS TO BE INSERTED
BY THE INSERTED ESCAPEMENT
IF THERE IS STILL MORE ROOM FOR FOOTNOTE
TEXT THEN
DETERMINE THE NUMBER OF BLANK LINES TO
INSERT FOR FOOTNOTE SPACING
DETERMINE THE ESCAPEMENT DUE TO THESE
BLANK LINES
IF THERE IS ROOM FOR THESE BLANK LINES THEN
ADJUST THE INSERTION ESCAPEMENT COUNTER
ACCORDINGLY
ADJUST THE INSERTION LINE COUNTER
ACCORDINGLY INSERT THE BLANK LINES INTO TEXT
SETUP TO PROCESS THE NEXT FOOTNOTE
ELSE
INDICATE THAT NO MORE FOOTNOTE TEXT CAN BE
INSERTED
ENDIF
ENDIF
ENDDO
UPDATE THE FOOTNOTE CONTROL BLOCK AND
FOOTNOTE REFERENCE BUFFER TO REFLECT THE
NUMBER OF FOOTNOTE TEXT LINES INSERTED
IF THERE WILL BE NO FOOTNOTE TEXT LINES
FLOWING TO THE NEXT PAGE AND SYSTEM IS
PERFORMING REGULAR RESOLUTION THEN
STOP USING THE INDEFINITE ALGORITHM SO THAT
THE LIMITED ALGORITHM WILL BE USED ON THE
NEXT PAGE ENDIF
ENDSET (INDEF)
END (EPAG)
______________________________________
In summary, a unique method of, and system for, managing the assembly of body and footnote text is provided in order that an operator may format and assemble footnote text in a document. Format and assembly of the footnote text can be either at the bottom of pages of the document or at the end of the document. In addition, according to the method and system of this invention, the operator can hyphenate the document, adjust line endings, cause page ending decisions and associated widow/orphan line decisions to be made, and cause printing of the document in a single pass operation. Following input keying of the body and footnote text, operator procedure calls for causing the system to assemble the body and footnote text. The assembly operation involves combined merge and pagination operations to which either one of two separate algorithms are acceptable. A fast algorithm or the "limited footnote algorithm" is used when processing footnotes of limited size. A slower algorithm or the "indefinite footnote algorithm" is used when processing lengthy footnotes. The system automatically determines which algorithm is to be in effect. This determination is on a per page basis. Whenever possible, the "limited footnote algorithm" will be the algorithm in effect. Following assembly, the document can be display recalled on a page basis for review and editing. Thereafter, the document is ready to be printed. While the invention has been particularly shown and described with reference to a preferred embodiment, it will be understood by those skilled in the art that various changes in form and detail may be made without departing from the spirit and scope of the invention.
|
Same subclass Same class Consider this |
||||||||||
