diff --git a/library/CLIPBOARD b/library/CLIPBOARD
index 1f71ea38..dbe83449 100644
--- a/library/CLIPBOARD
+++ b/library/CLIPBOARD
@@ -1 +1 @@
-(DEFINE-FILE-INFO READTABLE "INTERLISP" PACKAGE "INTERLISP")
(FILECREATED "23-Feb-2021 17:31:20" 
{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>CLIPBOARD.;51 9084   

      changes to%:  (FNS CLIPBOARD-PASTE-STREAM CLIPBOARD-COPY-STREAM)

      previous date%: "23-Feb-2021 11:34:57" 
{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>CLIPBOARD.;50)


(PRETTYCOMPRINT CLIPBOARDCOMS)

(RPAQQ CLIPBOARDCOMS
       [                                                     (* ; "Enable copy and paste")
        (FNS INSTALL-CLIPBOARD GETCLIPBOARD PUTCLIPBOARD PASTEFROMCLIPBOARD LISPINTERRUPTS.PASTE 
             CLIPBOARD-COPY-STREAM CLIPBOARD-PASTE-STREAM)
        (FNS TEDIT.COPYTOCLIPBOARD TEDIT.EXTRACTTOCLIPBOARD)
        (FNS SEDIT.COPYTOCLIPBOARD)
        (INITVARS (CLIPBOARD-FORMAT :UTF8))
        (DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DOCOPY (FILES (SYSLOAD)
                                                              UNIXCOMM UNICODE)
               (P (INSTALL-CLIPBOARD)))
        (DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DONTCOPY COMPILERVARS (ADDVARS (NLAMA)
                                                                             (NLAML)
                                                                             (LAMA])



(* ; "Enable copy and paste")

(DEFINEQ

(INSTALL-CLIPBOARD
  [LAMBDA NIL                                               (* ; "Edited  8-Aug-2020 07:59 by rmk:")
                                                            (* ; "Edited 19-Apr-2020 12:15 by rmk:")
                                                            (* ; "Edited 18-Apr-2018 23:00 by rmk:")
    (CL:WHEN (GETD 'LISPINTERRUPTS.PASTE)
        (MOVD? 'LISPINTERRUPTS 'LISPINTERRUPTS.ORIG)
        (MOVD 'LISPINTERRUPTS.PASTE 'LISPINTERRUPTS))
    (INTERRUPTCHAR (CHARCODE "1,v")
           '(PASTEFROMCLIPBOARD))
    (INTERRUPTCHAR (CHARCODE "1,V")
           '(PASTEFROMCLIPBOARD))
    (CL:WHEN (BOUNDP 'TEDIT.READTABLE)                       (* ; "TEDIT")

        (* ;; "Paste")

        (TEDIT.SETFUNCTION (CHARCODE "1,v")
               (FUNCTION PASTEFROMCLIPBOARD)
               TEDIT.READTABLE)
        (TEDIT.SETFUNCTION (CHARCODE "1,V")
               (FUNCTION PASTEFROMCLIPBOARD)
               TEDIT.READTABLE)

        (* ;; "Copy")

        (TEDIT.SETFUNCTION (CHARCODE "1,c")
               (FUNCTION TEDIT.COPYTOCLIPBOARD)
               TEDIT.READTABLE)
        (TEDIT.SETFUNCTION (CHARCODE "1,C")
               (FUNCTION TEDIT.COPYTOCLIPBOARD)
               TEDIT.READTABLE)

        (* ;; "Extract")

        (TEDIT.SETFUNCTION (CHARCODE "1,X")
               (FUNCTION TEDIT.EXTRACTTOCLIPBOARD)
               TEDIT.READTABLE)
        (TEDIT.SETFUNCTION (CHARCODE "1,x")
               (FUNCTION TEDIT.EXTRACTTOCLIPBOARD)
               TEDIT.READTABLE))
    (CL:WHEN (GETP 'SEDIT 'FILEDATES)                        (* ; 
                                                             "SEDIT copy: INTERRUPTCHAR does paste")
        (SEDIT:ADD-COMMAND "1,c" 'SEDIT.COPYTOCLIPBOARD)
        (SEDIT:ADD-COMMAND "1,C" 'SEDIT.COPYTOCLIPBOARD)
        (SEDIT:RESET-COMMANDS))])

(GETCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 23-Feb-2021 11:32 by rmk:")
                                                            (* ; "Edited 25-Apr-2018 16:56 by rmk:")
    (CL:WITH-OPEN-STREAM (s (CLIPBOARD-PASTE-STREAM))
           (CONCATCODES (BIND C WHILE (SETQ C (READCCODE s)) COLLECT C])

(PUTCLIPBOARD
  [LAMBDA (OBJECT PRINTFN)                              (* ; "Edited 23-Feb-2021 11:32 by rmk:")
                                                            (* ; "Edited 25-Apr-2018 16:49 by rmk:")
    (CL:WITH-OPEN-STREAM (s (CLIPBOARD-COPY-STREAM))
           (IF PRINTFN
               THEN (APPLY* PRINTFN OBJECT s)
             ELSE (PRIN3 OBJECT s])

(PASTEFROMCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 15-Feb-2021 23:43 by rmk:")
                                                            (* ; "Edited 18-Apr-2018 13:56 by rmk:")
                                                            (* ; "Edited 17-Apr-2018 23:11 by rmk:")

    (* ;; "If for some reason TTY process doesn't have a window (e.g. TEXEC), we can only do the character printing.  Presumably the right thing to do--no image objects in an exec.")

    (* ;; "Should be able to just call COPYINSERT, but the default BKSYSBUF puts in string quotes.")

    (LET [(STR (GETCLIPBOARD))
          (WINDOW (PROCESS.WINDOW (TTY.PROCESS]
         (IF (AND WINDOW (WINDOWPROP WINDOW 'COPYINSERTFN))
             THEN (COPYINSERT STR)
           ELSE (BIND C WHILE (SETQ C (GNCCODE STR)) DO (BKSYSCHARCODE C])

(LISPINTERRUPTS.PASTE
  [LAMBDA NIL                                           (* ; "Edited 18-Apr-2018 22:59 by rmk:")

    (* ;; "So paste interrupts will be installed in every process")

    (APPEND [LIST (LIST (CHARCODE "1,v")
                        '(PASTEFROMCLIPBOARD))
                  (LIST (CHARCODE "1,V")
                        '(PASTEFROMCLIPBOARD]
           (LISPINTERRUPTS.ORIG])

(CLIPBOARD-COPY-STREAM
  [LAMBDA NIL                                           (* ; "Edited 23-Feb-2021 17:31 by rmk:")

    (* ;; "Clipboard is UNICODE and UTF8")

    (LET (STRM (OST (UNIX-GETENV "OSTYPE")))
         [SETQ STRM (CREATE-PROCESS-STREAM '(CL:IF (STRPOS "darwin" OST)
                                                "pbcopy"
                                                "xclip -i -selection clipboard")]
         (\EXTERNALFORMAT STRM CLIPBOARD-FORMAT)
         STRM])

(CLIPBOARD-PASTE-STREAM
  [LAMBDA NIL                                           (* ; "Edited 23-Feb-2021 17:29 by rmk:")
    (LET (STRM (OST (UNIX-GETENV "OSTYPE")))
         (SETQ STRM (CREATE-PROCESS-STREAM (CL:IF (STRPOS "darwin" OST)
                                               "pbpaste"
                                               "xclip -o -selection clipboard")))
         (\EXTERNALFORMAT STRM CLIPBOARD-FORMAT)
         [SETFILEINFO STRM 'ENDOFSTREAMOP #'(CL:LAMBDA (s)
                                                   (RETFROM (FUNCTION READCCODE)
                                                          NIL]
         STRM])
)
(DEFINEQ

(TEDIT.COPYTOCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 18-Apr-2018 00:02 by rmk:")
    (LET [(TEXTSTREAM (TEXTSTREAM (TTY.PROCESS]
         (IF TEXTSTREAM
             THEN (PUTCLIPBOARD (TEDIT.SEL.AS.STRING TEXTSTREAM])

(TEDIT.EXTRACTTOCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 19-Apr-2020 12:17 by rmk:")
                                                            (* ; "Edited 18-Apr-2018 00:02 by rmk:")
    (LET [(TEXTSTREAM (TEXTSTREAM (TTY.PROCESS]
         (IF TEXTSTREAM
             THEN (PUTCLIPBOARD (TEDIT.SEL.AS.STRING TEXTSTREAM))
                   (TEDIT.DELETE TEXTSTREAM (TEDIT.GETSEL TEXTSTREAM])
)
(DEFINEQ

(SEDIT.COPYTOCLIPBOARD
  [LAMBDA (CONTEXT)                                     (* ; "Edited  8-Aug-2020 15:25 by rmk:")
                                                            (* ; "Edited 24-Apr-2018 20:39 by rmk:")
                                                            (* ; "Edited 24-Apr-2018 20:33 by rmk:")
                                                            (* ; "Edited 23-Apr-2018 18:19 by rmk:")
    [CL:MULTIPLE-VALUE-BIND (SEL SELTYPE)
           (SEDIT:GET-SELECTION CONTEXT)

           (* ;; "SEL could be a list of several elements, or a structure, depending on SELTYPE.  ")

           (* ;; "SELTYPE=NIL means not a valid selection, and SEL is NIL.  Non-NIL values are :SUB-LIST, :CHARACTERS, and T")

           (CL:WHEN SELTYPE
               [PUTCLIPBOARD (CONS SEL (EQ SELTYPE :SUB-LIST))
                      (FUNCTION (LAMBDA (PAIR STREAM)
                                  (LET ((*PRINT-PRETTY* T)
                                        (PRETTYTABFLG NIL)
                                        (FONTCHANGEFLG NIL)
                                        (%#RPARS NIL))
                                       (DECLARE (SPECVARS *PRINT-PRETTY* %#RPARS PRETTYTABFLG 
                                                           FONTCHANGEFLG))
                                       (PRINTDEF (CAR PAIR)
                                              0 NIL (CDR PAIR)
                                              NIL STREAM])]
    T])
)

(RPAQ? CLIPBOARD-FORMAT :UTF8)
(DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DOCOPY 

(FILESLOAD (SYSLOAD)
       UNIXCOMM UNICODE)


(INSTALL-CLIPBOARD)
)
(DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DONTCOPY COMPILERVARS 

(ADDTOVAR NLAMA )

(ADDTOVAR NLAML )

(ADDTOVAR LAMA )
)
(PUTPROPS CLIPBOARD COPYRIGHT (NONE))
(DECLARE%: DONTCOPY
  (FILEMAP (NIL (1309 6431 (INSTALL-CLIPBOARD 1319 . 3141) (GETCLIPBOARD 3143 . 3517) (PUTCLIPBOARD 3519
 . 3924) (PASTEFROMCLIPBOARD 3926 . 4844) (LISPINTERRUPTS.PASTE 4846 . 5267) (CLIPBOARD-COPY-STREAM 
5269 . 5771) (CLIPBOARD-PASTE-STREAM 5773 . 6429)) (6432 7191 (TEDIT.COPYTOCLIPBOARD 6442 . 6723) (
TEDIT.EXTRACTTOCLIPBOARD 6725 . 7189)) (7192 8731 (SEDIT.COPYTOCLIPBOARD 7202 . 8729)))))
STOP
\ No newline at end of file
+(DEFINE-FILE-INFO READTABLE "INTERLISP" PACKAGE "INTERLISP")
(FILECREATED "23-Feb-2021 22:13:09" 
{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>CLIPBOARD.;52 9082   

      changes to%:  (FNS CLIPBOARD-COPY-STREAM CLIPBOARD-PASTE-STREAM)

      previous date%: "23-Feb-2021 11:34:57" 
{DSK}<Users>kaplan>Local>medley3.5>git-medley>library>CLIPBOARD.;50)


(PRETTYCOMPRINT CLIPBOARDCOMS)

(RPAQQ CLIPBOARDCOMS
       [                                                     (* ; "Enable copy and paste")
        (FNS INSTALL-CLIPBOARD GETCLIPBOARD PUTCLIPBOARD PASTEFROMCLIPBOARD LISPINTERRUPTS.PASTE 
             CLIPBOARD-COPY-STREAM CLIPBOARD-PASTE-STREAM)
        (FNS TEDIT.COPYTOCLIPBOARD TEDIT.EXTRACTTOCLIPBOARD)
        (FNS SEDIT.COPYTOCLIPBOARD)
        (INITVARS (CLIPBOARD-FORMAT :UTF8))
        (DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DOCOPY (FILES (SYSLOAD)
                                                              UNIXCOMM UNICODE)
               (P (INSTALL-CLIPBOARD)))
        (DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DONTCOPY COMPILERVARS (ADDVARS (NLAMA)
                                                                             (NLAML)
                                                                             (LAMA])



(* ; "Enable copy and paste")

(DEFINEQ

(INSTALL-CLIPBOARD
  [LAMBDA NIL                                               (* ; "Edited  8-Aug-2020 07:59 by rmk:")
                                                            (* ; "Edited 19-Apr-2020 12:15 by rmk:")
                                                            (* ; "Edited 18-Apr-2018 23:00 by rmk:")
    (CL:WHEN (GETD 'LISPINTERRUPTS.PASTE)
        (MOVD? 'LISPINTERRUPTS 'LISPINTERRUPTS.ORIG)
        (MOVD 'LISPINTERRUPTS.PASTE 'LISPINTERRUPTS))
    (INTERRUPTCHAR (CHARCODE "1,v")
           '(PASTEFROMCLIPBOARD))
    (INTERRUPTCHAR (CHARCODE "1,V")
           '(PASTEFROMCLIPBOARD))
    (CL:WHEN (BOUNDP 'TEDIT.READTABLE)                       (* ; "TEDIT")

        (* ;; "Paste")

        (TEDIT.SETFUNCTION (CHARCODE "1,v")
               (FUNCTION PASTEFROMCLIPBOARD)
               TEDIT.READTABLE)
        (TEDIT.SETFUNCTION (CHARCODE "1,V")
               (FUNCTION PASTEFROMCLIPBOARD)
               TEDIT.READTABLE)

        (* ;; "Copy")

        (TEDIT.SETFUNCTION (CHARCODE "1,c")
               (FUNCTION TEDIT.COPYTOCLIPBOARD)
               TEDIT.READTABLE)
        (TEDIT.SETFUNCTION (CHARCODE "1,C")
               (FUNCTION TEDIT.COPYTOCLIPBOARD)
               TEDIT.READTABLE)

        (* ;; "Extract")

        (TEDIT.SETFUNCTION (CHARCODE "1,X")
               (FUNCTION TEDIT.EXTRACTTOCLIPBOARD)
               TEDIT.READTABLE)
        (TEDIT.SETFUNCTION (CHARCODE "1,x")
               (FUNCTION TEDIT.EXTRACTTOCLIPBOARD)
               TEDIT.READTABLE))
    (CL:WHEN (GETP 'SEDIT 'FILEDATES)                        (* ; 
                                                             "SEDIT copy: INTERRUPTCHAR does paste")
        (SEDIT:ADD-COMMAND "1,c" 'SEDIT.COPYTOCLIPBOARD)
        (SEDIT:ADD-COMMAND "1,C" 'SEDIT.COPYTOCLIPBOARD)
        (SEDIT:RESET-COMMANDS))])

(GETCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 23-Feb-2021 11:32 by rmk:")
                                                            (* ; "Edited 25-Apr-2018 16:56 by rmk:")
    (CL:WITH-OPEN-STREAM (s (CLIPBOARD-PASTE-STREAM))
           (CONCATCODES (BIND C WHILE (SETQ C (READCCODE s)) COLLECT C])

(PUTCLIPBOARD
  [LAMBDA (OBJECT PRINTFN)                              (* ; "Edited 23-Feb-2021 11:32 by rmk:")
                                                            (* ; "Edited 25-Apr-2018 16:49 by rmk:")
    (CL:WITH-OPEN-STREAM (s (CLIPBOARD-COPY-STREAM))
           (IF PRINTFN
               THEN (APPLY* PRINTFN OBJECT s)
             ELSE (PRIN3 OBJECT s])

(PASTEFROMCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 15-Feb-2021 23:43 by rmk:")
                                                            (* ; "Edited 18-Apr-2018 13:56 by rmk:")
                                                            (* ; "Edited 17-Apr-2018 23:11 by rmk:")

    (* ;; "If for some reason TTY process doesn't have a window (e.g. TEXEC), we can only do the character printing.  Presumably the right thing to do--no image objects in an exec.")

    (* ;; "Should be able to just call COPYINSERT, but the default BKSYSBUF puts in string quotes.")

    (LET [(STR (GETCLIPBOARD))
          (WINDOW (PROCESS.WINDOW (TTY.PROCESS]
         (IF (AND WINDOW (WINDOWPROP WINDOW 'COPYINSERTFN))
             THEN (COPYINSERT STR)
           ELSE (BIND C WHILE (SETQ C (GNCCODE STR)) DO (BKSYSCHARCODE C])

(LISPINTERRUPTS.PASTE
  [LAMBDA NIL                                           (* ; "Edited 18-Apr-2018 22:59 by rmk:")

    (* ;; "So paste interrupts will be installed in every process")

    (APPEND [LIST (LIST (CHARCODE "1,v")
                        '(PASTEFROMCLIPBOARD))
                  (LIST (CHARCODE "1,V")
                        '(PASTEFROMCLIPBOARD]
           (LISPINTERRUPTS.ORIG])

(CLIPBOARD-COPY-STREAM
  [LAMBDA NIL                                           (* ; "Edited 23-Feb-2021 22:11 by rmk:")

    (* ;; "Clipboard is UNICODE and UTF8")

    (LET (STRM (OST (UNIX-GETENV "OSTYPE")))
         (SETQ STRM (CREATE-PROCESS-STREAM (CL:IF (STRPOS "darwin" OST)
                                               "pbcopy"
                                               "xclip -i -selection clipboard")))
         (\EXTERNALFORMAT STRM CLIPBOARD-FORMAT)
         STRM])

(CLIPBOARD-PASTE-STREAM
  [LAMBDA NIL                                           (* ; "Edited 23-Feb-2021 17:29 by rmk:")
    (LET (STRM (OST (UNIX-GETENV "OSTYPE")))
         (SETQ STRM (CREATE-PROCESS-STREAM (CL:IF (STRPOS "darwin" OST)
                                               "pbpaste"
                                               "xclip -o -selection clipboard")))
         (\EXTERNALFORMAT STRM CLIPBOARD-FORMAT)
         [SETFILEINFO STRM 'ENDOFSTREAMOP #'(CL:LAMBDA (s)
                                                   (RETFROM (FUNCTION READCCODE)
                                                          NIL]
         STRM])
)
(DEFINEQ

(TEDIT.COPYTOCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 18-Apr-2018 00:02 by rmk:")
    (LET [(TEXTSTREAM (TEXTSTREAM (TTY.PROCESS]
         (IF TEXTSTREAM
             THEN (PUTCLIPBOARD (TEDIT.SEL.AS.STRING TEXTSTREAM])

(TEDIT.EXTRACTTOCLIPBOARD
  [LAMBDA NIL                                           (* ; "Edited 19-Apr-2020 12:17 by rmk:")
                                                            (* ; "Edited 18-Apr-2018 00:02 by rmk:")
    (LET [(TEXTSTREAM (TEXTSTREAM (TTY.PROCESS]
         (IF TEXTSTREAM
             THEN (PUTCLIPBOARD (TEDIT.SEL.AS.STRING TEXTSTREAM))
                   (TEDIT.DELETE TEXTSTREAM (TEDIT.GETSEL TEXTSTREAM])
)
(DEFINEQ

(SEDIT.COPYTOCLIPBOARD
  [LAMBDA (CONTEXT)                                     (* ; "Edited  8-Aug-2020 15:25 by rmk:")
                                                            (* ; "Edited 24-Apr-2018 20:39 by rmk:")
                                                            (* ; "Edited 24-Apr-2018 20:33 by rmk:")
                                                            (* ; "Edited 23-Apr-2018 18:19 by rmk:")
    [CL:MULTIPLE-VALUE-BIND (SEL SELTYPE)
           (SEDIT:GET-SELECTION CONTEXT)

           (* ;; "SEL could be a list of several elements, or a structure, depending on SELTYPE.  ")

           (* ;; "SELTYPE=NIL means not a valid selection, and SEL is NIL.  Non-NIL values are :SUB-LIST, :CHARACTERS, and T")

           (CL:WHEN SELTYPE
               [PUTCLIPBOARD (CONS SEL (EQ SELTYPE :SUB-LIST))
                      (FUNCTION (LAMBDA (PAIR STREAM)
                                  (LET ((*PRINT-PRETTY* T)
                                        (PRETTYTABFLG NIL)
                                        (FONTCHANGEFLG NIL)
                                        (%#RPARS NIL))
                                       (DECLARE (SPECVARS *PRINT-PRETTY* %#RPARS PRETTYTABFLG 
                                                           FONTCHANGEFLG))
                                       (PRINTDEF (CAR PAIR)
                                              0 NIL (CDR PAIR)
                                              NIL STREAM])]
    T])
)

(RPAQ? CLIPBOARD-FORMAT :UTF8)
(DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DOCOPY 

(FILESLOAD (SYSLOAD)
       UNIXCOMM UNICODE)


(INSTALL-CLIPBOARD)
)
(DECLARE%: DONTEVAL@LOAD DOEVAL@COMPILE DONTCOPY COMPILERVARS 

(ADDTOVAR NLAMA )

(ADDTOVAR NLAML )

(ADDTOVAR LAMA )
)
(PUTPROPS CLIPBOARD COPYRIGHT (NONE))
(DECLARE%: DONTCOPY
  (FILEMAP (NIL (1309 6429 (INSTALL-CLIPBOARD 1319 . 3141) (GETCLIPBOARD 3143 . 3517) (PUTCLIPBOARD 3519
 . 3924) (PASTEFROMCLIPBOARD 3926 . 4844) (LISPINTERRUPTS.PASTE 4846 . 5267) (CLIPBOARD-COPY-STREAM 
5269 . 5769) (CLIPBOARD-PASTE-STREAM 5771 . 6427)) (6430 7189 (TEDIT.COPYTOCLIPBOARD 6440 . 6721) (
TEDIT.EXTRACTTOCLIPBOARD 6723 . 7187)) (7190 8729 (SEDIT.COPYTOCLIPBOARD 7200 . 8727)))))
STOP
\ No newline at end of file
diff --git a/library/CLIPBOARD.LCOM b/library/CLIPBOARD.LCOM
index f296faef..c77009e5 100644
Binary files a/library/CLIPBOARD.LCOM and b/library/CLIPBOARD.LCOM differ
