diff --git a/library/TEDIT b/library/TEDIT
index d366eba4..e4939206 100644
--- a/library/TEDIT
+++ b/library/TEDIT
@@ -1,12 +1,12 @@
 (DEFINE-FILE-INFO PACKAGE "INTERLISP" READTABLE "INTERLISP" BASE 10)
 
-(FILECREATED "29-Sep-2021 22:16:28" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDIT.;11 142247 
+(FILECREATED "13-Oct-2021 10:00:40" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDIT.;19 142287 
 
       changes to%:  (FNS TEDIT-SEE)
 
-      previous date%: "19-Sep-2021 17:08:56" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDIT.;5)
+      previous date%: "11-Oct-2021 14:03:12" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDIT.;18)
 
 
 (* ; "
@@ -330,7 +330,7 @@ Copyright (c) 1983-1993, 1995, 1999, 2018, 2021 by Venue & Xerox Corporation.
                 (RETURN PROC])
 
 (TEDIT-SEE
-  [LAMBDA (FILE WINDOW FORMAT)                          (* ; "Edited 29-Sep-2021 22:16 by rmk:")
+  [LAMBDA (FILE WINDOW FORMAT)                          (* ; "Edited 13-Oct-2021 10:00 by rmk:")
                                                             (* ; "Edited 27-Feb-2021 20:07 by rmk:")
                                                              (* ; "Edited  1-Feb-88 19:00 by bvm:")
 
@@ -340,18 +340,18 @@ Copyright (c) 1983-1993, 1995, 1999, 2018, 2021 by Venue & Xerox Corporation.
 
     (CL:WITH-OPEN-FILE (STREAM FILE :DIRECTION :INPUT)
            (LET ((SEESTREAM STREAM)
-                 ENV TSTREAM)
+                 TSTREAM)
 
                 (* ;; "No need to fiddle with a TEDIT file")
 
                 (IF (\TEDIT.FORMATTEDP1 STREAM)
-                  ELSEIF (SETQ ENV (LISPSOURCEFILEP STREAM))
+                  ELSEIF (LISPSOURCEFILEP STREAM)
                     THEN 
 
                           (* ;; "Lisp source file")
 
-                          (SETFILEINFO STREAM 'FORMAT ENV)
                           (SETQ SEESTREAM (OPENTEXTSTREAM))
+                          (DSPFONT DEFAULTFONT SEESTREAM)
                           (COPY.TEXT.TO.IMAGE STREAM SEESTREAM)
                   ELSE 
 
@@ -360,11 +360,12 @@ Copyright (c) 1983-1993, 1995, 1999, 2018, 2021 by Venue & Xerox Corporation.
                         (* ;; "Maybe there is a conventional way of finding out the external format of a plain-text stream (an EMACS header?), here we nudge towards :UTF-8 (if it exists).")
 
                         (SETFILEINFO STREAM 'FORMAT (OR FORMAT (FIND-FORMAT :UTF-8)
-                                                        *DEFAULT-EXTERNALFORMAT*))
+                                                        :DEFAULT))
                         (CL:UNLESS (RANDACCESSP STREAM)
                             (SETQ SEESTREAM (OPENSTREAM '{NODIRCORE} 'BOTH 'NEW))
                             (COPYCHARS STREAM SEESTREAM)))
-                [SETQ TSTREAM (TEXTSTREAM (TEDIT SEESTREAM WINDOW NIL '(READONLY T]
+                [SETQ TSTREAM (TEXTSTREAM (TEDIT SEESTREAM WINDOW NIL
+                                                     `(READONLY T FONT ,DEFAULTFONT]
                 (WINDOWPROP (WFROMDS TSTREAM)
                        'TITLE
                        (CONCAT "SEE window for " (FULLNAME STREAM)))
@@ -2235,7 +2236,7 @@ Copyright (c) 1983-1993, 1995, 1999, 2018, 2021 by Venue & Xerox Corporation.
 (* ; "TEDIT Support information")
 
 
-(RPAQQ TEDITSYSTEMDATE "29-Sep-2021 22:16:28")
+(RPAQQ TEDITSYSTEMDATE "13-Oct-2021 10:00:40")
 
 (RPAQ TEDITSUPPORT "TEditSupport.PA")
 (DEFINEQ
@@ -2261,19 +2262,19 @@ Copyright (c) 1983-1993, 1995, 1999, 2018, 2021 by Venue & Xerox Corporation.
 (PUTPROPS TEDIT COPYRIGHT ("Venue & Xerox Corporation" 1983 1984 1985 1986 1987 1988 1989 1990 1991 
 1992 1993 1995 1999 2018 2021))
 (DECLARE%: DONTCOPY
-  (FILEMAP (NIL (4329 117413 (\TEDIT2 4339 . 7090) (COERCETEXTOBJ 7092 . 15868) (TEDIT 15870 . 20839) (
-TEDIT-SEE 20841 . 23089) (TEDIT.CHARWIDTH 23091 . 25115) (TEDIT.COPY 25117 . 33553) (TEDIT.DELETE 
-33555 . 34245) (TEDIT.DO.BLUEPENDINGDELETE 34247 . 37314) (TEDIT.INSERT 37316 . 42846) (TEDIT.KILL 
-42848 . 44405) (TEDIT.MAPLINES 44407 . 45806) (TEDIT.MAPPIECES 45808 . 46764) (TEDIT.MOVE 46766 . 
-56550) (TEDIT.QUIT 56552 . 58552) (TEDIT.STRINGWIDTH 58554 . 59225) (TEDIT.\INSERT 59227 . 61252) (
-TEXTOBJ 61254 . 62379) (TEXTSTREAM 62381 . 63996) (\TEDIT.INCLUDE 63998 . 67898) (\TEDIT.INSERT.PIECES
- 67900 . 77815) (\TEDIT.MOVE.PIECEMAPFN 77817 . 79896) (\TEDIT.OBJECT.SHOWSEL 79898 . 83527) (
-\TEDIT.RESTARTFN 83529 . 85524) (\TEDIT.CHARDELETE 85526 . 89488) (\TEDIT.COPY.PIECEMAPFN 89490 . 
-92715) (\TEDIT.DELETE 92717 . 100235) (\TEDIT.DIFFUSE.PARALOOKS 100237 . 103001) (\TEDIT.FOREIGN.COPY?
- 103003 . 106730) (\TEDIT.QUIT 106732 . 109878) (\TEDIT.WORDDELETE 109880 . 114713) (\TEDIT1 114715 . 
-117411)) (117527 117643 (\CREATE.TEDIT.RESTART.MENU 117537 . 117641)) (117742 121431 (PLCHAIN 117752
- . 118026) (PRINTLINE 118028 . 120792) (SEEFILE 120794 . 121429)) (121472 141115 (TEDIT.INSERT.OBJECT 
-121482 . 130559) (TEDIT.EDIT.OBJECT 130561 . 132817) (TEDIT.FIND.OBJECT 132819 . 133712) (
-TEDIT.FIND.OBJECT.SUBTREE 133714 . 134520) (TEDIT.PUT.OBJECT 134522 . 136181) (TEDIT.GET.OBJECT 136183
- . 139382) (TEDIT.OBJECT.CHANGED 139384 . 141113)) (141393 141756 (MAKETEDITFORM 141403 . 141754)))))
+  (FILEMAP (NIL (4330 117453 (\TEDIT2 4340 . 7091) (COERCETEXTOBJ 7093 . 15869) (TEDIT 15871 . 20840) (
+TEDIT-SEE 20842 . 23129) (TEDIT.CHARWIDTH 23131 . 25155) (TEDIT.COPY 25157 . 33593) (TEDIT.DELETE 
+33595 . 34285) (TEDIT.DO.BLUEPENDINGDELETE 34287 . 37354) (TEDIT.INSERT 37356 . 42886) (TEDIT.KILL 
+42888 . 44445) (TEDIT.MAPLINES 44447 . 45846) (TEDIT.MAPPIECES 45848 . 46804) (TEDIT.MOVE 46806 . 
+56590) (TEDIT.QUIT 56592 . 58592) (TEDIT.STRINGWIDTH 58594 . 59265) (TEDIT.\INSERT 59267 . 61292) (
+TEXTOBJ 61294 . 62419) (TEXTSTREAM 62421 . 64036) (\TEDIT.INCLUDE 64038 . 67938) (\TEDIT.INSERT.PIECES
+ 67940 . 77855) (\TEDIT.MOVE.PIECEMAPFN 77857 . 79936) (\TEDIT.OBJECT.SHOWSEL 79938 . 83567) (
+\TEDIT.RESTARTFN 83569 . 85564) (\TEDIT.CHARDELETE 85566 . 89528) (\TEDIT.COPY.PIECEMAPFN 89530 . 
+92755) (\TEDIT.DELETE 92757 . 100275) (\TEDIT.DIFFUSE.PARALOOKS 100277 . 103041) (\TEDIT.FOREIGN.COPY?
+ 103043 . 106770) (\TEDIT.QUIT 106772 . 109918) (\TEDIT.WORDDELETE 109920 . 114753) (\TEDIT1 114755 . 
+117451)) (117567 117683 (\CREATE.TEDIT.RESTART.MENU 117577 . 117681)) (117782 121471 (PLCHAIN 117792
+ . 118066) (PRINTLINE 118068 . 120832) (SEEFILE 120834 . 121469)) (121512 141155 (TEDIT.INSERT.OBJECT 
+121522 . 130599) (TEDIT.EDIT.OBJECT 130601 . 132857) (TEDIT.FIND.OBJECT 132859 . 133752) (
+TEDIT.FIND.OBJECT.SUBTREE 133754 . 134560) (TEDIT.PUT.OBJECT 134562 . 136221) (TEDIT.GET.OBJECT 136223
+ . 139422) (TEDIT.OBJECT.CHANGED 139424 . 141153)) (141433 141796 (MAKETEDITFORM 141443 . 141794)))))
 STOP
diff --git a/library/TEDIT.LCOM b/library/TEDIT.LCOM
index 419aa50d..630abb32 100644
Binary files a/library/TEDIT.LCOM and b/library/TEDIT.LCOM differ
diff --git a/library/TEDITWINDOW b/library/TEDITWINDOW
index ae1a86b5..01ecefd2 100644
--- a/library/TEDITWINDOW
+++ b/library/TEDITWINDOW
@@ -1,11 +1,12 @@
 (DEFINE-FILE-INFO PACKAGE "INTERLISP" READTABLE "INTERLISP" BASE 10)
-(FILECREATED "19-Sep-2021 23:11:04" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDITWINDOW.;10 186372 
 
-      changes to%:  (FNS \TEDIT.SCROLLFN)
+(FILECREATED "12-Oct-2021 15:10:06" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDITWINDOW.;16 187619 
 
-      previous date%: "19-Sep-2021 22:58:18" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDITWINDOW.;9)
+      changes to%:  (FNS \TEDIT.BUTTONEVENTFN)
+
+      previous date%: "12-Oct-2021 15:01:30" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEDITWINDOW.;15)
 
 
 (* ; "
@@ -25,6 +26,9 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
              \TEDIT.WINDOW.OPS \TEDIT.EXPANDFN \TEDIT.MAINW \TEDIT.PRIMARYW \TEDIT.COPYINSERTFN 
              \TEDIT.NEWREGIONFN \TEDIT.SET.WINDOW.EXTENT \TEDIT.SHRINK.ICONCREATE \TEDIT.SHRINKFN 
              \TEDIT.SPLITW \TEDIT.UNSPLITW \TEDIT.WINDOW.SETUP \SAFE.FIRST)
+        (INITVARS (\TEDIT.OP.WIDTH 12)
+               (\TEDIT.OP.BOTTOM 12))
+        (DECLARE%: DONTEVAL@LOAD DOCOPY (GLOBALVARS \TEDIT.OP.WIDTH \TEDIT.OP.BOTTOM))
         (CURSORS BXCARET BXHICARET TEDIT.LINECURSOR \TEDIT.SPLITCURSOR \TEDIT.MOVESPLITCURSOR 
                \TEDIT.UNSPLITCURSOR \TEDIT.MAKESPLITCURSOR)
         (INITVARS (TEDIT.DEFAULT.WINDOW NIL))
@@ -156,7 +160,7 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
     TEDIT.DEFAULT.WINDOW])
 
 (TEDIT.CURSORMOVEDFN
-  [LAMBDA (W)                                            (* ; "Edited 30-May-91 23:39 by jds")
+  [LAMBDA (W)                                           (* ; "Edited 12-Oct-2021 13:14 by rmk:")
 
          (* Watch the mouse and change the cursor to reflect the region of the window 
        it's in (line select, window split eventually?))
@@ -187,13 +191,18 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
                                                                           of LINE]
                 (SELECTQ (fetch (TEXTOBJ MOUSEREGION) of TEXTOBJ)
                     (TEXT [COND
-                             ((IGEQ X (SETQ LEFT (IDIFFERENCE (fetch (TEXTOBJ WRIGHT)
-                                                                 of TEXTOBJ)
-                                                        8)))
+                             ((AND (IGEQ X (SETQ LEFT (IDIFFERENCE (fetch (TEXTOBJ WRIGHT)
+                                                                      of TEXTOBJ)
+                                                             \TEDIT.OP.WIDTH)))
+                                   (IGEQ Y (IPLUS (fetch (TEXTOBJ WBOTTOM) of TEXTOBJ)
+                                                  \TEDIT.OP.BOTTOM)))
+
+                              (* ;; "The region to the right of text, for splitting operations.")
+
                               (CURSOR \TEDIT.SPLITCURSOR)
                               (replace (TEXTOBJ MOUSEREGION) of TEXTOBJ with 'WINDOW)
                               (replace LEFT of CURSORREG with LEFT)
-                              (replace WIDTH of CURSORREG with 8))
+                              (replace WIDTH of CURSORREG with \TEDIT.OP.WIDTH))
                              ([ILESSP X (SETQ LEFT
                                          (OR [AND LINE (COND
                                                           ((fetch (FMTSPEC FMTHARDCOPY)
@@ -221,13 +230,15 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
                                                                                     of TEXTOBJ)
                                                                            (IPLUS LEFT 8])
                     (LINE (COND
-                             ((IGEQ X (SETQ LEFT (IDIFFERENCE (fetch (TEXTOBJ WRIGHT)
-                                                                 of TEXTOBJ)
-                                                        8)))
+                             ((AND (IGEQ X (SETQ LEFT (IDIFFERENCE (fetch (TEXTOBJ WRIGHT)
+                                                                      of TEXTOBJ)
+                                                             \TEDIT.OP.WIDTH)))
+                                   (IGEQ Y (IPLUS (fetch (TEXTOBJ WBOTTOM) of TEXTOBJ)
+                                                  \TEDIT.OP.BOTTOM)))
                               (CURSOR \TEDIT.SPLITCURSOR)
                               (replace (TEXTOBJ MOUSEREGION) of TEXTOBJ with 'WINDOW)
                               (replace LEFT of CURSORREG with LEFT)
-                              (replace WIDTH of CURSORREG with 8))
+                              (replace WIDTH of CURSORREG with \TEDIT.OP.WIDTH))
                              [[IGEQ X (SETQ LEFT (OR [AND LINE (COND
                                                                   ((fetch (FMTSPEC FMTHARDCOPY)
                                                                       of (fetch (
@@ -256,13 +267,15 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
                              (T (replace LEFT of CURSORREG with 0)
                                 (replace WIDTH of CURSORREG with LEFT))))
                     (WINDOW (COND
-                               ((IGEQ X (SETQ LEFT (IDIFFERENCE (fetch (TEXTOBJ WRIGHT)
-                                                                   of TEXTOBJ)
-                                                          8)))
+                               ((AND (IGEQ X (SETQ LEFT (IDIFFERENCE (fetch (TEXTOBJ WRIGHT)
+                                                                        of TEXTOBJ)
+                                                               \TEDIT.OP.WIDTH)))
+                                     (IGEQ Y (IPLUS (fetch (TEXTOBJ WBOTTOM) of TEXTOBJ)
+                                                    \TEDIT.OP.BOTTOM)))
                                 (replace (TEXTOBJ MOUSEREGION) of TEXTOBJ with
                                                                                   'WINDOW)
                                 (replace LEFT of CURSORREG with LEFT)
-                                (replace WIDTH of CURSORREG with 8))
+                                (replace WIDTH of CURSORREG with \TEDIT.OP.WIDTH))
                                ([IGEQ X (SETQ LEFT
                                          (OR [AND LINE (COND
                                                           ((fetch (FMTSPEC FMTHARDCOPY)
@@ -795,17 +808,18 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
                               'SELECTED OSEL (fetch (TEXTOBJ STREAMHINT) of TEXTOBJ])])
 
 (\TEDIT.WINDOW.OPS
-  [LAMBDA (TEXTOBJ WINDOWTOSPLIT)                        (* ; "Edited 30-May-91 23:33 by jds")
+  [LAMBDA (TEXTOBJ WINDOWTOSPLIT)                       (* ; "Edited 12-Oct-2021 15:01 by rmk:")
 
 (* ;;; "Do window operations for TEdit, e.g., splitting a window, moving the split location, or unsplitting.")
 
     (PROG ([WINDOWOPREGION (create REGION
                                   LEFT _ (DIFFERENCE (fetch (TEXTOBJ WRIGHT) of TEXTOBJ)
-                                                8)
-                                  BOTTOM _ 0
-                                  WIDTH _ 8
-                                  HEIGHT _ (fetch HEIGHT of (WINDOWPROP WINDOWTOSPLIT
-                                                                           'REGION]
+                                                \TEDIT.OP.WIDTH)
+                                  BOTTOM _ \TEDIT.OP.BOTTOM
+                                  WIDTH _ \TEDIT.OP.WIDTH
+                                  HEIGHT _ (fetch (REGION HEIGHT) of (WINDOWPROP 
+                                                                                    WINDOWTOSPLIT
+                                                                                    'REGION]
            Y OPERATION)
           [while [AND (MOUSESTATE (OR LEFT MIDDLE RIGHT))
                           (INSIDE? WINDOWOPREGION (LASTMOUSEX WINDOWTOSPLIT)
@@ -845,7 +859,7 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
                            (\TEDIT.UNSPLITW WINDOWTOSPLIT))
                   (MOVE                                      (* ; 
                                                            "Moving the divider between two panes.")
-                        (TEDIT.PROMPTPRINT TEXTOBJ "Can't move the split point yet." T))
+                        (TEDIT.PROMPTPRINT TEXTOBJ "Split-point moving is not yet implemented" T))
                   (SHOULDNT)))
              (T (CURSOR T])
 
@@ -1366,6 +1380,16 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
         (CAR LIST.OR.ATOM))
        (T LIST.OR.ATOM])
 )
+
+(RPAQ? \TEDIT.OP.WIDTH 12)
+
+(RPAQ? \TEDIT.OP.BOTTOM 12)
+(DECLARE%: DONTEVAL@LOAD DOCOPY 
+(DECLARE%: DOEVAL@COMPILE DONTCOPY
+
+(GLOBALVARS \TEDIT.OP.WIDTH \TEDIT.OP.BOTTOM)
+)
+)
 (RPAQ BXCARET (CURSORCREATE (QUOTE #*(16 16)@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@A@@@CH@@CH@@FL@@FL@@LF@@
 ) (QUOTE NIL) 3 4))
 (RPAQ BXHICARET (CURSORCREATE (QUOTE #*(16 16)A@@@A@@@A@@@A@@@A@@@A@@@A@@@A@@@CH@@GL@@FL@@LF@@HB@@@@@@@@@@@@@@
@@ -2830,25 +2854,25 @@ Copyright (c) 1983-1991, 1993-1994, 1999, 2021 by John Sybalsky & Xerox Corporat
 (PUTPROPS TEDITWINDOW COPYRIGHT ("John Sybalsky & Xerox Corporation" 1983 1984 1985 1986 1987 1988 
 1989 1990 1991 1993 1994 1999 2021))
 (DECLARE%: DONTCOPY
-  (FILEMAP (NIL (7117 93041 (TEDIT.CREATEW 7127 . 8263) (\TEDIT.CREATEW.FROM.REGION 8265 . 9249) (
-TEDIT.CURSORMOVEDFN 9251 . 19903) (TEDIT.CURSOROUTFN 19905 . 20440) (TEDIT.WINDOW.SETUP 20442 . 22251)
- (TEDIT.MINIMAL.WINDOW.SETUP 22253 . 30042) (\TEDIT.ACTIVE.WINDOWP 30044 . 31025) (
-\TEDIT.BUTTONEVENTFN 31027 . 56017) (\TEDIT.WINDOW.OPS 56019 . 59822) (\TEDIT.EXPANDFN 59824 . 60227) 
-(\TEDIT.MAINW 60229 . 61518) (\TEDIT.PRIMARYW 61520 . 62732) (\TEDIT.COPYINSERTFN 62734 . 63705) (
-\TEDIT.NEWREGIONFN 63707 . 66174) (\TEDIT.SET.WINDOW.EXTENT 66176 . 72278) (\TEDIT.SHRINK.ICONCREATE 
-72280 . 74552) (\TEDIT.SHRINKFN 74554 . 75129) (\TEDIT.SPLITW 75131 . 81232) (\TEDIT.UNSPLITW 81234 . 
-86928) (\TEDIT.WINDOW.SETUP 86930 . 92650) (\SAFE.FIRST 92652 . 93039)) (94187 95094 (TEDITWINDOWP 
-94197 . 95092)) (95131 97627 (TEDIT.GETINPUT 95141 . 97124) (\TEDIT.MAKEFILENAME 97126 . 97625)) (
-97676 104127 (TEDIT.PROMPTPRINT 97686 . 100590) (TEDIT.PROMPTFLASH 100592 . 102547) (
-\TEDIT.PROMPT.PAGEFULLFN 102549 . 104125)) (104362 108424 (TEXTSTREAM.TITLE 104372 . 104993) (
-\TEDIT.ORIGINAL.WINDOW.TITLE 104995 . 107040) (\TEDIT.WINDOW.TITLE 107042 . 107712) (
-\TEXTSTREAM.FILENAME 107714 . 108422)) (108467 153208 (TEDIT.DEACTIVATE.WINDOW 108477 . 115626) (
-\TEDIT.REPAINTFN 115628 . 118485) (\TEDIT.RESHAPEFN 118487 . 124107) (\TEDIT.SCROLLFN 124109 . 153206)
-) (153250 155299 (\TEDIT.PROCIDLEFN 153260 . 154609) (\TEDIT.PROCENTRYFN 154611 . 154904) (
-\TEDIT.PROCEXITFN 154906 . 155297)) (155378 166378 (\EDIT.DOWNCARET 155388 . 156069) (\EDIT.FLIPCARET 
-156071 . 157606) (TEDIT.FLASHCARET 157608 . 158722) (\EDIT.UPCARET 158724 . 159177) (
-TEDIT.NORMALIZECARET 159179 . 165130) (\SETCARET 165132 . 166052) (\TEDIT.CARET 166054 . 166376)) (
-166412 180167 (TEDIT.ADD.MENUITEM 166422 . 168337) (TEDIT.DEFAULT.MENUFN 168339 . 177606) (
-TEDIT.REMOVE.MENUITEM 177608 . 178609) (\TEDIT.CREATEMENU 178611 . 179064) (\TEDIT.MENU.WHENHELDFN 
-179066 . 179836) (\TEDIT.MENU.WHENSELECTEDFN 179838 . 180165)))))
+  (FILEMAP (NIL (7288 94104 (TEDIT.CREATEW 7298 . 8434) (\TEDIT.CREATEW.FROM.REGION 8436 . 9420) (
+TEDIT.CURSORMOVEDFN 9422 . 20808) (TEDIT.CURSOROUTFN 20810 . 21345) (TEDIT.WINDOW.SETUP 21347 . 23156)
+ (TEDIT.MINIMAL.WINDOW.SETUP 23158 . 30947) (\TEDIT.ACTIVE.WINDOWP 30949 . 31930) (
+\TEDIT.BUTTONEVENTFN 31932 . 56922) (\TEDIT.WINDOW.OPS 56924 . 60885) (\TEDIT.EXPANDFN 60887 . 61290) 
+(\TEDIT.MAINW 61292 . 62581) (\TEDIT.PRIMARYW 62583 . 63795) (\TEDIT.COPYINSERTFN 63797 . 64768) (
+\TEDIT.NEWREGIONFN 64770 . 67237) (\TEDIT.SET.WINDOW.EXTENT 67239 . 73341) (\TEDIT.SHRINK.ICONCREATE 
+73343 . 75615) (\TEDIT.SHRINKFN 75617 . 76192) (\TEDIT.SPLITW 76194 . 82295) (\TEDIT.UNSPLITW 82297 . 
+87991) (\TEDIT.WINDOW.SETUP 87993 . 93713) (\SAFE.FIRST 93715 . 94102)) (95434 96341 (TEDITWINDOWP 
+95444 . 96339)) (96378 98874 (TEDIT.GETINPUT 96388 . 98371) (\TEDIT.MAKEFILENAME 98373 . 98872)) (
+98923 105374 (TEDIT.PROMPTPRINT 98933 . 101837) (TEDIT.PROMPTFLASH 101839 . 103794) (
+\TEDIT.PROMPT.PAGEFULLFN 103796 . 105372)) (105609 109671 (TEXTSTREAM.TITLE 105619 . 106240) (
+\TEDIT.ORIGINAL.WINDOW.TITLE 106242 . 108287) (\TEDIT.WINDOW.TITLE 108289 . 108959) (
+\TEXTSTREAM.FILENAME 108961 . 109669)) (109714 154455 (TEDIT.DEACTIVATE.WINDOW 109724 . 116873) (
+\TEDIT.REPAINTFN 116875 . 119732) (\TEDIT.RESHAPEFN 119734 . 125354) (\TEDIT.SCROLLFN 125356 . 154453)
+) (154497 156546 (\TEDIT.PROCIDLEFN 154507 . 155856) (\TEDIT.PROCENTRYFN 155858 . 156151) (
+\TEDIT.PROCEXITFN 156153 . 156544)) (156625 167625 (\EDIT.DOWNCARET 156635 . 157316) (\EDIT.FLIPCARET 
+157318 . 158853) (TEDIT.FLASHCARET 158855 . 159969) (\EDIT.UPCARET 159971 . 160424) (
+TEDIT.NORMALIZECARET 160426 . 166377) (\SETCARET 166379 . 167299) (\TEDIT.CARET 167301 . 167623)) (
+167659 181414 (TEDIT.ADD.MENUITEM 167669 . 169584) (TEDIT.DEFAULT.MENUFN 169586 . 178853) (
+TEDIT.REMOVE.MENUITEM 178855 . 179856) (\TEDIT.CREATEMENU 179858 . 180311) (\TEDIT.MENU.WHENHELDFN 
+180313 . 181083) (\TEDIT.MENU.WHENSELECTEDFN 181085 . 181412)))))
 STOP
diff --git a/library/TEDITWINDOW.LCOM b/library/TEDITWINDOW.LCOM
index 59c632ab..bf7fb2a1 100644
Binary files a/library/TEDITWINDOW.LCOM and b/library/TEDITWINDOW.LCOM differ
diff --git a/library/TEXTOFD b/library/TEXTOFD
index 525f9d07..b32fdd96 100644
--- a/library/TEXTOFD
+++ b/library/TEXTOFD
@@ -1,11 +1,12 @@
 (DEFINE-FILE-INFO PACKAGE "INTERLISP" READTABLE "INTERLISP" BASE 10)
-(FILECREATED " 6-May-2021 10:18:06" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley2>library>TEXTOFD.;4 176139 
 
-      changes to%:  (FNS \TEXTINIT)
+(FILECREATED "12-Oct-2021 15:38:41" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEXTOFD.;4 176302 
 
-      previous date%: "11-Feb-2001 12:06:42" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley2>library>TEXTOFD.;2)
+      changes to%:  (FNS \TEDITOUTCCODEFN)
+
+      previous date%: " 7-Oct-2021 08:41:13" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>TEXTOFD.;3)
 
 
 (* ; "
@@ -25,24 +26,24 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
         (FNS \INSERTCH \INSERTCR)
         (COMS 
 
-(* ;;; "Functions to manipulate the Piece Table (PCTB)")
+(* ;;; "Functions to manipulate the Piece Table (PCTB)")
 
               (FNS \CHTOPC \CHTOPCNO \CLEARPCTB \CREATEPIECEORSTREAM \DELETEPIECE \FINDPIECE 
                    \INSERTPIECE \MAKEPCTB \SPLITPIECE \INSERT.FIRST.PIECE))
-        (COMS                                                (* ; 
-                                                           "Generic-IO type operations support")
+        (COMS                                                (* ; 
+                                                           "Generic-IO type operations support")
               (FNS \TEXTCLOSEF \TEXTCLOSEF-SUBTREE \TEXTDSPFONT \TEXTEOFP \TEXTGETEOFPTR 
                    \TEXTGETFILEPTR \TEXTOPENF \TEXTOPENF-SUBTREE \TEXTOUTCHARFN \TEXTBACKFILEPTR 
-                   \TEXTBOUT \TEDITOUTCHARFN \TEXTSETEOF \TEXTSETFILEPTR \TEXTDSPXPOSITION 
+                   \TEXTBOUT \TEDITOUTCCODEFN \TEXTSETEOF \TEXTSETFILEPTR \TEXTDSPXPOSITION 
                    \TEXTDSPYPOSITION \TEXTLEFTMARGIN \TEXTRIGHTMARGIN \TEXTDSPCHARWIDTH 
                    \TEXTDSPSTRINGWIDTH \TEXTDSPLINEFEED)
               (FNS \TEXTBIN \TEDIT.TEXTBIN.STRINGSETUP \TEDIT.TEXTBIN.FILESETUP 
                    \TEDIT.TEXTBIN.NEW.PAGE)
               (FNS \TEXTPEEKBIN \TEDIT.PEEKBIN.NEW.PAGE))
-        (COMS                                                (* ; "Support for TEXTPROP")
+        (COMS                                                (* ; "Support for TEXTPROP")
               (FNS CGETTEXTPROP CTEXTPROP GETTEXTPROP PUTTEXTPROP TEXTPROP))
         [COMS 
-              (* ;; "Support for error handling:  The old error handler for the stream-not-open error.  This is here, because you only want to do this ONCE, even if you load TEXTOFD multiple times (as, e.g., in development)")
+              (* ;; "Support for error handling:  The old error handler for the stream-not-open error.  This is here, because you only want to do this ONCE, even if you load TEXTOFD multiple times (as, e.g., in development)")
 
               (INITVARS (*TEDIT-OLD-STREAM-ERROR-HANDLER* (CONDITION-HANDLER 'XCL:STREAM-NOT-OPEN]
         (DECLARE%: DONTEVAL@LOAD DOCOPY (P (\TEXTINIT)))
@@ -676,29 +677,29 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
           (RETURN PC])
 
 (\TEXTINIT
-  [LAMBDA NIL                                           (* ; "Edited  6-May-2021 10:17 by rmk:")
-                                                             (* ; 
-                                          "Create the FDEV and STREAM prototypes for TEXT streams.")
+  [LAMBDA NIL                                           (* ; "Edited  7-Oct-2021 08:40 by rmk:")
+                                                             (* ; 
+                                          "Create the FDEV and STREAM prototypes for TEXT streams.")
 
-    (* ;; "TEXT streams make use of the following STREAM fields:")
+    (* ;; "TEXT streams make use of the following STREAM fields:")
 
-    (* ;; "(DEVICE (* FDEV of this guy -- The TEXT device)")
+    (* ;; "(DEVICE (* FDEV of this guy -- The TEXT device)")
 
-    (* ;; "F1 (* The STREAM for the PFILE of the current piece (or NIL))")
+    (* ;; "F1 (* The STREAM for the PFILE of the current piece (or NIL))")
 
-    (* ;; "F2 (* # chars left in piece at end of underlying file's page)")
+    (* ;; "F2 (* # chars left in piece at end of underlying file's page)")
 
-    (* ;; "F3 (* The TEXTOBJ for this stream)")
+    (* ;; "F3 (* The TEXTOBJ for this stream)")
 
-    (* ;; "F4")
+    (* ;; "F4")
 
-    (* ;; "F5 (* The PIECE we're currently inside)")
+    (* ;; "F5 (* The PIECE we're currently inside)")
 
-    (* ;; "(FW6 WORD) (* CPAGE for the start of the piece, for BACKFILEPTR)")
+    (* ;; "(FW6 WORD) (* CPAGE for the start of the piece, for BACKFILEPTR)")
 
-    (* ;; "(FW7 WORD) (* COFFSET for the start of the piece, for BACKFILEPTR)")
+    (* ;; "(FW7 WORD) (* COFFSET for the start of the piece, for BACKFILEPTR)")
 
-    (* ;; "(FW8 WORD)")
+    (* ;; "(FW8 WORD)")
 
     (SETQ \TEXTIMAGEOPS (create IMAGEOPS
                                IMAGETYPE _ 'TEXT
@@ -745,6 +746,9 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
                            FDEXTENDABLE _ NIL
                            TRUNCATEFILE _ (FUNCTION NILL)
                            WRITEPAGES _ (FUNCTION NILL)))
+
+    (* ;; "The prototypical Text stream")
+
     (SETQ \TEXTOFD
      (create STREAM
             BINABLE _ T
@@ -761,10 +765,16 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
             FW7 _ 0
             MAXBUFFERS _ 10
             IMAGEOPS _ \TEXTIMAGEOPS
-            IMAGEDATA _ (create TEXTIMAGEDATA)
-            OUTCHARFN _ (FUNCTION \TEDITOUTCHARFN)))         (* ; "The prototypical Text stream")
+            IMAGEDATA _ (create TEXTIMAGEDATA)))
 
-    (* ;; "Set up so that FILE NOT OPENs on TEdit streams are caught and fixed.")
+    (* ;; "Maybe more functions later?")
+
+    (MAKE-EXTERNALFORMAT :TEDIT NIL NIL NIL (FUNCTION \TEDITOUTCCODEFN)
+           NIL
+           'CR)
+    (\EXTERNALFORMAT \TEXTOFD :TEDIT)
+
+    (* ;; "Set up so that FILE NOT OPENs on TEdit streams are caught and fixed.")
 
     (CL:SETF (CONDITION-HANDLER 'XCL:STREAM-NOT-OPEN)
            (FUNCTION (LAMBDA (CONDITION)
@@ -772,8 +782,8 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
                             (COND
                                [(AND (BOUNDP 'ERRORPOS)
                                      (TEXTSTREAMP STREAM))
-                                                             (* ; 
-           "This happened in the error handler, and it happened to a TEdit stream, so try the fix:")
+                                                             (* ; 
+           "This happened in the error handler, and it happened to a TEdit stream, so try the fix:")
                                 (LET ((XCL::RESULT (REOPENTEXTSTREAM STREAM)))
                                      (CL:WHEN XCL::RESULT
                                          (ENVAPPLY (STKNAME ERRORPOS)
@@ -781,8 +791,8 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
                                                 (STKNTH -1 ERRORPOS ERRORPOS)
                                                 ERRORPOS T T))]
                                (*TEDIT-OLD-STREAM-ERROR-HANDLER* 
-                                                             (* ; 
-                         "Some other kind of stream, so punt to the old handler (if there is one):")
+                                                             (* ; 
+                         "Some other kind of stream, so punt to the old handler (if there is one):")
                                       (APPLY* *TEDIT-OLD-STREAM-ERROR-HANDLER* CONDITION])
 
 (\TEXTMARK
@@ -1782,10 +1792,10 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
           (freplace (TEXTSTREAM CHARSLEFT) of STREAM with 0)
           (freplace (TEXTSTREAM REALFILE) of STREAM with NIL])
 
-(\TEDITOUTCHARFN
-  [LAMBDA (STREAM CHARCODE)                              (* ; "Edited 31-May-91 14:19 by jds")
+(\TEDITOUTCCODEFN
+  [LAMBDA (STREAM CHARCODE)                             (* ; "Edited 12-Oct-2021 15:38 by rmk:")
 
-    (* ;; "OUTCHARFN for TEdit streams -- always BOUTs the character, because TEdit streams deal in complete charcodes rather than bytes. BUT -- does update the CHARPOSITION of the stream, which is used by some code to decide things.")
+    (* ;; "OUTCCODEFN for TEdit streams -- always BOUTs the character, because TEdit streams deal in complete charcodes rather than bytes (via \TEXTBOUT). BUT -- does update the CHARPOSITION of the stream, which is used by some code to decide things.")
 
     (COND
        ((EQ CHARCODE (CHARCODE EOL))
@@ -2657,25 +2667,25 @@ Copyright (c) 1983-1991, 1993-1995, 1999-2001, 2021 by John Sybalsky & Xerox Cor
 (PUTPROPS TEXTOFD COPYRIGHT ("John Sybalsky & Xerox Corporation" 1983 1984 1985 1986 1987 1988 1989 
 1990 1991 1993 1994 1995 1999 2000 2001 2021))
 (DECLARE%: DONTCOPY
-  (FILEMAP (NIL (2982 52971 (COPYTEXTSTREAM 2992 . 6114) (OPENTEXTSTREAM 6116 . 20993) (REOPENTEXTSTREAM
- 20995 . 21417) (TEDIT.STREAMCHANGEDP 21419 . 21717) (TEXTSTREAMP 21719 . 22033) (TXTFILE 22035 . 
-22480) (\DELETECH 22482 . 33738) (\SETUPGETCH 33740 . 41019) (\TEDIT.REOPEN.STREAM 41021 . 42871) (
-\TEDIT.COPYTEXTSTREAM.PIECEMAPFN 42873 . 45311) (\TEXTINIT 45313 . 50864) (\TEXTMARK 50866 . 51614) (
-\TEXTTTYBOUT 51616 . 52969)) (52972 78404 (\INSERTCH 52982 . 76708) (\INSERTCR 76710 . 78402)) (78470 
-98786 (\CHTOPC 78480 . 79669) (\CHTOPCNO 79671 . 80933) (\CLEARPCTB 80935 . 81731) (
-\CREATEPIECEORSTREAM 81733 . 84707) (\DELETEPIECE 84709 . 85622) (\FINDPIECE 85624 . 85990) (
-\INSERTPIECE 85992 . 89002) (\MAKEPCTB 89004 . 90919) (\SPLITPIECE 90921 . 97880) (\INSERT.FIRST.PIECE
- 97882 . 98784)) (98838 123056 (\TEXTCLOSEF 98848 . 100075) (\TEXTCLOSEF-SUBTREE 100077 . 100783) (
-\TEXTDSPFONT 100785 . 101777) (\TEXTEOFP 101779 . 103138) (\TEXTGETEOFPTR 103140 . 103350) (
-\TEXTGETFILEPTR 103352 . 105415) (\TEXTOPENF 105417 . 106247) (\TEXTOPENF-SUBTREE 106249 . 107050) (
-\TEXTOUTCHARFN 107052 . 107400) (\TEXTBACKFILEPTR 107402 . 113303) (\TEXTBOUT 113305 . 116653) (
-\TEDITOUTCHARFN 116655 . 117901) (\TEXTSETEOF 117903 . 118412) (\TEXTSETFILEPTR 118414 . 119639) (
-\TEXTDSPXPOSITION 119641 . 120498) (\TEXTDSPYPOSITION 120500 . 121045) (\TEXTLEFTMARGIN 121047 . 
-121530) (\TEXTRIGHTMARGIN 121532 . 122468) (\TEXTDSPCHARWIDTH 122470 . 122708) (\TEXTDSPSTRINGWIDTH 
-122710 . 122950) (\TEXTDSPLINEFEED 122952 . 123054)) (123057 156801 (\TEXTBIN 123067 . 139853) (
-\TEDIT.TEXTBIN.STRINGSETUP 139855 . 145568) (\TEDIT.TEXTBIN.FILESETUP 145570 . 151956) (
-\TEDIT.TEXTBIN.NEW.PAGE 151958 . 156799)) (156802 170210 (\TEXTPEEKBIN 156812 . 165951) (
-\TEDIT.PEEKBIN.NEW.PAGE 165953 . 170208)) (170248 175466 (CGETTEXTPROP 170258 . 170734) (CTEXTPROP 
-170736 . 173080) (GETTEXTPROP 173082 . 173677) (PUTTEXTPROP 173679 . 175004) (TEXTPROP 175006 . 175464
+  (FILEMAP (NIL (2989 53114 (COPYTEXTSTREAM 2999 . 6121) (OPENTEXTSTREAM 6123 . 21000) (REOPENTEXTSTREAM
+ 21002 . 21424) (TEDIT.STREAMCHANGEDP 21426 . 21724) (TEXTSTREAMP 21726 . 22040) (TXTFILE 22042 . 
+22487) (\DELETECH 22489 . 33745) (\SETUPGETCH 33747 . 41026) (\TEDIT.REOPEN.STREAM 41028 . 42878) (
+\TEDIT.COPYTEXTSTREAM.PIECEMAPFN 42880 . 45318) (\TEXTINIT 45320 . 51007) (\TEXTMARK 51009 . 51757) (
+\TEXTTTYBOUT 51759 . 53112)) (53115 78547 (\INSERTCH 53125 . 76851) (\INSERTCR 76853 . 78545)) (78613 
+98929 (\CHTOPC 78623 . 79812) (\CHTOPCNO 79814 . 81076) (\CLEARPCTB 81078 . 81874) (
+\CREATEPIECEORSTREAM 81876 . 84850) (\DELETEPIECE 84852 . 85765) (\FINDPIECE 85767 . 86133) (
+\INSERTPIECE 86135 . 89145) (\MAKEPCTB 89147 . 91062) (\SPLITPIECE 91064 . 98023) (\INSERT.FIRST.PIECE
+ 98025 . 98927)) (98981 123219 (\TEXTCLOSEF 98991 . 100218) (\TEXTCLOSEF-SUBTREE 100220 . 100926) (
+\TEXTDSPFONT 100928 . 101920) (\TEXTEOFP 101922 . 103281) (\TEXTGETEOFPTR 103283 . 103493) (
+\TEXTGETFILEPTR 103495 . 105558) (\TEXTOPENF 105560 . 106390) (\TEXTOPENF-SUBTREE 106392 . 107193) (
+\TEXTOUTCHARFN 107195 . 107543) (\TEXTBACKFILEPTR 107545 . 113446) (\TEXTBOUT 113448 . 116796) (
+\TEDITOUTCCODEFN 116798 . 118064) (\TEXTSETEOF 118066 . 118575) (\TEXTSETFILEPTR 118577 . 119802) (
+\TEXTDSPXPOSITION 119804 . 120661) (\TEXTDSPYPOSITION 120663 . 121208) (\TEXTLEFTMARGIN 121210 . 
+121693) (\TEXTRIGHTMARGIN 121695 . 122631) (\TEXTDSPCHARWIDTH 122633 . 122871) (\TEXTDSPSTRINGWIDTH 
+122873 . 123113) (\TEXTDSPLINEFEED 123115 . 123217)) (123220 156964 (\TEXTBIN 123230 . 140016) (
+\TEDIT.TEXTBIN.STRINGSETUP 140018 . 145731) (\TEDIT.TEXTBIN.FILESETUP 145733 . 152119) (
+\TEDIT.TEXTBIN.NEW.PAGE 152121 . 156962)) (156965 170373 (\TEXTPEEKBIN 156975 . 166114) (
+\TEDIT.PEEKBIN.NEW.PAGE 166116 . 170371)) (170411 175629 (CGETTEXTPROP 170421 . 170897) (CTEXTPROP 
+170899 . 173243) (GETTEXTPROP 173245 . 173840) (PUTTEXTPROP 173842 . 175167) (TEXTPROP 175169 . 175627
 )))))
 STOP
diff --git a/library/TEXTOFD.LCOM b/library/TEXTOFD.LCOM
index cb466888..3ff75261 100644
Binary files a/library/TEXTOFD.LCOM and b/library/TEXTOFD.LCOM differ
diff --git a/sources/HARDCOPY b/sources/HARDCOPY
index 145f90bb..7d63bbf5 100644
--- a/sources/HARDCOPY
+++ b/sources/HARDCOPY
@@ -1,11 +1,12 @@
 (DEFINE-FILE-INFO PACKAGE "INTERLISP" READTABLE "INTERLISP" BASE 10)
-(FILECREATED "20-Sep-2021 10:59:58" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley>sources>HARDCOPY.;2 103730 
 
-      changes to%:  (VARS HARDCOPYCOMS)
+(FILECREATED " 8-Oct-2021 22:23:49" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>sources>HARDCOPY.;13 103499 
 
-      previous date%: " 5-May-2021 19:41:55" 
-{DSK}<Users>kaplan>Local>medley3.5>git-medley>sources>HARDCOPY.;1)
+      changes to%:  (FNS COPY.TEXT.TO.IMAGE)
+
+      previous date%: " 7-Oct-2021 10:43:32" 
+{DSK}<Users>kaplan>Local>medley3.5>git-medley>sources>HARDCOPY.;12)
 
 
 (* ; "
@@ -722,105 +723,100 @@ Copyright (c) 1984-1993, 1999, 2018, 2021 by Venue & Xerox Corporation.
                             (CLOSEF IMAGESTREAM])])
 
 (COPY.TEXT.TO.IMAGE
-  [LAMBDA (INFILE IMAGESTREAM FONTS TABS)               (* ; "Edited  5-May-2021 19:41 by rmk:")
-                                                             (* ; "Edited 10-Apr-95 21:23 by rmk:")
+  [LAMBDA (INFILE IMAGESTREAM FONTS TABS)               (* ; "Edited  8-Oct-2021 22:23 by rmk:")
+                                                             (* ; "Edited 10-Apr-95 21:23 by rmk:")
 
-    (* ;; "Copy text to an image stream, obeying PSPOOL control characters")
+    (* ;; "Copy text to an image stream, obeying PSPOOL control characters")
 
     (LET*
-     ((IMAGESTREAM (GETSTREAM IMAGESTREAM 'OUTPUT))
+     [(IMAGESTREAM (GETSTREAM IMAGESTREAM 'OUTPUT))
       (RIGHTMAR (DSPRIGHTMARGIN NIL IMAGESTREAM))
       (FONTARRAY (FONTMAPARRAY FONTS))
       (MAXFONT (ARRAYSIZE FONTARRAY))
       (INSTRM (GETSTREAM INFILE 'INPUT))
-      DEFAULTTAB C FC)
-     (replace (STREAM ENDOFSTREAMOP) of INSTRM with (FUNCTION ZERO))
-     (do
-      (COND
-         ((AND [EQ 0 (LOGAND 255 (SETQ C (\INCCODE INSTRM]
-               (EOFP INSTRM))
-          (RETURN))
-         ((AND RIGHTMAR (> (DSPXPOSITION NIL IMAGESTREAM)
-                           RIGHTMAR))                        (* ; 
-                                                      "Not to walk off the right edge of the paper")
-          (TERPRI IMAGESTREAM)))
-      (COND
-         ([> C (CONSTANT (APPLY (FUNCTION MAX)
-                                (CHARCODE (^F CR LF ^L TAB NULL]
-          (\OUTCHAR IMAGESTREAM C))
-         (T
-          (SELCHARQ C
-               (^F                                           (* ; "Font shift")
+      DEFAULTTAB C FC (EOSP (GETFILEINFO INSTRM 'ENDOFSTREAMOP]
 
-                   (* ;; 
-                 "For FX-XP-9 printer:SETXY interpress command to avoid printer's BUG(Take)")
+     (* ;; 
+"RMK:  EOS function changed to NILL from ZERO. 0 in low-order bits is OK in UNICODE, when we switch")
 
-                   (DSPXPOSITION (IPLUS (DSPXPOSITION NIL IMAGESTREAM)
-                                        1)
-                          IMAGESTREAM)
-                   [SELCHARQ (SETQ FC (\INCCODE INSTRM))
-                        (^T                                  (* ; "tab to absolute pos.")
-                            (COND
-                               ((EQ 0 (SETQ FC (\INCCODE INSTRM)))
-                                (\OUTCHAR IMAGESTREAM (CHARCODE ^F))
-                                (\OUTCHAR IMAGESTREAM (CHARCODE ^T))
-                                (AND (\EOFP INSTRM)
-                                     (RETURN))
-                                (\OUTCHAR IMAGESTREAM FC))
-                               (T 
+     (SETFILEINFO INSTRM 'ENDOFSTREAMOP (FUNCTION NILL))
+     [while (SETQ C (\INCCODE INSTRM))
+        do
+        (COND
+           ((AND RIGHTMAR (> (DSPXPOSITION NIL IMAGESTREAM)
+                             RIGHTMAR))                      (* ; 
+                                                      "Not to walk off the right edge of the paper")
+            (TERPRI IMAGESTREAM)))
+        (COND
+           ([> C (CONSTANT (APPLY (FUNCTION MAX)
+                                  (CHARCODE (^F CR LF ^L TAB]
+            (\OUTCHAR IMAGESTREAM C))
+           (T
+            (SELCHARQ C
+                 (^F                                         (* ; "Font shift")
 
-                                 (* ;; "TEXTDEFAULTTABS is a hack, since it depends on the units of the stream.  Should really be a property of the stream or imagetype, or defined in terms of standard scale")
+                     (* ;; 
+                   "For FX-XP-9 printer:SETXY interpress command to avoid printer's BUG(Take)")
 
-                                  [SETQ FC
-                                   (IF TABS
-                                       THEN (OR (CAR (NTH TABS FC))
-                                                    (ERROR "Undefined absolute tab number" FC))
-                                     ELSE (TIMES FC
-                                                     (OR DEFAULTTAB
-                                                         (SETQ DEFAULTTAB
-                                                          (TIMES 8 (CHARWIDTH (CHARCODE SPACE)
-                                                                          (FONTCREATE (ELT FONTARRAY
-                                                                                           1)
-                                                                                 NIL NIL NIL 
-                                                                                 IMAGESTREAM]
-                                  (DSPXPOSITION FC IMAGESTREAM))))
-                        (NULL (\OUTCHAR IMAGESTREAM (CHARCODE ^F))
-                              (AND (\EOFP INSTRM)
-                                   (RETURN))
-                              (\OUTCHAR IMAGESTREAM FC)      (* ; "EOS after ^F")
-                              )
-                        (COND
-                           ((AND (>= MAXFONT FC)
-                                 (NEQ FC 0))
-                            (DSPFONT (ELT FONTARRAY FC)
-                                   IMAGESTREAM))
-                           (T (\OUTCHAR IMAGESTREAM (CHARCODE ^F))
-                              (\OUTCHAR IMAGESTREAM C])
-               (CR 
-                   (* ;; "Assumes that CR and possibly following LF denote a single EOL, independent of the EOL convention and independent of whether the file was opened binary or text.  Originally, this function tried to discriminate, treating an LF in a CR-mode file as a line-feed and a CR in an LF file as a carriage-return.  But these formatting effects cannot be guaranteed across text-file transfers (which is all that it makes sense to print), so it is silly to take them seriously.  Given that just this information can be lost in text-mode file transfers, we make adopt here the 99%% correct solution, which is to treat all instances of CR, CRLF, and LF as end-of-line.")
+                     (DSPXPOSITION (IPLUS (DSPXPOSITION NIL IMAGESTREAM)
+                                          1)
+                            IMAGESTREAM)
+                     [SELCHARQ (SETQ FC (\INCCODE INSTRM))
+                          (^T                                (* ; "tab to absolute pos.")
+                              (CL:UNLESS (SETQ FC (\INCCODE INSTRM))
+                                  (\OUTCHAR IMAGESTREAM (CHARCODE ^F))
+                                  (\OUTCHAR IMAGESTREAM (CHARCODE ^T))
+                                  (RETURN))
 
-                   (TERPRI IMAGESTREAM)
-                   (COND
-                      ((EQ (CHARCODE LF)
-                           (\PEEKBIN INSTRM T))
-                       (BIN INSTRM))))
-               (TAB (OR (LET* [(LEFTMARGIN (DSPLEFTMARGIN NIL IMAGESTREAM))
-                               (TAB.WIDTH (TIMES (CHARWIDTH (CHARCODE SPACE)
-                                                        IMAGESTREAM)
-                                                 8))
-                               (CURRENT.X (- (DSPXPOSITION NIL IMAGESTREAM)
-                                             LEFTMARGIN))
-                               (CURRENT.STOP (- CURRENT.X (REMAINDER CURRENT.X TAB.WIDTH]
-                              (NLSETQ (RELMOVETO (- (+ CURRENT.STOP TAB.WIDTH)
-                                                    CURRENT.X)
-                                             0 IMAGESTREAM)))
-                        (\OUTCHAR IMAGESTREAM C)))
-               (LF                                           (* ; "See comment at CR")
-                   (TERPRI IMAGESTREAM))
-               (NULL (AND (EOFP INSTRM)
-                          (RETURN))
-                     (\OUTCHAR IMAGESTREAM C))
-               (\OUTCHAR IMAGESTREAM C])
+                              (* ;; "TEXTDEFAULTTABS is a hack, since it depends on the units of the stream.  Should really be a property of the stream or imagetype, or defined in terms of standard scale")
+
+                              [SETQ FC
+                               (IF TABS
+                                   THEN (OR (CAR (NTH TABS FC))
+                                                (ERROR "Undefined absolute tab number" FC))
+                                 ELSE (TIMES FC (OR DEFAULTTAB
+                                                        (SETQ DEFAULTTAB
+                                                         (TIMES 8 (CHARWIDTH (CHARCODE SPACE)
+                                                                         (FONTCREATE (ELT FONTARRAY 1
+                                                                                          )
+                                                                                NIL NIL NIL 
+                                                                                IMAGESTREAM]
+                              (DSPXPOSITION FC IMAGESTREAM))
+                          (NIL (\OUTCHAR IMAGESTREAM (CHARCODE ^F))
+                                                             (* ; "EOS after ^F")
+                               (RETURN))
+                          (COND
+                             ((AND (>= MAXFONT FC)
+                                   (NEQ FC 0))
+                              (DSPFONT (ELT FONTARRAY FC)
+                                     IMAGESTREAM))
+                             (T (\OUTCHAR IMAGESTREAM (CHARCODE ^F))
+                                (\OUTCHAR IMAGESTREAM FC])
+                 (CR 
+                     (* ;; "Assumes that CR and possibly following LF denote a single EOL, independent of the EOL convention and independent of whether the file was opened binary or text.  Originally, this function tried to discriminate, treating an LF in a CR-mode file as a line-feed and a CR in an LF file 
+as a carriage-return.  But these formatting effects cannot be guaranteed across text-file transfers (which is all that it makes sense to print), so it is silly to take them seriously.  Given that just this information can be lost in text-mode file transfers, we make adopt here the 99%% correct solution, wh
+ich is to treat all instances of CR, CRLF, and LF as end-of-line.")
+
+                     (COND
+                        ((EQ (CHARCODE LF)
+                             (\PEEKCCODE.NOEOLC INSTRM T))
+                         (\INCCODE INSTRM)))
+                     (TERPRI IMAGESTREAM))
+                 (LF                                         (* ; "Isolatedx LF, see comment at CR")
+                     (TERPRI IMAGESTREAM))
+                 (TAB (OR (LET* [(LEFTMARGIN (DSPLEFTMARGIN NIL IMAGESTREAM))
+                                 (TAB.WIDTH (TIMES (CHARWIDTH (CHARCODE SPACE)
+                                                          IMAGESTREAM)
+                                                   8))
+                                 (CURRENT.X (- (DSPXPOSITION NIL IMAGESTREAM)
+                                               LEFTMARGIN))
+                                 (CURRENT.STOP (- CURRENT.X (REMAINDER CURRENT.X TAB.WIDTH]
+                                (NLSETQ (RELMOVETO (- (+ CURRENT.STOP TAB.WIDTH)
+                                                      CURRENT.X)
+                                               0 IMAGESTREAM)))
+                          (\OUTCHAR IMAGESTREAM C)))
+                 (\OUTCHAR IMAGESTREAM C]
+     (SETFILEINFO INSTRM 'ENDOFSTREAMOP EOSP])
 )
 (DEFINEQ
 
@@ -1088,39 +1084,39 @@ Copyright (c) 1984-1993, 1999, 2018, 2021 by Venue & Xerox Corporation.
 (PUTPROPS HARDCOPY COPYRIGHT ("Venue & Xerox Corporation" 1984 1985 1986 1987 1988 1989 1990 1991 1992
  1993 1999 2018 2021))
 (DECLARE%: DONTCOPY
-  (FILEMAP (NIL (6176 10360 (HARDCOPY.SOMEHOW 6186 . 7544) (HARDCOPYIMAGEW 7546 . 7698) (
-HARDCOPYIMAGEW.TOFILE 7700 . 8008) (HARDCOPYIMAGEW.TOPRINTER 8010 . 8675) (HARDCOPYREGION.TOFILE 8677
- . 8975) (HARDCOPYREGION.TOPRINTER 8977 . 9599) (COPY.WINDOW.TO.BITMAP 9601 . 10358)) (10432 20982 (
-MakeMenuOfPrinters 10442 . 11667) (PRINTERS.WHENSELECTEDFN 11669 . 13411) (MakeMenuOfImageTypes 13413
- . 13931) (GetNewPrinterFromUser 13933 . 14361) (PopUpWindowAndGetAtom 14363 . 15748) (
-PopUpWindowAndGetList 15750 . 17316) (NewPrinter 17318 . 18266) (GetPrinterName 18268 . 18548) (
-GetImageFile 18550 . 20837) (FetchDefaultPrinter 20839 . 20980)) (21017 21555 (
-ExtensionForPrintFileType 21027 . 21220) (PRINTFILETYPE.FROM.EXTENSION 21222 . 21553)) (21610 37994 (
-DEFAULTPRINTER 21620 . 21780) (CAN.PRINT.DIRECTLY 21782 . 21938) (CONVERT.FILE.TO.TYPE.FOR.PRINTER 
-21940 . 22984) (EMPRESS 22986 . 23299) (HARDCOPYW 23301 . 26261) (LISTFILES1 26263 . 26436) (
-PRINTER.BITMAPFILE 26438 . 26685) (PRINTER.BITMAPSCALE 26687 . 26952) (PRINTER.SCRATCH.FILE 26954 . 
-27077) (PRINTERPROP 27079 . 27262) (PRINTERSTATUS 27264 . 27453) (PRINTERTYPE 27455 . 29764) (
-PRINTERNAME 29766 . 30068) (PRINTFILEPROP 30070 . 30261) (PRINTFILETYPE 30263 . 32207) (
-\EXPECTED.FILE.TYPE 32209 . 32991) (SEND.FILE.TO.PRINTER 32993 . 37992)) (37995 42977 (PRINTERDEVICE 
-38005 . 42975)) (43792 51993 (TEXTTOIMAGEFILE 43802 . 45992) (COPY.TEXT.TO.IMAGE 45994 . 51991)) (
-51994 53129 (\BLTSHADE.GENERICPRINTER 52004 . 53127)) (53257 72009 (MAKEHARDCOPYSTREAM 53267 . 54271) 
-(UNMAKEHARDCOPYSTREAM 54273 . 54957) (HARDCOPYSTREAMTYPE 54959 . 55238) (\CHARWIDTH.HDCPYDISPLAY 55240
- . 55671) (\DSPFONT.HDCPYDISPLAY 55673 . 57078) (\DSPRIGHTMARGIN.HDCPYDISPLAY 57080 . 57657) (
-\DSPXPOSITION.HDCPYDISPLAY 57659 . 57920) (\DSPYPOSITION.HDCPYDISPLAY 57922 . 58183) (
-\STRINGWIDTH.HDCPYDISPLAY 58185 . 58692) (\STRINGWIDTH.HCPYDISPLAYAUX 58694 . 61026) (\HDCPYBLTCHAR 
-61028 . 63563) (\HDCPYDISPLAY.FIX.XPOS 63565 . 63985) (\HDCPYDISPLAY.FIX.YPOS 63987 . 64407) (
-\HDCPYDISPLAYINIT 64409 . 65186) (\HDCPYDSPPRINTCHAR 65188 . 67348) (\SLOWHDCPYBLTCHAR 67350 . 70853) 
-(\CHANGECHARSET.HDCPYDISPLAY 70855 . 72007)) (72731 103028 (MAKEHARDCOPYMODESTREAM 72741 . 74650) (
-UNMAKEHARDCOPYMODESTREAM 74652 . 75730) (\BLTSHADE.HCPYMODE 75732 . 76179) (\BITBLT.HCPYMODE 76181 . 
-76803) (\BRUSHCONVERT.HCPYMODE 76805 . 77042) (\CHANGECHARSET.HCPYMODE 77044 . 78811) (
-\DASHINGCONVERT.HCPYMODE 78813 . 79076) (\CHARWIDTH.HCPYMODE 79078 . 79365) (\DRAWLINE.HCPYMODE 79367
- . 79679) (\DRAWCURVE.HCPYMODE 79681 . 80110) (\DRAWCIRCLE.HCPYMODE 80112 . 80507) (
-\DRAWELLIPSE.HCPYMODE 80509 . 81021) (\DSPFONT.HCPYMODE 81023 . 82179) (\DSPLEFTMARGIN.HCPYMODE 82181
- . 82765) (\DSPLINEFEED.HCPYMODE 82767 . 83177) (\DSPRIGHTMARGIN.HCPYMODE 83179 . 83808) (
-\DSPSPACEFACTOR.HCPYMODE 83810 . 84331) (\DSPXPOSITION.HCPYMODE 84333 . 84914) (\DSPYPOSITION.HCPYMODE
- 84916 . 85321) (\MOVETO.HCPYMODE 85323 . 85475) (\FONTCREATE.HCPYMODE.PRESS 85477 . 86489) (
-\CREATECHARSET.HCPYMODE.PRESS 86491 . 87462) (\FONTCREATE.HCPYMODE.INTERPRESS 87464 . 88498) (
-\CREATECHARSET.HCPYMODE.INTERPRESS 88500 . 89488) (\STRINGWIDTH.HCPYMODE 89490 . 89924) (
-\HCPYMODEBLTCHAR 89926 . 92895) (\HCPYMODEDISPLAYINIT 92897 . 95828) (\HCPYMODEDSPPRINTCHAR 95830 . 
-98011) (\SLOWHCPYMODEBLTCHAR 98013 . 101527) (\SFFixY.HCPYMODE 101529 . 103026)))))
+  (FILEMAP (NIL (6184 10368 (HARDCOPY.SOMEHOW 6194 . 7552) (HARDCOPYIMAGEW 7554 . 7706) (
+HARDCOPYIMAGEW.TOFILE 7708 . 8016) (HARDCOPYIMAGEW.TOPRINTER 8018 . 8683) (HARDCOPYREGION.TOFILE 8685
+ . 8983) (HARDCOPYREGION.TOPRINTER 8985 . 9607) (COPY.WINDOW.TO.BITMAP 9609 . 10366)) (10440 20990 (
+MakeMenuOfPrinters 10450 . 11675) (PRINTERS.WHENSELECTEDFN 11677 . 13419) (MakeMenuOfImageTypes 13421
+ . 13939) (GetNewPrinterFromUser 13941 . 14369) (PopUpWindowAndGetAtom 14371 . 15756) (
+PopUpWindowAndGetList 15758 . 17324) (NewPrinter 17326 . 18274) (GetPrinterName 18276 . 18556) (
+GetImageFile 18558 . 20845) (FetchDefaultPrinter 20847 . 20988)) (21025 21563 (
+ExtensionForPrintFileType 21035 . 21228) (PRINTFILETYPE.FROM.EXTENSION 21230 . 21561)) (21618 38002 (
+DEFAULTPRINTER 21628 . 21788) (CAN.PRINT.DIRECTLY 21790 . 21946) (CONVERT.FILE.TO.TYPE.FOR.PRINTER 
+21948 . 22992) (EMPRESS 22994 . 23307) (HARDCOPYW 23309 . 26269) (LISTFILES1 26271 . 26444) (
+PRINTER.BITMAPFILE 26446 . 26693) (PRINTER.BITMAPSCALE 26695 . 26960) (PRINTER.SCRATCH.FILE 26962 . 
+27085) (PRINTERPROP 27087 . 27270) (PRINTERSTATUS 27272 . 27461) (PRINTERTYPE 27463 . 29772) (
+PRINTERNAME 29774 . 30076) (PRINTFILEPROP 30078 . 30269) (PRINTFILETYPE 30271 . 32215) (
+\EXPECTED.FILE.TYPE 32217 . 32999) (SEND.FILE.TO.PRINTER 33001 . 38000)) (38003 42985 (PRINTERDEVICE 
+38013 . 42983)) (43800 51762 (TEXTTOIMAGEFILE 43810 . 46000) (COPY.TEXT.TO.IMAGE 46002 . 51760)) (
+51763 52898 (\BLTSHADE.GENERICPRINTER 51773 . 52896)) (53026 71778 (MAKEHARDCOPYSTREAM 53036 . 54040) 
+(UNMAKEHARDCOPYSTREAM 54042 . 54726) (HARDCOPYSTREAMTYPE 54728 . 55007) (\CHARWIDTH.HDCPYDISPLAY 55009
+ . 55440) (\DSPFONT.HDCPYDISPLAY 55442 . 56847) (\DSPRIGHTMARGIN.HDCPYDISPLAY 56849 . 57426) (
+\DSPXPOSITION.HDCPYDISPLAY 57428 . 57689) (\DSPYPOSITION.HDCPYDISPLAY 57691 . 57952) (
+\STRINGWIDTH.HDCPYDISPLAY 57954 . 58461) (\STRINGWIDTH.HCPYDISPLAYAUX 58463 . 60795) (\HDCPYBLTCHAR 
+60797 . 63332) (\HDCPYDISPLAY.FIX.XPOS 63334 . 63754) (\HDCPYDISPLAY.FIX.YPOS 63756 . 64176) (
+\HDCPYDISPLAYINIT 64178 . 64955) (\HDCPYDSPPRINTCHAR 64957 . 67117) (\SLOWHDCPYBLTCHAR 67119 . 70622) 
+(\CHANGECHARSET.HDCPYDISPLAY 70624 . 71776)) (72500 102797 (MAKEHARDCOPYMODESTREAM 72510 . 74419) (
+UNMAKEHARDCOPYMODESTREAM 74421 . 75499) (\BLTSHADE.HCPYMODE 75501 . 75948) (\BITBLT.HCPYMODE 75950 . 
+76572) (\BRUSHCONVERT.HCPYMODE 76574 . 76811) (\CHANGECHARSET.HCPYMODE 76813 . 78580) (
+\DASHINGCONVERT.HCPYMODE 78582 . 78845) (\CHARWIDTH.HCPYMODE 78847 . 79134) (\DRAWLINE.HCPYMODE 79136
+ . 79448) (\DRAWCURVE.HCPYMODE 79450 . 79879) (\DRAWCIRCLE.HCPYMODE 79881 . 80276) (
+\DRAWELLIPSE.HCPYMODE 80278 . 80790) (\DSPFONT.HCPYMODE 80792 . 81948) (\DSPLEFTMARGIN.HCPYMODE 81950
+ . 82534) (\DSPLINEFEED.HCPYMODE 82536 . 82946) (\DSPRIGHTMARGIN.HCPYMODE 82948 . 83577) (
+\DSPSPACEFACTOR.HCPYMODE 83579 . 84100) (\DSPXPOSITION.HCPYMODE 84102 . 84683) (\DSPYPOSITION.HCPYMODE
+ 84685 . 85090) (\MOVETO.HCPYMODE 85092 . 85244) (\FONTCREATE.HCPYMODE.PRESS 85246 . 86258) (
+\CREATECHARSET.HCPYMODE.PRESS 86260 . 87231) (\FONTCREATE.HCPYMODE.INTERPRESS 87233 . 88267) (
+\CREATECHARSET.HCPYMODE.INTERPRESS 88269 . 89257) (\STRINGWIDTH.HCPYMODE 89259 . 89693) (
+\HCPYMODEBLTCHAR 89695 . 92664) (\HCPYMODEDISPLAYINIT 92666 . 95597) (\HCPYMODEDSPPRINTCHAR 95599 . 
+97780) (\SLOWHCPYMODEBLTCHAR 97782 . 101296) (\SFFixY.HCPYMODE 101298 . 102795)))))
 STOP
diff --git a/sources/HARDCOPY.LCOM b/sources/HARDCOPY.LCOM
index 27e0ec85..867202fb 100644
Binary files a/sources/HARDCOPY.LCOM and b/sources/HARDCOPY.LCOM differ
