* Macros to Center Lines, Paragraphs and Documents, v1.0 * CENTER10.QM * * Here are three handy macros to center text: * * @1 Centers line, moves to next line * @2 Centers paragraph, moves to next paragraph * @3 Centers entire document * 旼컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴커 * �@1 Centers line, moves to next � * 읕컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴켸 * To run place cursor line on desired line to center and press * Alt & 1 at the same time. * @1 macrobegin * centerline * center line cursordown * move to next line * * 6 bytes Sat 08-25-1990 12:13:33 * 旼컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴� * �@2 Centers all lines in a paragraph, moves to next paragraph � * 읕컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴� * To run place cursor line in a paragraph to center and press * Alt & 2 at the same time. * @2 macrobegin cursordown * move down one line * stays in para if @ col/lin 1/1 prevpara * go to paragraph begin CENTERPARA: * endline begline * blank line? Jfalse AGAIN: * if blank, go to next paragraph centerline * center line cursordown * move to next line Jump CENTERPARA: * continue centering AGAIN: * nextpara * go to next paragraph when done makectrofscreen * better viewing * * 18 bytes Sat 08-25-1990 12:13:44 * 旼컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴� * �@3 Centers entire document, supplied by Robert Danek � * 읕컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴컴� * To run press Alt & 3 at the same time with cursor line anywhere * in the document. * @3 Macrobegin * Macro to Center entire text. endfile * Test for trailing blank lines. LABEL0: endline begline * " " " " " " " " " Jtrue LABEL1: * If not, then begin centering DelLine * Delete trailing blank. CursorUp * Go up. Jump LABEL0: * Retest. LABEL1: begfile * Go to the beginning of your text. LABEL2: endline begline *\ Tests whether there's anything jtrue LABEL3: */ to center. cursordown * If there isn't, go to next line. jump LABEL2: LABEL3: MarkLine CenterLine *\ Centers the current UnmarkBlock */ line of text. CursorDown * Check for eof. jfalse LABEL4: * If yes, go to ending. jump LABEL2: * Repeat test LABEL4: begfile * Return to the top. * * 36 bytes Sat 08-25-1990 14:22:46 * * Tom Hogshead Sat 08-25-1990 16:36:25