/WPRTOV DECMATE-II V2.0 PRINTER OVERLAYS /XLIST /THIS IS SUPPOSED TO BE HERE /276 EMcD 24-Sep-85 Dutch and Spanish Xlations /275 EMcD 16-Sep-85 Nordic translations /274 Mart 28-june85 fix reqired space for tech chars /273 Mart 28-may-85 set flag to repeat char for shadow / and sort bugs in theme printing /272 MART 03-MAY-85 flag PUM mode /271 Mart 02-APR-85 Allow 8 bit multinational chars /270 RCME 22-MAR-85 Set up G1 as line drawing character set / /---------------------- All below refer to V2.0 and earlier --------------- / /269 HLP 10-JAN-85 Fixup EOD wait for double XON on 02/03/WD /268 HLP 28-DEC-84 Don't strip trailing spaces if soft retn / Delete SP-BS ruse to trigger underline / Fix no-letterspacing bug (unreported) / Only reset LQP02 at EOD / Fix missing jump--going to oblivion on EOD timeout / Set DECPSP flag for LN03 proportional fonts /267 HLP 13-DEC-84 UNDO 266 and B include printer ID and / reset printer after printer ID /266 HLP 06-DEC-84 Add 1 sec delay after RIS in PRTRID /265 HLP 03-DEC-84 Changes for bug 334: B to include printer ID / Reset printer after printer ID using / new PCTMRS technique / R NOT to ask for status if nonexistent printer / Fix dead key tab posn bug /264 HLP 27-NOV-84 Fix \s.\p hang BUG384, BUG373 /263 HLP 26-NOV-84 Reset PRIRFD when wakeup !!! WPSV2-380 /262 HLP 21-NOV-84 Fix LQP02 bold broken in edit 258 /261 HLP 12-NOV-84 19Z Fix bug in XMT; too many uses of T2 /260 HLP 12-NOV-84 Changes for extra FF if EO and RESET causes / consecutive odd or even pages /259 HLP 07-NOV-84 Rename LPLIN symbols to DPLIN so will CREF /258 HLP 06-NOV-84 Fix old TW justify bug WPSV2-361 /257 HLP 26-OCT-84 Change DCS escape chr from \ to / / Reenable error reports at EOD after RIS /256 HLP 23-OCT-84 Fix V2-336 TW alignment problem /255 HLP 19-OCT-84 For DEVEL, add \v for a fixed string /254 HLP 16-OCT-84 19X Fix Attributed CHRSET, FONT, PITCH bug (unreported) / Fix Attributed tab justification bug (unreported) /253 HLP 10-OCT-84 Fix Footer Problem Again broken on edit 214 / Increase EOD wait before declare malfunction / (wpsv2-313) etc. /252 ECH 09-OCT-84 Fix for incorrect margins on pitch changes /251 HLP 08-OCT-84 Fix WPSV2-307, Justify with para return / Fix WPSV2-314, LQPSE centering justify /250 HLP 04-OCT-84 For DEVEL, \d includes time /249 HLP 02-OCT-84 19W Fix Page Number Centering bug 298 /248 HLP 27-SEP-84 Fix Wide Track Printer Justification /247 HLP 21-SEP-84 Install Form Feed at BOTP if DD CHST / Add 2 overlays for LN03 justification /246 ECH 18-SEP-84 Fix incorrect font for underlines /245 HLP 18-SEP-84 19V Put LPQSE justification back to v1.5 / 10-SEP-84 Minor changes for LN03 / Fix LQPSE Dead key problem /244 HLP 07-SEP-84 19T Rework LQP02 Centering logic to fix bug, / add C in ruler centering ability / 30-AUG-84 19S Fix tabbed underline in OV3L10 / Fix shadowbolding when shouldn't in OV3l10 /243 HLP 28-AUG-84 Initial Changes for proportional centering LQP02 / ...added a new overlay for LQP02 centering / Fix 1 space indent bug--reset P2PSN to 0001 / Fix tab after underline bug / Fix Multicolumn not centering / Fix Tabs in multicolumn blobbing /242 HLP 17-AUG-84 Fix LQP02 ppnl TW printing Bug#99 /241 HLP 10-AUG-84 Fix LP headers not printing and clobr boot blk /240 HLP 09-AUG-84 Changes for odd/even paging /239 HLP 07-AUG-84 Fix ppnl tabs in LQP02 /238 ECH 01-AUG-84 MINOR BUG IN TECH CHAR TO PRBIF /237 HLP 31-JUL-84 Add delay after LQP02 XON /236 HLP 26-JUL-84 Changes for sixel graphic controls /235 ECH 30-JUL-84 Technical Characters to Host. /234 HLP 24-JUL-84 Fix DD CHST blank line problem /233 HLP 20-JUL-84 Account for new return from PLCHBS on tech chr /232 HLP 17-JUL-84 Change PRTRID so PRSTTS is not set when / a non existent printer in CX or LP / Do not execute CHFNRS if LQPSE (WPSV2-114) /231 HLP 15-JUL-84 Move OVDDCK to a type A overlay / ...Fix missing CLA after set quality mode /230 LJJ 13-JUL-84 Fixes for \d\p\s expansion/contraction bug /229 ECH 12-JUL-84 Comments and removal of the start of a block / absorbed an extra disk block /228 ECH 10-JUL-84 Integrate fixes for draft/tech printing: / justification of indented rulers / justification with tech char / bolding of tech char when bold interp on /227 HLP 09-JUL-84 Move PLSCPX and PLREST from resident to overlay /226 HLP 02-JUL-84 End of document fix / Create CHFNRS for use by PRTRID & OVNDOC /225 GDH 29-JUN-84 Empty control block bugfix /224 ECH 22-JUN-84 Technical Characters in LPLIN /223 HLP 18-JUN-84 Integrate LJJ changes for British lb. sign / Initialize G2 and G3 for tech chars. /222 ECH 15-JUN-84 Complete supers/subs in LPLIN /221 LJJ 13-Jun-84 Remove edit 205, fix \d processing /220 HLP 11-JUN-84 Rework ASCOUT and justification sequence /219 HLP 10-JUN-84 Save a little space in OVJUSD and OVJUSL /218 HLP 06-JUN-84 Fix Proportional Justified Printing / with replacement characters / Fix Required Space with LQPSE /217 HLP 31-MAY-84 Move PRJL5A here from resident / Make PIDW use ESC02 for terminal ID seq / Use correct table for proportional printing /216 HLP 30-MAY-84 Changes for Coding of Required Space / Conditionalize code for multiple pass dead keys / Use PRESCS to set quality mode /215 ECH 29-MAY-84 Initial Changes for supers/subs on draft printers /214 HLP 24-MAY-84 More changes for DD HOST1 /213 HLP 14-MAY-84 Initial Changes for adding DD HOST1 /212 HLP 11-MAY-84 Change XXSTGN names to match G0 and G1 properly / Change LPLIN to require argument MC on LA50 / Reset page size at end of document / (re-establishes top of form) / F and N rulers, EX changes for draft printers /211 HLP 30-APR-84 Restructure justificationn overlays / Eliminate thrashing when DD HOST / Rebias LQPSE PSTBL from 2 to 1 /210 HLP 25-APR-84 Change end of document scheme to / detect LQP02 done with D2XONF / delete SNDCHR add PCTMID /209 HLP 24-APR-84 Flush Host Input Buffer if DD HOST /208 HLP 23-APR-84 Select G0 at beginning of document / Fix CHRSET NORMAL bug not resetting G1 /207 HLP 20-APR-84 Changes for RDFIO to use PRQRX /206 HLP 18-APR-84 Fixup drive no passing for QBLK change /205 ECH 16-APR-84 Fix for the date change for U.S./British /204 HLP 13-APR-84 Move PCTBUF to overlay from R2FILP / Change RDFQBK to PRQB /203 HLP 10-APR-84 Add JEXIT code so print field can be used by other jobs /202 HLP 14-MAR-84 Move justification variable to page zero /------------------------SDC Submission DECmate-II V1.5--------------------- /201 HLP 19-MAR-84 Reset function code to READ after MISCTL in WBLK /200 HLP 16-MAR-84 Fix Footer positioning method so works with / draft printer which cannot move backwards / ALSO fix false mismatch CTL if footer size is / less than amount stripped AP NO /199 HLP 13-MAR-84 WAIT routine not to reset status (move WAIT2,) /198 HLP 05-MAR-84 Add duplicate routine IDCKT2 to test TIMEOUT /197 HLP 03-MAR-84 Don't issue PRINTER PITCH command to LQPs /196 HLP 15-FEB-84 Re-issue margin command after setting pitch / LA100,LA120,LA34-WA firmware bug pitch reset margins /195 HLP 06-FEB-84 Select either table 1 or table 2 in NDOC /194 HLP 05-FEB-84 Fix theme justification bug. Although old, / this bug never hit V2.1 or V1.1 Yea! /193 HLP 01-FEB-84 Fix problem of OVRULR (formerly an OLA) / being called by other OLAs if a ruler in / certain control blocks. Fixed by making type C / Changed OVFONT from type C to B /193 HLP 19-JAN-84 Don't ask for status on LPQSE ASF error / Fix CHRSET initialization bug /192 HLP 16-JAN-84 Reworking character routines, etc. / Make PRSTRP test if already at EOC / Restore JMP PRSTRP near PRMCL4 /191 HLP 11-JAN-84 More work on mismatched controls, etc. / Inhibit enabling of status reports on LA34 /190 HLP 06-JAN-84 Rewrite LP Header/Footer processing for mismatch / control processing, use diff buffer to save space /189 HLP 05-JAN-84 LQPSE to feed envs from front tray (DECII-156) /188 HLP 29-DEC-83 Fix multicolumn matching control problems /187 HLP 27-DEC-83 Add time delay to loop which times out / at end of document if there is an error condx /186 HLP 16-DEC-83 Reset character size if LQPSE in Stop Menu / otherwise print screen gives blobs (bug 130) /185 HLP 16-DEC-83 Refine EOF within Control block processing /184 HLP 08-DEC-83 Detect EOF within Control block indicating / missing end print control /183 HLP 07-DEC-83 Change end of document delay from 8 to 12 secs / (for DECII-140 LA120 bug) /182 HLP 07-DEC-83 Change Stop Overlays to Type C / (fixes missing end control bugs) / Call PTSTST where needed near JMS PRRULE /181 HLP 01-DEC-83 Fix a bunch of SE/SELECT bugs /180 HLP 30-NOV-83 Fix insert rear message on PRINTER SELECT / LETTERHEAD with SE YES / SE NO to select trays if ASF attached /179 HLP 22-NOV-83 Allow String Finals for CHRSET /178 HLP 17-NOV-83 Move all overlays in WPRINT to here / Clear LPONLN if DD=HOST /177 HLP 11-NOV-83 Changes for SE ENVELOPE multipass strategy /176 HLP 07-NOV-83 Fix Problem if do user stop while / LQP02 timing out / Request a status report after response / to Stop Printer Menu /175 HLP 02-NOV-83 Don't set T3 at OVSTN unless ASF attached /174 HLP 29-OCT-83 Bugfixes / PRINTER STOPPED at end of doc LQPSE / No sheet fed, LQPSE/ASF / LQP02 doesn't print: ovly loading probs /173 HLP 23-OCT-83 Add CHRSET and FONT functions /172 HLP 13-OCT-83 Add SE LETTERHEAD to PRINTER SELECT cntrol /171 HLP 03-OCT-83 Bugfix: Detect if header blk #=0 and declare / it to be a doc rd error. (Happens if user / switches disks after que'ng and new dsk / doesn't have a document with same number) /170 HLP 30-SEP-83 Changed places PRRSST is called / so not clobbered by reset buffer /169 HLP 11-AUG-83 Changed order of processing so SE stop / processing takes place before reading anything /168 HLP 23-AUG-83 Restructure overlays so there can be / up to 16 overlay areas and / up to 256 overlays which can load into given area / Implement menu pitch for draft printers / Don't load printer handlers anymore / Add PRINTER control blocks for sending escape / sequences and controlling ASF01/02 tray selection /167 WCE 17-AUG-83 Remove changes made in edit #146 that caused a / redefinition of "RXE??" handler commands /166 HLP 10-AUG-83 Make check document destination code / part of PRTRID. Call wwith AC=0002 / This so list processing can set quality / mode on LA50/LA100. /165 HLP 02-AUG-83 Reset all character enhancement attributes / at end of document ESC [ m (was ESC [ 1 m) /164 HLP 25-JUL-83 Lengthen end of document delay for LA50 / Make LA50 & LA100 not observe rest of EOD delay / once answerback occurs /161 HLP 09-JUN-83 Rework footer processing to leave footer in / a fixed psn if text invades BM in AP NO /160 HLP 07-JUN-83 Add IDANSW flag /159 HLP 06-JUN-83 Delete extra blank pages when BM=0 /158 HLP 02-JUN-83 Come out of PRWAIT on PRACTN not PRSTOP /157 HLP 01-JUN-83 Reset LPFLAG near DONE1. Fix V2.1 bug 159 /156 HLP 24-MAY-83 Change comments near PRST6A / Move OVTOPP from a B to an A overlay / to speed up to/from / Use 13 bit arithmetic on PRPGNM range checks / Delete count backwards after 2048 (\p\s) / Lock maximum page number at 4095 / If PRSTOP occurs during PRTRID treat as / nonexistent printer /155 HLP 16-MAY-83 Add stuff for communications error code 26 /154 HLP 13-MAY-83 Change PRTRID timer from 3 to 4 seconds / Do not re-do printer stop. WPCUT handles this /153 HLP 10-MAY-83 Reinstate code at GETDC to set busy /152 HLP 27-APR-83 Make PRRSST resident, add calls in WAITPR / and PRST8A / Reorganize setting and clearing of PRSTTS, PRSTT2 /151 HLP 22-APR-83 Make CLQP01 execute only once / Increase delays at end of document / to prevent timeouts while printer finishes / Make PRRSST request status if LQPSE attached /150 HLP 08-APR-83 Fix extra CLA d'l't'd rev 094 which resulted / in R also doing an N new page /149 HLP 07-APR-83 Rewrite SETSTN / Revert to old page rollup on B,T (see REV140) / Make S call PRRSTS /148 HLP 01-APR-83 Delete JEXIT so printer errors can be parsed / at all times / Fix multicolumn (change SNA to SZA at PRMLTC+2) /147 HLP 23-MAR-83 Don't reset status for those errors which / the printer will report when corrected /146 HLP 04-MAR-83 Rewrite to handle disk errors /145 HLP 01-MAR-83 No ESC-[-c after print if DD=HOST / No JMS PRTRID after B,T / Use JMS DIGCHK near PRMCG1 to save space / Skip JMS PRTRID on N if DD=HOST /144 HLP 28-FEB-83 Rewrote PRTID to use XRPMSK /143 HLP 21-FEB-83 New useage of LPONLN (IDFLAG & PRQLQP deleted) / also PRASF deleted /142 HLP 15-FEB-83 Rework for parser in PRINT field /141 HLP 27-JAN-83 Fix mask for LPONLN in IDTMMX--was giving / wrong delays for draft printers when dequeue / this was culprit in LA34 beeping bug /140 HLP 25-JAN-83 Insure that B always resumes pass 1 if 2wheel / Rearranged order of processing at NCPYL3 and 4 / Deleted JMS PRSTNP on B or T near OVSTP9 / and added JMP .+1 to relieve interrupts / and added JMS PRSTNP on S-S only / Make T N be redo n copies if TW YES /139 HLP 20-JAN-83 Reset LQP02 hit count to 1 if abort. Ref /114 /138 HLP 19-JAN-83 Introduce delays for DPs and LQP02 B4 dequeue /137 2. Reset PRSTTS to 1 if it was 6 or less /-------------19-JAN-83-------SDC SUBMISSION DECmate-II V1.0.0 /137 HLP 18-JAN-83 V136 Printer Bug THREE fix: / 1. NOP the JMS PRTRID after a B or T / 2. Reset PRSTTS to 1 if it was 2 (user stop) / 3. Don't reset PRSTTS if talking to LQP02 /136 HLP 13-JAN-83 Eliminate extra sheet between sheets on SE YES / continuous form paper to LQPSE or LQPSE /135 HLP 11-JAN-83 Fix "wandering footer" with AP yes when a / blank line occurs at natural page break /134 HLP 10-JAN-83 Set PRINTER BUSY at GETDC /133 HLP 07-JAN-83 If PRSTTS goes from error to busy / while printer code is in stop ovly, / set it to 2 (user stop) /132 HLP 31-DEC-82 Patch to set status back to busy /131 HLP 30-DEC-82 Added dispatch table for resume / Make non-existent printer resumable /130 HLP 29-DEC-82 Add who-are-you at DONE2. LQPSE won't / respond until it is done with the document / PRID to reset LQPSE if times out /129 HLP 22-DEC-82 Fix B and T for LQPSE /128 HLP 20-DEC-82 Missing ( on a link near OVSTB /127 HLP 16-DEC-82 Make sure that CLQP01 is called if enter stop / menu with nothing in queue (as from CX) so that / LQPSE is properly reset and will feed paper next / time CX is entered (BUG #273--phase II) /126 HLP 12-DEC-82 FIX BUG #291: wide line in CX hangs system / change error code for LQP01 CANCEL to 25 / reset LQP01 when this error code occurs /125 HLP 09-DEC-82 FIX BUG #285: portion of LQP02 status msg / lost if comes in while loading handler /124 HLP 08-DEC-82 Replaced setting of TIMOUT at DONE0B / with tabularized setting when enter PRTID /123 HLP 07-DEC-82 PRTID not to wait after draft printer ID / Changed delay after ID from 3 to 1 second / so WAITPR routine in WPCUT would not timeout /122 HLP 06-DEC-82 Fix SE & AP yes bug #270 /121 HLP 02-DEC-82 Changes for selective stop printer menu / Change LQPSE ASF error code from 17 to 24 /120 HLP 03-DEC-82 Use a real delay when wait for status in PRTID / Change PRTID timer routines to allow other jobs / to be using TIMOUT at the same time / WPSYS now lets TIMOUT count up continually /119 HLP 29-NOV-82 Delete extra sheet (continuous form) / at end of document /118 HLP 23-NOV-82 Handle abort from PRWAIT (CX errors, etc.) /117 HLP 19-NOV-82 Reset PRASF in PRTRID /116 HLP 19-NOV-82 Dont copy PRLOCK to PRSTTS in SETSTN /115 HLP 18-NOV-82 Reset LQPSE after printing so CX and print / screen will always feed paper /114 HLP 16-NOV-82 Set back to one hammer strike if dequeue / so CX will be guaranteed to print /113 HLP 16-NOV-82 Reset PRSTTS if abort, create PRSTT3 /112 HLP 03-NOV-82 PRTID not to set PRSTTS to 1 (busy) / PRSTTS to 1 when find a doc in queue / PRSTTS to 0 when find no doc in queue /111 HLP 29-OCT-82 Fix Bug #161 STOPPED not removed on / B or T with LPQSE or any DP /110 HLP 27-OCT-82 Make malfunction a fatal error /109 HLP 26-OCT-82 Change N command to eject if ASF attached /108 HLP 22-OCT-82 Fix BUG 121 for LQP02 (P after unfixed ASF err) /107 HLP 15-OCT-82 Make PRTID give an error if LQP01 does not answer restore / Make PRTID reload handler if paused / Change PRTID paused error code from 15 to 11 /106 HLP 15-OCT-82 Clear the Handler's print buffer on S-S /105 HLP 14-OCT-82 Reset PRSTTS and PRSTT2 on S-S /104 HLP 12-OCT-82 Changed JMS STSTTS to DCA PRSTTS at PSXIT (Bug #125) /103 HLP 08-OCT-82 Reworked destination table in stop ovly / Moved stuff to make more room / moved reset of FLASH and BUZZ after action / Moved reset of LQP01/ASF error to PRSTL9 again / Make P and R responses to LQP01/ASF error illegal / Moved PRACTS to page zero /102 HLP 07-OCT-82 Changed SNA to SNA CLA in stop overlay /101 HLP 05-OCT-82 Change wrong doc dest error code to 10 from 24 / (code 24 gets clobbered by LQP02 no error report) /100 HLP 04-OCT-82 Move reset LQPSE on ASF error code / (P was hanging system) /099 HLP 01-OCT-82 Stop-Stop to return to dequeue / (so can cancel if LQP02 paused at boot) /098 HLP 30-SEP-82 Restore Stop-stop code to join PRSTL7 / (LQPSE ASF error S did not reset LQP01) /097 HLP 28-SEP-82 Fix PRTRID routine--proper exit on / LQP02 paused at PRTRID call /096 HLP 27-SEP-82 Fix bug SE alternate (again!) /095 HLP 21-SEP-82 Add code to change document destination /094 HLP 15-SEP-82 Eliminate blank sheets between docs /093 HLP 14-SEP-82 Fix bug #XX-Extra sheets fed by S commands /092 HLP 12-SEP-82 Fix bug #37-SE Alternate /091 HLP 31-AUG-82 Fix bug--no sheet fed on N from PS menu /090 HLP 30-AUG-82 Add recovery when connected to wrong printer /089 HLP 28-AUG-82 Fix hang problem when boot with LSP02 paused / (Bug number 33) /088 HLP 18-AUG-82 Changes to allow B and T after ASF error / Done ovly waits for LPDNFG while checking PRSTOP / Code added at PRSTL9 to reset LQP01 / Code deltd at PRSTL2 to allow ASF errors /PREVIOUS EDIT HISTORIES (NON HLP) DELETED 09-JAN-83 HLP /THE FIRST LOCATION IN AN OVERLAY MUST BE THE NEGATIVE OF THE OVERLAY NUMBER /FOR A FULLER EXPLANATION OF THE OVERLAY SCHEMES, SEE THE COMMENTS WITH /THE SECTION PROV, IN WPRINT /OVERLAYS NO LONGER NEED TO BE WRITTEN OUT /C150 /SEE INITIALIZATION CODE NEAR FLD3L1 /A150 OVADR=0000-400 /BEGINNING ADDRESS FOR OVERLAYS OVNUM=-1 /BEGINNING OVERLAY NUMBER OLA=0000 OLB=0400 OLC=1000 OLD=1400 XLIST OVTYPE=OLA OVNUM=OVNUM+1 OVADR=OVADR+400 OVRLCA=PROVA+OVTYPE DL=DLOPRO+OVNUM /DISK BLOCK OF THIS OVERLAY FIELD OVNUM%20+3 RELOC *OVADR RELOC OVRLCA -OVNUM / THIS OVERLAY IS USED ONLY FOR LQPS /C211 OVJUSL=.-OVRLCA OBJUSL=OVTYPE+OVNUM /PLPTR currently addresses the return word in the buffer. Bit 1 of this word /is clear for a hard return and is set otherwise. We save the type of the /return for later use. TAD I PLPTR /GET THE LINE ENDING CODE AND (3400) /MASK BIT WHICH SAY TYPE OF RETURN /C251 DCA PRJRET /SAVE THE TYPE OF RETURN: / 0012 --> 0000 HARD RETURN / 1012 --> 1000 PARA MARKER / 1412 --> 1400 CENTERED RETURN / 2012 --> 2000 SOFT RETURN TAD PRQPIT /COPY THE PITCH FLAG /A219 DCA PLPFLG /COPY OF PITCH FLAG /A219 /Call routine to set LQP02 into proportional print mode if thats what we/A080 / are printing to and thats what we are printing. /A080 /A080 DCA PLBOLD /Reset SP PROPORTIONAL LQP02 flag. /A086 JMS PROV / FIRST MAKE SURE PLINIT IS LOADED /A211 OBPLIN / /A211 JMS PLINIT /If proportional print to LQP02 then set printer/A080 /We now set up some variables in order to process the line. We want the /following conditions to hold: /PLPTR - Points to the return character (this already holds) /PLCNT - Is the negative of the number of characters, including the return, / in the line. /PLDIR - Is minus one so that processing can proceed from right to left. PRJL0A, /A211 TAD PLPTR /Subtract the address of the return, and one more CMA TAD (PRLBUF) /From the address of the first character DCA PLCNT /And save as the buffer count AC7777 DCA PLDIR /Set the direction of printing /If the line ends with a soft return, we now strip all trailing spaces, tabs, /and backspaces from the line. If the line ends with a hard return, we do /not strip these characters. We strip in case of soft return because the /trailing spaces interfere with justification, and should not appear in case /the line is underlined. In either case, when the loop is over, the following /conditions will hold: /1. PLPTR will point to the rightmost character of the line which should / be printed (which will be a text character in case of a soft return / and the one before the return for a hard return). /2. PLCNT will be the negative of the number of characters from the beginning / of the buffer to the character pointed to by PLPTR. PRJL0, JMS PLNXT /Look at the next character JMP PRGSL1 /No more characters so the line was all blank--no /need to bother printing the line AC2000 /WAS THE RETURN A SOFT RETURN? /C268 AND PRJRET /C268 SNA CLA JMP PRJL1 /NO--DON'T STRIP TRAILING SPACES! TAD I PLPTR /Get the character AND P177 /Strip the mode bits TAD (-SPC) /Is it a space/tab/backspace? SPA SNA CLA JMP PRJL0 /Yes--continue stripping the line /The line was not blank and must be printed. We now initialize some variables /used to gather information about the line for printing and justification. PRJL1, TAD PLCNT DCA PRLBCT /Save the size of the line DCA PLPS /Clear position justification spacing DCA PLSS /Clear space justification spacing AC7777 DCA PRJPOS /Initialize number of inter-position spaces DCA PRJSPC /Clear number of spaces DCA PRRCH /Clear right end of line position DCA PRPASS /Clear the pass counter DCA PRJDEF /Clear deficiency (no justification required yet)/A080 /This loop gathers information about the spacing and composition of the /line by processing the characters from left to right. When the loop /completes, we will know: /PRRCH -The length of the justifiable part of the line in print units / ** NOTE ** This is a different definition than that used in OVJUSD ** /PRJPOS - The number of inter-position spaces in the justifiable portion / of the line. /PRJSPC - The number of spaces in the justifiable portion of the line. /The loop also marks each character in the justifiable portion of the line /by setting bit 0 of the character. The justifiable portion of the line is /that part which follows the rightmost tab space. AC4000 /We first set the count enable flag. This flag is DCA PRJENB /to mark justifiable characters and is examined when /deciding whether to count them. It is ultimately /cleared when the first tab is encountered. /At the beginning of each iteration, PLPTR points to the first character in a /position. Each iteration treats the entire position with all of its dead /keys, if any. PRJL2, TAD I PLPTR /Get the character AND P177 /Strip the mode bits TAD (-SPC) /Is it a space? SZA CLA JMP PRJL3 /No, a text--jump to treat it /The character is a space. If it is part of a tab, the enable flag must be /cleared. If the enable flag has not been cleared by this time, we increment /the number of justifiable spaces and fall through to the text counter. TAD I PLPTR /Retrieve the space character CMA RAL /AC0=0 if the space is part of a tab, 1 otherwise AND PRJENB /AC=4000 if counting should still be enabled SZA /Do not count the space if we are disabled ISZ PRJSPC /Count a space in justifiable part of line DCA PRJENB /And save the new enable flag /This section handles characters. If the enable flag is set, we count the /position. PRJL3, TAD PRJENB /Get the enable flag SZA CLA /IF THE FLAG IS CLEAR WE HAVE ENCOUNTERED /A243 /THE RIGHTMOST TAB SPACE. IF IT IS A CENTERING /A243 /RETURN STOP COUNTING. OTHERWISE USE PLNRCS /A243 JMP PRJL3A /MEASURING IS STILL ENABLED /A243 / WE HAVE MEASURED THE JUSTIFIABLE PORTION OF THE LINE / WE NOW EXAMINE THE TYPE OF RETURN / IF IT IS A CENTERING RETURN WE WILL GOTO THE CENTERING JUSTIFICATION / LOGIC DIRECTLY. IF IT IS A SOFT RETURN AND WE ARE JUSTIFYING / MORE TESTS ARE NECESSARY... / LQPSE not supported in this version and I needed the space /d271 /d271 JMS SKIPIF /DO THE LQPSE JUSTIFICATION THE WAY WE /A245 /d271 LQP02 /WE ALWAYS DID -- DON'T ALIGN TABS /A245 /d271 JMP PRJL3B /OR FIX CENTERING /A245 / LQPSE not supported in this version and I needed the space /d271 TAD PRJRET /GET TYPE OF RETURN /A243 TAD (-1400) /SEE IF CENTERED RETURN /C251 SZA CLA / /C251 JMP PRJL4B /NOT CENTERING, GO ADD PLNCRS /C251 / CENTERING, LQP02 ... TAD (OVCTR2 /GO TO LQP02 CENTERING OVERLAY /A243 JMS PROV / /A243 OBCTR2 / /A243 PRJL3A, ISZ PRJPOS /Increment the number of inter-position spaces NOP /In case it skips (since it is initialized to -1) /We now find the width of the position and add it to the measure of the right /end of the line. PRJL3B, JMS PLSPCX /Get position width--the width is returned in the AC PRJL4, /M239 TAD PRRCH /Update the right end measure DCA PRRCH PRJL4F, /a274 /We now enter a sub-loop which moves the buffer pointer to the first /character of the next position. It also marks each non-backspace character /as justifiable or not with the enable flag. When we reach the next position, /we continue the main loop. If we just treated the last position, we leave /the main loop and continue with processing. PRJL4C, /A245 TAD I PLPTR /Get the character TAD PRJENB /Mark it with the enable flag DCA I PLPTR /Save the character back into the buffer JMS PLCHBS /ARE THERE MORE CHARACTERS? JMP PRJL5 /NO, LEAVE THE LOOP / these chars should be filtered out / earlier /a274 JMP PRJL4C /M274 / yes , a multinational char /a271 JMP PRJL4C /M274 /...YES, A TECHNICAL PRECEDENCE /A233 JMP PRJL4C /...YES, IN THIS POSITION /C245 JMP PRJL2 /YES, IN A NEW POSITION / IF WE SEE A TECHNICAL PRECEDENCE CHARACTER WE SUBTRACT THE /A239 / WIDTH OF THE TECHNICAL EQUIVALENT, ALREADY READ FROM THE TABLE /A239 / AND ADDED IN, SINCE WE ARE PROCESSING THE LINE BACKWARDS, AND /A239 / ADD IN THE FIXED AMOUNT OF SPACE ACCORDING TO THE PITCH /A239 PRJL4A, TAD PLWIDT / get width of tech char /a239 CIA /subtract it off /a239 / and fall thru to ADD IN WIDTH /a239 PRJL4D, JMP PRJL3B /GO ADD IT IN /M274 /A239 PRJL4B, TAD PLNRCS / GET CHAR WIDTH (VAI) /A239 JMP PRJL4 / GO ADD IT IN /A239 PRJL5, /We now determine whether or not justification is necessary. We do not /justify the line if one of the following conditions holds: /1. The line is not terminated with a soft return / and the line is naturally shorter than the right margin /2. There are no justifiable positions (PRJPOS=0). /3. The ruler does not require justification (PRRM=0). /If the line is not to be justified, we simply continue with printing /the line. AC2000 / LOAD MASK FOR SOFT RETURN /A251 AND PRJRET / IS THE RETURN A SOFT RETURN? SZA CLA / SKIP IF NOT SOFT RETURN JMP PRJL5A / IF SOFT RETURN GO CHECK FURTHER TAD PRRM / GET RULER RIGHT MARGIN (OR 0) / USE 13 BIT ARITHMETIC FOR WIDE TRACK /A248 CMA CLL / COMPUTE WHETHER LINE IS OUTSIDE OF /C248 TAD PRRCH / RULER SNL CLA / IF OUTSIDE RULER CONTINUE CHECKING /C248 JMP PRJL9A / OTHERWISE JUST PRINT LINE / -- NO JUSTIFICATION NEEDED PRJL5A, / CONTINUE WITH JUSTIFICATION CHECKS /C217 TAD PRJPOS /Are there any justifiable positions? SPA SNA CLA JMP PRJL9A /No--proceed with printing the line TAD PRRM /Does the ruler specify justification? SNA JMP PRJL9A /No--proceed with printing the line /We now determine how justification is to be done. Justification is done by /increasing or decreasing inter-position and space sizes. The options, in /their order of consideration, are: /1. The line is longer than its desired length. / Position spacing is decreased in decrements of one until the resulting / line length is less than or equal to the justified length. We then / consider the other options. /2. The line is equal to its justified length. / We need do no more and continue with printing the line. /If we reach this point in the option list, the line is shorter than its /desired length. /3. There are no justifiable spaces. / Justification is effected solely by increasing the size of / inter-position spacing. /4. Each justifiable space can be doubled in size. / Justification is effected solely by increasing the size of spaces. / This is done because the line is grossly out of justification. /5. Each position width can be increased by one unit. / This is done. if the line is too short we continue / with option 6 /6. Justification remains to be done / justification is effected soley by increasing the size of spaces / The ammount by which each inter position space is to be increased is /indicated in PLPS; the ammount by which each space is to be increased is /indicated in PLSS. Note that the numbers do not always come /out even, and some spaces must be increased by one unit more than others. /The positions or spaces suceptible to this increase are indicated by /setting bit one of the corresponding character /PRRM, which is in the ac is the desired right margin. CIA / subtract the desired line length TAD PRRCH / from the current line length /This loop shrinks the line by decreasing inter-position spacing until either /the line is too short or just right. It then jumps to treat the right case. /As each iteration begins, the AC contains the negative of the deficiency of /the line. The AC is positive if the line is too long, negative if it is too /short, and zero if it is just right. PRJL6, DCA PRJDEF /Save the negative of the deficiency TAD PRRM /Use the desired right margin DCA PRRCH /To set the current right margin TAD PRJDEF /Restore the deficiency--what is its sign? SNA JMP PRJL9A /The deficiency is zero--print the line SPA CLA JMP PRJL7 /The line must be lengthed--leave the loop /The line is too long. We decrease inter-position size by one unit and try /again. AC7777 /Decrease inter-position spacing by one unit TAD PLPS DCA PLPS TAD PRJPOS /Subtract one unit for each inter-position space CIA TAD PRJDEF /From the deficiency JMP PRJL6 /And keep shrinking the line /-------------- PAGE PRJL7, /The line must be lengthed, and the amount by which is must be stretched is /stored in PRJDEF. We now determine which of the remaining options must be /used. TAD PLNRCS /Get the character size into the AC JMS PRMULT /Determine units occupied by justifiable spaces PRJSPC SZA /Are there indeed any justifiable spaces? JMP PRJL8 /Yes--jump to choose between options 4, 5, and 6 /Option 3 holds--there are no justifiable spaces. We divide the deficiency /between the positions. TAD PRJPOS /Get the number of justifiable inter-position spaces JMS PRDVID /Divide the deficiency between them TAD PLPS /Update the amount of increased position spacing DCA PLPS / /C268 JMP PRJL9A /Continue with marking the line /Now the amount of increased position spacing is set, and the number of left /over units is recorded in PRJDEF. We continue by marking those positions /which must be sized one unit larger. /There are justifiable spaces. The AC now contains the number of units /occupied by these spaces. We first check whether option 4 holds. PRJL8, TAD PRJDEF /Add in the negative of the deficiency. If the AC /is still negative or zero, we know that the line is /grossly out of justification and justify it by /increasing space sizes. SPA SNA CLA JMP PRJL9 /Option 4 holds--jump to implement it /We now determine if option 5 or 6 holds. We see what would happen if we /increased each inter-position space by one unit. TAD PRJPOS /Get the number of positions TAD PRJDEF /Add to the negative of the deficiency SMA SZA JMP PRJL9 /Since the AC is now positive, it would be too much to /increase each inter-position space by one unit. /Hence, option 6 holds and we jump to implement it. /By elimination, option 5 holds. The AC now contains the negative of the /deficiency which the line will have when inter-position size is increased by /one unit. DCA PRJDEF /Save the new deficiency ISZ PLPS /Increase inter-position spacing. Although this /instruction could skip, it would only skip the "CLA," /which is unnecessary for this branch. /Any remaining justification must be done by increasing space sizing. PRJL9, CLA TAD PRJSPC /Get the number of spaces JMS PRDVID /Divide the deficiency among the spaces DCA PLSS /Record space sizing PRJL9A, /DECIDE WHICH TYPE B LQP02 OVERLAY TO CALL / If all filler parameters (PRJDEF, PLPS, PLSS) are all zero then that / means that no extra filler will be added so we call the JL20 overlay. / If the intercharacter spacing is negative (meaning to squish the / characters together) or the enable flag is cleared (meaning that / justification is no longer enabled at the begining of the line, / (this flag gets cleared when a "soft space" is seen, among other / things) then we take the skip return for "squish-line" JL30 / processing. If both the intercharacter spacing (PLPS) is positive / (greater than or equal to 0) and the justification flag is still set / (PRJENB = 4000) then take the 1st return for "expand-line" JL20 / justification. TAD PRJDEF / Check the filler parameters. SNA;TAD PLPS / if all of them are 0 then it is safe SNA;TAD PLSS / to call the JL20 overlay (null expand SNA CLA / skip if not certain yet. JMP PRJL9B / Return to take the JL20 overlay. JMS SKIPIF / if an LQP02 then /a273 LQP03 /skip if LQP03 /a273 JMP PRJL9B+1 / return to take the JL30 overlay /a273 TAD PLPS / Get intercharacter spacing. CMA / complement the 4000 bit. AND PRJENB / and AND it with the justification bi SPA CLA / /C227 JMP PRJL9B / SPACE WARS /A243 JMP PRJL9B+1 / SPACE WARS+1 /A243 /When this routine is called, the buffer variables point to a position. The /routine returns the spacing needed after the position is prined. If this is /the last position in the line, that width is zero. Otherwise, the width /is half the width of this position plus half the width of the next position, /plus any extra spacing needed for justificatin. /The width of the position is returned in PLPOS. The buffer variables, /although they change during execution, are restored before return. PLSPC, XX /PLCNT and PLPTR are changed in the subroutine PLWIDE. They are saved here /and restored before return. TAD PLCNT /Save the character count DCA PLCNT1 TAD PLPTR /And the buffer pointer DCA PLPTR1 /PLWIDE returns the width of the current position (PLWIDT), and bumps the /buffer pointer to point to the next position. It makes a normal return if /the current position is the last position; otherwise, it makes a skip return. JMS PLWIDE /Get the width of the current position JMP PLSPC1 /This is the last position--return zero TAD PLWIDT /Get the width DCA PLPOS /And save it /Before getting the width of the next position, we record the pointer to it /so that we can examine some pertinent bits there later. TAD PLPTR /Save the buffer pointer DCA PLPTR2 JMS PLWIDE /Get the width of the next position NOP /We don't care whether this is the last position TAD PLWIDT /Get the width TAD PLPOS /Add the widths of the two positions CLL RAR /Average them DCA PLPOS /And save the width /We now consider extra spacing requirements. If we are shadow-printing /A086 /proportional print (PLBOLD=200) then we add an extra print unit to the /A086 /position size if this char is bolded. /A086 /We also consider extra spacing due to justification. The high bit of a /character is set if it is justifiable, the next bit is set if an extra unit /is needed. We do not justify unless the current and the next positions are /both justifiable. TAD I PLPTR1 /Get the current position AND PLBOLD /See if SP bolding. /A086 SZA CLA /skip if no. /A086 ISZ PLPOS /1 more print unit for shadowed theme characters/A086 TAD I PLPTR1 /Get the current position /A086 AND I PLPTR2 /And the next one SMA CLA /Are we at a justifiable position? JMP PLSPC2 /No--perform no justification /If we are printing to the right, we add an extra unit of justification if /the current position is marked to that effect. If we are printing to the /left, we add an extra unit of justification if the next position is marked /to that effect. The important bit is bit 1. All of this is done so that /lines will print the same regardless of direction; in this way, superscripts, /underlines, normal text, and subscripts will all line up. TAD PLDIR /Which direction are we printing in? SMA CLA TAD I PLPTR1 /To the right--check the current position SNA TAD I PLPTR2 /To the left--check the next position RAL /Get the extra unit bit into AC0 SPA /Do we need extra justification? ISZ PLPOS /Yes--add it in /If the character is a space, we use extra space sizing. In any case, we use /extra position sizing. Again, we are interested in examining the current /position if we are printing to the right; the next position if we are /printing to the left. RAR /Restore the character AND P177 /Strip the mode bits TAD (-SPC) /Is it a space? SNA CLA TAD PLSS /Yes--add extra space sizing TAD PLPS /Add extra position sizing TAD PLPOS /Add to the previously calculated position size /The width of the current position is now in PLPOS. Restore the buffer /variables and return. PLSPC1, DCA PLPOS /Save the position size PLSPC2, TAD PLCNT1 /Restore the character count DCA PLCNT TAD PLPTR1 /And the buffer pointer DCA PLPTR JMP I PLSPC /And return PLCNT1, 0 /Used to store the character count upon call PLPTR1, 0 /The buffer pointer to the current position /THE FOLLOWING TEMP IS SHARED WITH THE PLREST SUBROUTINE RETURN ADDRESS /FOR SPACE SAVINGS PURPOSES. THIS SHOULD BE OK AS PLREST IS AN INITIALIZATION /ROUTINE AND SHOULD NOT BE IN USE THE SAME TIME THAT PLSPC IS IN USE...BUT /LET THE READER BEWARE OF THIS POTENTIAL TIME BOMB...HLP/A268 PLPTR2, /The buffer pointer to the next position PLREST, XX DCA PLDIR /Save the direction of printing TAD PRLBCT /Get the saved buffer count DCA PLCNT /And restore it /(PRLBUF) is the address of the first location in the buffer; PLCNT is the /negative of the number of characters in it. Therefore, if we negate PLCNT, /subtract one from the result, and add to (PRLBUF), we have the address of /the last location of the buffer. PLPTR is supposed to point to the first /buffer address to be printed, which is the first or last depending on the /direction of printing. TAD PLDIR /Get the direction of printing SMA CLA /Are we printing right-to-left? JMP PLRES1 /No--jump for this condition TAD PLCNT /Yes--get the negative of the number of /characters in the buffer CMA /At this point, the AC=0 if we are printing left-to-right, and is equal to /the offset from the first character of the last character otherwise. By /adding this value to the first buffer address, we derive the desired /value for PLPTR. PLRES1, TAD (PRLBUF) /Add the first buffer address DCA PLPTR /Save as the pointer into the buffer JMP I PLREST /And return PLSPCX, XX / RETURN ADDRESS /A080 TAD PLPTR / Save the character pointers. /A080 DCA PLSPX1 / for when we return. /A080 TAD PLCNT / Save also the character count. /A080 DCA PLSPX2 / ... /A080 JMS PLWIDE / Get width of current posn. /A080 NOP / Dont care if this is the last posn. /A080 TAD PLSPX2 / Restore the character count. /A080 DCA PLCNT / ... /A080 TAD PLSPX1 / Also restore the character pointer. /A080 DCA PLPTR / ... /A080 / /A086 /If this posn is bolded (@PLPTR 200 bit is set) and we are printing /A086 /shadowed theme (PLBOLD=200) then add an extra print unit to posn width /A086 / /A086 TAD I PLPTR / get current character. /A086 AND PLBOLD / see if supposed to add an xtra p.u. /A086 SZA CLA / Skip if not supposed to up the size. /A086 AC0001 / 1 more for the proportional shadow. /A086 TAD PLWIDT / Return the posn width in the AC. /A080 JMP I PLSPCX / Return to caller. /A080 /A080 PLSPX1, 0 / Temps for save across the call to /A080 PLSPX2, 0 / PLWIDE since it destroys them. /A080 /--------------- PAGE OVTYPE=OLB OVNUM=OVNUM+1 OVADR=OVADR+400 OVRLCA=PROVA+OVTYPE DL=DLOPRO+OVNUM /DISK BLOCK OF THIS OVERLAY FIELD OVNUM%20+3 RELOC *OVADR RELOC OVRLCA -OVNUM /At this point, all of the branches for the various options converge if /justification was indeed necessary. PLSS and PLPS have been properly set, /and PRJDEF now contains the negative of the number of inter-positions or /spaces which must be increased by one more unit. We now mark such characters /by setting their bit 1. OVJL10=.-OVRLCA /LQP01 JUSTIFICATION LOGIC. /A080 OBJL10=OVTYPE+OVNUM /Now adjust the right margin to the start of the last character posn. /A080 /It is currently set to the end of the last char posn. and we will /A080 / move the print head the width of all posns plus all added xtra 'cept /A080 / half the 1st char width and half the last char width. so now we /A080 / adjust the right margin by half the width of the 1st and last posns. /A080 / We also adjust the left margin by half the width of the 1st character /A080 / to cause proportional characters to have a smooth left margin. /A080 AC0001 / Compute the width of the 1st character posn. /A080 JMS PLRRCH / ... /A080 DCA PLRTSZ / Save size of half of right margin character. /A080 AC7777 / and half the width of the last character /A080 JMS PLRRCH / position /A080 CIA / Decrement it from the right margin (for when /A080 TAD PRRCH / we are printing right to left). /A080 DCA PRRCH / update. /A080 TAD PRJDEF / Do we need to justify (more)? /A080 SNA CLA / Skip if yes. /A080 JMP P1LINE / Go print the line. /A080 AC7777 JMS PLREST /Restore the buffer variables (PLPTR and PLCNT) /We do not want to mark the last position in the line as extra justifiable, /since the information in that line is ignored. Hence, we enter the following /loop in the right place to ignore the first position. /We have decided that the current position must not be marked. Find the next /position. PRJL11, JMS PLCHBS /Is there another character? JMP P1LINE /No--print the line JMP PRJL11 /A Multinational char /a271 JMP PRJL11 /A TECHNICAL PRECEDENCE CHR /A233 JMP PRJL11 /Yes, in this position--find the next position /Fall through if yes in a new position... /Now, we decide if the current position should be marked. If there are no /justifiable spaces, then we mark all positions; otherwise, we mark only /spaces. PRJL12, TAD PRJSPC /Are there any justifiable spaces? SZA CLA /Skip if there are not TAD I PLPTR /Get the current character AND P177 /And strip the mode bits /At this point, the AC=0 if all positions are to be marked, and contains the /current character is only spaces are to be marked. When we subtract the /space value, the AC will be zero or negative only if the current position /should be marked. TAD (-SPC) /Subtract the space value SMA SZA CLA /Skip if the position should be marked JMP PRJL11 /Don't mark this position--find the next one /Now, we mark the position unless we have run out of positions which should /be marked. ISZ PRJDEF /Are any more positions to be marked? JMP PRJL13 /Yes--mark them JMP P1LINE /No--jump to print the line /We have decided to mark all the characters in the current position. PRJL13, AC2000 /Set the marking bit TAD I PLPTR /And mark the position DCA I PLPTR PRJL14, JMS PLCHBS /Any more characters? JMP P1LINE /No--continue by printing the line JMP PRJL14 /YES, A Multinational PRECEDENCE CHR /a271 JMP PRJL14 /YES, A TECHNICAL PRECEDENCE CHR /A233 JMP PRJL13 /Yes, in this position--continue marking them JMP PRJL12 /Yes, in a new position--jump to treat them /All necessary justification calculations have been performed and printing /may commence. This loop is iterated once for each pass through the line. /There are four passes in all. PRLIN0, /At this point, the link is set if a half-line of spacing must be done. SZL /Skip if spacing is not needed TAD (PRNHL) /Get a half-line of spacing JMS PRMOVE /Transmit the move ISZ PRPASS /Increment the pass and continue with the next /iteration P1LINE, /We now decide which direction to print in. PRCCH contains the position /of the print head, and we want to start at the end of the line it is /closest to. We assume that the left end of the line is zero. Although this /may not always be true (due to leading spaces or tabs) the approximation is /a small price to pay for the space savings it yields. TAD PRRCH /Get the location of the right end of the line CLL RAR /Divide by two to find the middle CIA /Negate in order to TAD PRCCH /compare with the current head position SMA CLA /We skip if we are closer to the right margin and wish to print to the /right. AC7776 / Fall thru to set AC to -1. IAC / Set AC to +1 or -1 depending upon print direction. /At this point, the AC=+1 if we are printing to the right; AC=-1 if we /are printing to the left. JMS PLREST / Set buffer variables. /Now set the print margin to PRRCH if printing right to left or to /A080 / PLRTSZ if printing left to right. /A080 / /A080 TAD PLDIR / Get print direction. /A080 SPA CLA / Skip if printing left to right. /A080 TAD PRRCH / Get right print margin. /A080 SNA / Skip if print margin already computed. /A080 TAD PLRTSZ / Get left print margin. /A080 JMS PRESCS /Transmit the move PCMRT DCA PRCCH /And save as the new head position /This loop handles printing the line. One iteration is performed for each /position. The loop as a whole is entered once for each pass. PRLIN1, /Determine the spacing which will follow printing this position. The result, /which includes spacing due to justification, is stored in PLPOS. JMS PLSPC /Get the spacing /We now enter an inner loop which prints all of the characters in the /position. PRLIN2, /First, we process the mode bits. If the character is not to be printed /during this pass, the regular return is made; otherwise, the skip return. TAD I PLPTR /Get the character AND (1600) /Isolate the mode bits JMS PRLMOD /Process the mode bits JMP PRLIN5 /Wrong pass for this character--don't print it /Now, we set the spacing which will occur after this character is printed. /This is performed within the inner loop, instead of once for the entire /position, because there is no need to set spacing for characters which are /not even printed. Also, the routine which sets up the size updates the /head position as if the motion had already occurred, which it shortly will. TAD PLPOS /Get character size and update head position JMS PRLSCS /Set spacing and update the head position /We now check if the current character is one for which substitution must be /made. The values in PRQSB1 and PRQSB2 have been preprocessed so that this /testing works. JMS PRTST /Call code in overflow area. /M080 /We have dealt with the character by either printing it or ignoring it because /it is currently the wrong pass. We now look for the next character of this /position. There are three possibilities: /1. There are no more characters in the line--leave the main loop and begin / another pass if necessary /2. There are no more characters in the position--leave this inner loop / and iterate the main loop for another position /3. There is another character in this position--set things so a backspace / will be performed during the next mode bit processing and continue / in the inner loop. PRLIN5, JMS PLCHBS /Are there more characters? JMP PRLIN6 /No--wrap up this pass JMP PRLMN5 /YES, a MULTINATIONAL precedence char /a271 JMP PRLIN5 /YES, A TECHNICAL PRECEDENCE CHR /A233 JMP PRLIN7 /Yes, in this position. Jump out of line to deal /with the backspace. The code jumps back in line /to PRLIN2. JMP PRLIN1 /Yes, in a new position--deal with the next position /We have completed the pass. Finish up the loose ends and determine /whether another pass is needed. PRLIN6, AC7777 /Force the mode routine to reset and complete JMS PRLMOD /any pending underlining DCA PLASPC /Clear accumulated, unperformed spacing. It is not /necessary to clear immediate saved spacing because /it was cleared as a side effect of mode restoration. TAD (CR) /Transmit a carriage return JMS PRCHAR /We now must decide whether to do inter-line spacing and whether to do /another pass. TAD PRPASS /Get the current pass number CLL RAR /Encode it CML /At this point, the passes are encoded as: /1. Superscript AC=0, LINK=1 Spacing needed /2. Underline AC=0, LINK=0 No spacing needed /3. Normal AC=1, LINK=1 Spacing needed /4. Subscript AC=1, LINK=0 No spacing needed SNA SZL CLA /This skips if we were on the last pass JMP PRLIN0 /Do another pass--processing finished at top of loop JMP PRGSPC /The line is completed--continue with spacing routine /This code is out of line from the line printing routine on a previous /page. When it is invoked, a backspace has just been discovered. The current /character size is subtracted from the most recently saved character spacing. /This has the effect of cancelling out the head motion associated with the /last character printed. PRLIN7, TAD PLPOS /Get the current character size CIA TAD PLOLNC /Subtract from the most recent character spacing DCA PLOLNC /And save it JMP PRLIN2 /Continue in-line with the inner loop /This routine expects the size of the next position to be printed in the AC /upon invocation. This size is always positive. After putting the proper /sign on the spacing, it transmits the size if it has changed since the last /invocation of PRLSCS. It also updates the current head position. PRLSCS, XX JMS PRMULT /Multiply by the sign of the pass PLDIR DCA T1 /And save the spacing TAD T1 /Recover the position size TAD PRCCH /Add to the head position DCA PRCCH TAD T1 /Recover the position size CIA TAD PRLST1 /Compare with the last transmitted size SNA CLA JMP I PRLSCS /No change--return TAD T1 /Recover the position size /Both text and space sizes must be set since we don't know whether we're /dealing with a text or a space. JMS PRESCS /Set text size PCCSIZ JMS PRESCS /Set space size PCWSIZ DCA PRLST1 /Save as the last transmitted size JMP I PRLSCS /And return /we have found a mulktinational precedence char character in the buffer / just remind PRTST to deal with it when we find the real char PRLMN5, AC7777 / set flag to -1 /a271 DCA MNCFLG / flag kept in page zero /a271 JMP PRLIN5 / jump back to get the multinat char /a271 PRLST1, -1 / LAST TRANSMITTED SPACE SIZE PLRTSZ, 0 / Save for 1/2 size of 1st character posn. /A080 /--------------- PAGE /PRLMOD processes the mode bits which are passed to it in the AC upon /invocation. It makes a normal return if the mode bits indicate that the /character should not print during this pass, and makes a skip return /otherwise. The mode bits considered by this routine are in AC2,3,4 at the /time of call: /AC 2 3 / 0 0 print normally / 0 1 print with underscore / 1 0 print superscripted / 1 1 print subscripted /AC 4 / 0 not boldface / 1 boldface PRLMOD, XX /It is not necessary to give the mode bits the full treatment each time--we /need only do that every time they change. The location PRLSWT is patched /with a jump to the section of the routine appropriate for the mode bits /should they not change. First, we determine whether the mode bits have /indeed changed. We take the patched jump if they haven't; otherwise, we /give them the full treatment. /Notice that if we are called with AC=7777, this will be treated as a new /set of bits which don't belong to any pass. The net effect is to complete /any pending underlining and reset some variables. This trick is used when /finishing a pass and wishing to reset for the next one. CIA /Negate the mode bits TAD PRLMDB /Compare with the old ones SNA PRLSWT, XX /The mode bits haven't changed since last time, so /we can take this jump which was patched with a jump /to the section appropriate to this type of bits. /The mode bits have changed. We recover the new bits, save them, and proceed /to deal with them. CIA /Recover the new bits TAD PRLMDB DCA PRLMDB /And save them /If the underline flag is set, we invoke PRUNDL to perform accumulated /underlining. Notice that the net effect is that underlining is performed /in spurts when the mode changes. TAD PRUFLG /Check the underlining flag SZA CLA JMS PRUNDL /Do underlining if necessary DCA PRUFLG /Clear the flag /Now, we determine whether or not the current character belongs to this pass. /We branch accordingly. TAD PRLMDB /Get the mode bits CLL BSW /And move them into the lower two bits of the AC RTR TAD (-2) /After these manipulations... SMA SZA AC7775 /...the AC has the following values... /AC=0 superscript /AC=-1 underline /AC=-2 normal /AC=-3 subscript /...while PRPASS, which identifies the current pass, has these values... /PRPASS=0 superscript /PRPASS=1 underline /PRPASS=2 normal /PRPASS=3 subscript /...so we need only compare the two values. TAD PRPASS /Are we in the right pass? SZA CLA JMP PRLMO4 /No--jump to handle it /We are in the right pass. The first we must do is set the hit count. We /begin by putting the bold bit into the link. TAD PRLMDB /Get the mode bits BSW /And put the bold bit into the link RTR CLA /We must concern ourselves with three values: /1. The bold bit (now in the link) /2. The two wheel flag (PRQ2W) /3. The darkness value (PRQOVP) /If two-wheel printing is specified, the bold bit takes on a different /significance. TAD PRQ2W /Get the two wheel flag SNA /If AC=0, no two-wheel JMP PRLMO1 /Jump to handle regular printing /This section deals with two-wheel printing. /If PRQ2W is negative, this is the first pass. Only non-bold text is printed, / with a hit count equal to the darkness value. /If PRQ2W is positive, this is the second pass. Only bold text is printed, / with a hit count equal to the darkness value. /If text is not to be printed, the hit count is set negative. SMA CLA /If this is the first pass, the skip occurs. In this pass, we want to print /only the non-bold text; i.e., print only if the link is clear. If this is /the second pass, the skip does not occur. In thispass, we want to print /only the bold text; i.e., print only if the link is set. /Now, if this is the second pass and we complement the link, we will want to /print then only if the link is clear and the two cases become identical. CML /Second pass--complement the link and the two cases /become identical. /Now we print only if the link is clear. SZL /Skip if we need to print during this two-wheel pass AC7777 /Otherwise, get a -1 into the AC CLL /At this point, we rejoin the code for the non-wheel case. The possibilities /are as follows: /1. Not two wheel, not bold: AC=0, LINK=0 /2. Not two-wheel, bold: AC=0, LINK=1 /3. Two-wheel, printing AC=0, LINK=0 /4. Two-wheel, not printing: AC=-1,LINK=0 /So, after performing an RAL, we have the following corresponding cases: /1. Not two-wheel, not bold: AC=0 /2. Not two-wheel, bold: AC=1 /3. Two-wheel, printing: AC=0 /4. Two-wheel, not printing: AC=-2 /Upon adding the darkness, we will have the proper hit count for each case. PRLMO1, RAL /Get the hit count /M019 TAD PRQOVP /Add in the darkness value JMS PRESCS /And send it PCBOLD CLA /This is the point to which the routine branches if the mode bits haven't /changed and the last mode bits indicated the character belonged to the /current pass. The first thing which is always done for the proper pass /is to perform any spacing which has accumulated while characters which were /not in this pass were printing. There are several things to note about /the variables which record this motion: /PLOLNC is the amount that accumulated on the last character only. It is / kept separate because these accumualted spacing variables are used / in underlining also, and when underlining we do not want to underline / the most recent character. /PLASPC is the amount that has accumulated on all previous characters. /When a backspace is encountered, the current position size PLPOS is / subtracted from PLOLNC. If we were in the wrong pass, it is as if / no spacing had ever been included in PLOLNC; if we are in the wrong / pass, a backspace is performed the next time this section is reached. /This branch is not used for characters which belong to the underlining pass; / rather, the spacing is allowed to accumulate and it is performed all / at once when an underline is produced. PRLMO2, TAD PLOLNC /We want to move this distance in addition to the /distance in PLASPC which PLHMOV will perform /automatically JMS PLHMOV /Do the spacing DCA PLOLNC /PLHMOV clears PLASPC automatically; we also want /to clear this value to indicate the motion has /been performed /As noted above, if we are printing the underline pass, we make believe we /are not printing and merely accumulate space. When the mode changes again, /the underlining will be performed as above. AC7777 TAD PRPASS /Are we printing the underline pass? SNA CLA JMP PRLMO3 /Yes--jump to treat it /We must print a character during this pass. A skip return is called for. ISZ PRLMOD /Prepare a skip return TAD (S1-S2) /Set the switch so that until the mode changes, /characters will be treated as they deserve to /be printed JMP PRLMO6 /Jump to set the switch and return /This point is reached if the mode bits just changed and underlining was /enabled. We set the flag to indicate underline is in progress. The next /time the mode changes, the underlining routine will underline the space /which has accumulated since this time. PRLMO3, AC7777 DCA PRUFLG /Set the flag to indicate underlining in progress /This is the section to which characters of the wrong mode and underlined /characters (during the underline pass) are directed. PRLMO4, /If the underline flag is set, this is the underline pass and the current /character is in underline mode. We therefore clear the mode bits of /the character so it will be print in the next (regular) pass as well. TAD PRUFLG /Get the underline flag SNA CLA JMP PRLMO5 /Not underlining--don't fool with the mode bits TAD I PLPTR /Get the character AND (6377) /Clear the pass-significant mode bits DCA I PLPTR /And replace it in the buffer /The spacing occupied by this character is updated. Finally, we set the /switch for succeeding characters of the same mode and make a regular return. PRLMO5, TAD PLOLNC /Add the spacing of the last character TAD PLASPC /To the accumulated, unperformed spacing DCA PLASPC /And save it away TAD PLPOS /Save the current position spacing DCA PLOLNC /As the spacing of the last character PRLMO6, TAD (S2) /Set the switching value DCA PRLSWT JMP I PRLMOD /And return PRLMDB, -1 /The mode bits of the last character are recorded here. /After each pass they are set to -1 to force reconsideration /at the beginning of each new pass. /mode for printing during the current pass. PRUFLG, 0 /The underline flag--it is non-zero if underlining is /in progress; zero otherwise. S1=JMP PRLMO2 /The switch value to direct unchanged-mode characters which /are in the correct pass S2=JMP PRLMO4 /The switch value to direct unchanged-mode characters which /are in the wrong pass /This routine performs horizontal motion. It adds the amount of motion /in the AC to the amount in PLASPC (accumulated, unperformed horizontal /motion), places the correct sign on them, performs the move, updates PRCCH /(the head position) and clears PLASPC. PLHMOV, XX TAD PLASPC /Add accumulated space to the amount in the AC MQL /And save it TAD PLDIR /Get the direction of printing RAL /Save the sign of the motion in the LINK ACL /Recover the amount of motion SZL CIA /Negate if motion to the left SZA /Transmit motion only if non-zero JMS PRESCS PCMRT /If the skip is taken, this instruction will only /be a harmless AND TAD PRCCH /Update head position DCA PRCCH DCA PLASPC /Clear accumulated motion JMP I PLHMOV /And return ACL=7701 /An instruction to load the MQ into the AC. The assembler /doesn't know about it for some reason. /The following routine returns half the position size of the 1st or /A080 / last posn in the line. it is called with AC=1 for 1st and /A080 / AC=7777 for last. /A080 PLRRCH, XX / Entry point. /A080 JMS PLREST / Set buffer pointers. /A080 JMS PLWIDE / Get character width. /A080 NOP / dont care if no more in the line. /A080 TAD PLWIDT / Get character width. /A080 CLL RAR / divide by 2. /A080 JMP I PLRRCH / return to caller. /A080 /--------------- PAGE OVTYPE=OLB OVNUM=OVNUM+1 OVADR=OVADR+400 OVRLCA=PROVA+OVTYPE DL=DLOPRO+OVNUM /DISK BLOCK OF THIS OVERLAY FIELD OVNUM%20+3 RELOC *OVADR RELOC OVRLCA -OVNUM /***********************************************************************/ / / / OV2L10--LQP02/03 NORMAL JUSTIFICATION OVERLAY / / USED WHEN THERE IS NO JUSTIFICATION NEEDED / / OR WHEN JUSTIFICATION CAN BE ACCOMPLISHED USING / / THE JUSTIFICATION COMMAND DECFIL, WHICH ONLY / / ALLOWS FOR EXPANDING THE LINE. IF THE LINE NEEDS TO / / BE SQUISHED, WE WILL USE OV3L10. / / / /***********************************************************************/ OV2L10=.-OVRLCA / LQP02 "EXPAND-LINE" JUSTIFICATION LOGIC/A080 OB2L10=OVTYPE+OVNUM IFNZRO OV2L10-OVJL10