From e79bf42c2fa43f131f79d0891694e59434f820e9 Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Sat, 29 Jun 2024 05:58:21 -0400 Subject: a8cat: handle ASCII tab/backspace/bell in -r mode. --- a8cat.rst | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) (limited to 'a8cat.rst') diff --git a/a8cat.rst b/a8cat.rst index 68a4297..7b91fa9 100644 --- a/a8cat.rst +++ b/a8cat.rst @@ -2,9 +2,9 @@ a8cat ===== --------------------------------------------------- -Convert Atari 8-bit text to UTF-8 encoded Unicode. --------------------------------------------------- +------------------------------------------------------------- +Convert Atari 8-bit text to UTF-8 encoded Unicode (and back). +------------------------------------------------------------- .. include:: manhdr.rst @@ -26,13 +26,17 @@ goes to standard output; to write to a file, use a command like:: a8cat atari.txt > converted.txt -The output is plain UTF-8 Unicode, without BOM. It will display correctly -in modern terminals that support Unicode and UTF-8. If you get lots of -"empty rectangle" characters, it means your font lacks the glyphs for -the codepoints; try using the Deja Vu Sans and/or Symbola fonts. +The output is UTF-8 Unicode, without BOM, but possibly with +ANSI/VT-100 control sequences. It will display correctly in modern +terminals that support Unicode and UTF-8. If you get lots of "empty +rectangle" characters, it means your font lacks the glyphs for the +codepoints; try using the Deja Vu Sans and/or Symbola fonts. + +If you want to pipe the output to a pager, **less -MR** is +recommended. It will display the inverse characters correctly. It's even possible to edit the converted text and turn it back into -ATASCII, if you're very careful. +ATASCII, if you're very careful. See the **-r** option, below. Inverse video (characters codes above **$80**) are translated using the ANSI/VT-100 reverse video escape sequences. Exception: **$9B** @@ -54,8 +58,7 @@ OPTIONS -t Text mode. Normally, everything but EOL (**$9B**) is converted to a Unicode graphics character. In text mode, ATASCII tabs, backspace, - and bells are translated to the ASCII versions. Output created with this - option cannot be converted back to ATASCII with the **-r** option. + and bells are translated to the ASCII versions. -r Reverse conversion: Input is UTF-8, output is ATASCII (or XL ICS, with **-i**). @@ -78,6 +81,10 @@ OPTIONS back to ATASCII with the **-r** option, but of course there won't be any inverse-video characters in the result. +**--** + End of options; the rest of the arguments are filenames. Use this if you're + trying to work with files whose names begin with *-*. + **-h**, **--help** Show built-in help and exit. -- cgit v1.2.3