1
0
mirror of synced 2026-03-22 17:18:10 +00:00
Files
Interlisp.medley/lispusers/CONVERT-TO-UTF8.TEDIT
rmkaplan 7a7fca0bcf Add lispusers/CONVERT-TO-UTF8 (#2518)
* Add lispusers/CONVERT-TO-UTF8
* FILETYPE with no DFASL defaults to :FAKE-COMPILE-FILE
2026-03-09 12:15:14 -07:00

26 lines
3.3 KiB
Plaintext
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
Medley CONVERT-TO-UTF8
2
4
1
CONVERT-TO-UTF8
1
4
By Ron Kaplan
This document was last edited in February 2026.
This file contains a single function that facilitates the conversion of Medley source files from the default :MCCS external format to :UTF-8. The characters in the UTF-8 versions will have the same appearance outside of Medley (e.g. in github) as they do in Medley, even though the character-encoding byte sequences will be different for characters outside of Asciii (and for left-arrow and up-arrow).
(CONVERT-TO-UTF8 FILE FILETYPE) [Function]
This first ensures that EXPORTS.ALL is loaded, then loads the contents of FILE to property lists and also loads the EVAL@COMPILE items on FILE. It then performs (MAKEFILE FILE '(NEW :UTF-8)) and compiles all the functions on the resulting converted file according to its FILETYPE property.
There are apparently mistaken cases where the FILETYPE is CL:COMPILE-FILE but the current compile file is an LCOM and there is no DFASL. In that case, FILE's FILETYPE is changed to FILETYPE, if provided, or :FAKE-COMPILE-FILE.
(SEQUENCE NIL NIL (0 0 0 0) ((PAGE NIL (PAPERSIZE Letter STARTINGPAGE# NIL LANDSCAPE? NIL FOLIOINFO (ARABIC "" "")) (0 0 612 792) ((HEADING NIL (HEADINGTYPE RUNNINGHEAD) (84 744 528 36) NIL) (TEXT NIL NIL (84 96 456 600) NIL))) (ALTERNATE NIL NIL (0 0 0 0) ((PAGE NIL (PAPERSIZE Letter FOLIOINFO (ARABIC)) (0 0 612 792) ((FOLIO NIL (PARALOOKS (QUAD CENTERED) CHARLOOKS (SUPERSCRIPT 0 INVISIBLE OFF SELECTPOINT OFF PROTECTED OFF SIZE 10 FAMILY MODERN OVERLINE OFF STRIKEOUT OFF UNDERLINE OFF EXPANSION REGULAR SLOPE REGULAR WEIGHT MEDIUM INVERTED OFF USERINFO NIL STYLE NIL) FORMATINFO (ARABIC)) (174 36 288 36) NIL) (HEADING NIL (HEADINGTYPE RUNNINGHEAD) (84 744 528 36) NIL) (TEXT NIL NIL (84 96 456 600) NIL))) (PAGE NIL (PAPERSIZE Letter FOLIOINFO (ARABIC)) (0 0 612 792) ((FOLIO NIL (PARALOOKS (QUAD CENTERED) CHARLOOKS (SUPERSCRIPT 0 INVISIBLE OFF SELECTPOINT OFF PROTECTED OFF SIZE 10 FAMILY MODERN OVERLINE OFF STRIKEOUT OFF UNDERLINE OFF EXPANSION REGULAR SLOPE REGULAR WEIGHT MEDIUM INVERTED OFF USERINFO NIL STYLE NIL) FORMATINFO (ARABIC)) (174 36 288 36) NIL) (HEADING NIL (HEADINGTYPE RUNNINGHEAD) (84 744 528 36) NIL) (TEXT NIL NIL (84 96 456 600) NIL)))))))1$4È$È1È$1ŠŠ8$1ŠŠ8$JÈ$È PAGEHEADING RUNNINGHEAD/MODERN
(CHARPROPS (COLOR . BLACK))0CLASSIC
(CHARPROPS (COLOR . BLACK))/MODERN
(CHARPROPS (COLOR . BLACK))/MODERN
(CHARPROPS (COLOR . BLACK))/MODERN (CHARPROPS (COLOR . BLACK))3
TIMESROMAN$(CHARPROPS (COLOR . BLACK)) HRULE.GETFN HRULE.GETFN HRULE.GETFN HRULE.GETFN HRULE.GETFN1
J<s˜I(((CLEARGET) (CHARENCODING . MCCS)))PROPS:.DATE:kh
S=-zº