From e0385cad013e75592155c0f9aa8bca0af3d4d0a7 Mon Sep 17 00:00:00 2001 From: Matthew Mondor Date: Mon, 3 Mar 2025 14:42:28 +0000 Subject: [PATCH] AnalogTerm2: Remap Linux-extension "0" DEC Special Graphics from U+25AE to U+2588 --- .../analogterm2/fonts/6x6/beditor-6-ansi.txt.gz | Bin 3960 -> 3959 bytes mmsoftware/analogterm2/fonts/6x6/beditor-6.txt | 16 ++++----- mmsoftware/analogterm2/src/font.c | 2 +- mmsoftware/analogterm2/tests/dec-graphics.txt | 2 +- .../analogterm2/tests/dec-unicode-linux-notes.txt | 21 ++++++++++++ mmsoftware/analogterm2/tests/dec-unicode.lisp | 14 ++++++++ mmsoftware/analogterm2/tests/dec-unicode.txt | 37 +++++++++++++++++++++ 7 files changed, 82 insertions(+), 10 deletions(-) create mode 100644 mmsoftware/analogterm2/tests/dec-unicode-linux-notes.txt create mode 100644 mmsoftware/analogterm2/tests/dec-unicode.lisp create mode 100644 mmsoftware/analogterm2/tests/dec-unicode.txt diff --git a/mmsoftware/analogterm2/fonts/6x6/beditor-6-ansi.txt.gz b/mmsoftware/analogterm2/fonts/6x6/beditor-6-ansi.txt.gz index 88fd9c71b8c4de0f2db0b77f680b6b8f721b2bf3..ad1f8b0bb098e24cac7c61b2fb6e4e0f4a123a5b 100644 GIT binary patch delta 156 zcmV;N0Av679`_yxABzY8HNVBN2j&icuD62m-A5JIF&yuC+#Kk92b>MV^WlSs-98w{ z`$y;9V8dAquIY%G_B%YUI6Cu&-$7UG2V<$o7E5=LobQfWdb^CV?mJj3j=88dp2u7t zA)N0H(G?P8GY~a!yHpgPgA#>TAAS_ykv;M6BmIM02Csb=gZHhA@$bPa#>J=$KK~b$ K!j!Ncb^rjp8cd7; delta 157 zcmV;O0Am059{3&yABzY8ly1YZ2j&icJURBkICwrfJO;bBVsL>(%(UO(LHf}FGW-tD zhmZLqDI)lSkh9E<_F`~JM+{%K;%3ALEwLYrMIuiuzWckNma-*RtosgDiDPc5jps3U zM+oPOLv()xc??7i+$$BuhoD5^y@wyg7i3TT<4FJDmccvU#o%S@V*GpXesM7jTHN_B L=kDt88+HHy>_SaP diff --git a/mmsoftware/analogterm2/fonts/6x6/beditor-6.txt b/mmsoftware/analogterm2/fonts/6x6/beditor-6.txt index 3283bcb..e6c24ca 100644 --- a/mmsoftware/analogterm2/fonts/6x6/beditor-6.txt +++ b/mmsoftware/analogterm2/fonts/6x6/beditor-6.txt @@ -1967,6 +1967,14 @@ OOOOOO ..O... ..O... +9608 +OOOOOO +OOOOOO +OOOOOO +OOOOOO +OOOOOO +OOOOOO + 9618 O.O.O. .O.O.O @@ -1975,14 +1983,6 @@ O.O.O. O.O.O. .O.O.O -9646 -...... -.OOO.. -.OOO.. -.OOO.. -...... -...... - 9670 ..O... .OOO.. diff --git a/mmsoftware/analogterm2/src/font.c b/mmsoftware/analogterm2/src/font.c index 866a39a..0b9c713 100644 --- a/mmsoftware/analogterm2/src/font.c +++ b/mmsoftware/analogterm2/src/font.c @@ -71,7 +71,7 @@ const uint32_t decgfx_unicode_table[128] = { 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, /* 43 - 48, '+' - '0' Linux console extensions */ - 0x2192, 0x2190, 0x2191, 0x2193, 47, 0x25AE, + 0x2192, 0x2190, 0x2191, 0x2193, 47, 0x2588, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, diff --git a/mmsoftware/analogterm2/tests/dec-graphics.txt b/mmsoftware/analogterm2/tests/dec-graphics.txt index c18ea05..b2069c4 100644 --- a/mmsoftware/analogterm2/tests/dec-graphics.txt +++ b/mmsoftware/analogterm2/tests/dec-graphics.txt @@ -7,7 +7,7 @@ Linux and tmux console extensions: , ← - ↑ . ↓ -0 ▮ +0 █ VT100: (95 - 126, '_' - '~') diff --git a/mmsoftware/analogterm2/tests/dec-unicode-linux-notes.txt b/mmsoftware/analogterm2/tests/dec-unicode-linux-notes.txt new file mode 100644 index 0000000..dc573e4 --- /dev/null +++ b/mmsoftware/analogterm2/tests/dec-unicode-linux-notes.txt @@ -0,0 +1,21 @@ +What DEC Special Graphics Linux extension "0" should point to: + +█ 0x2588 (9608) + +https://en.wikipedia.org/wiki/Box-drawing_characters +https://en.wikipedia.org/wiki/Block_Elements + + +Used to point at: 0x25AE (9646) "BLACK VERTICAL RECTANGLE" +https://en.wikipedia.org/wiki/Geometric_Shapes_%28Unicode_block%29 + + +AnalogTerminal also remaps some other graphics characters by default: +See https://en.wikipedia.org/wiki/ARIB_STD_B24_character_set for some + +0x25AE (9646) "black vertical rectangle" -> 0x25A0 (9632) "black square" +0x25AF (9647) "white vertical rectangle" -> 0x25A1 (9633) "white square" +0x25B2 (9650) "black up pointing triangle" -> 0x1FB6F (129903) "lower triangular one quarter block" +0x25BC (9660) "black down pointing triangle" -> 0x1FB6D (129901) "upper triangular one quarter block" +0x25B7 (9655) "white right pointing triangle", 0x1FB6C (129900) "left triangular one quarter block" + diff --git a/mmsoftware/analogterm2/tests/dec-unicode.lisp b/mmsoftware/analogterm2/tests/dec-unicode.lisp new file mode 100644 index 0000000..5ee2e89 --- /dev/null +++ b/mmsoftware/analogterm2/tests/dec-unicode.lisp @@ -0,0 +1,14 @@ +(defparameter *glyphs* + '(#\U00A0 #\U00A3 #\U00B0 #\U00B1 #\U00B7 #\U03C0 #\U2190 #\U2191 + #\U2192 #\U2193 #\U2260 #\U2264 #\U2265 #\U23BA #\U23BB #\U23BC + #\U23BD #\U2409 #\U240A #\U240B #\U240C #\U240D #\U2424 #\U2500 + #\U2502 #\U250C #\U2510 #\U2514 #\U2518 #\U251C #\U2524 #\U252c + #\U2534 #\U253C #\U2592 #\U2588 #\U25C6)) + +(defun p () + (loop + with l = *glyphs* + for c in l + for i = (char-code c) + do + (format t "U+~4,'0X ~A ~C~%" i i c))) diff --git a/mmsoftware/analogterm2/tests/dec-unicode.txt b/mmsoftware/analogterm2/tests/dec-unicode.txt new file mode 100644 index 0000000..55e795a --- /dev/null +++ b/mmsoftware/analogterm2/tests/dec-unicode.txt @@ -0,0 +1,37 @@ +U+00A0 160   +U+00A3 163 £ +U+00B0 176 ° +U+00B1 177 ± +U+00B7 183 · +U+03C0 960 π +U+2190 8592 ← +U+2191 8593 ↑ +U+2192 8594 → +U+2193 8595 ↓ +U+2260 8800 ≠ +U+2264 8804 ≤ +U+2265 8805 ≥ +U+23BA 9146 ⎺ +U+23BB 9147 ⎻ +U+23BC 9148 ⎼ +U+23BD 9149 ⎽ +U+2409 9225 ␉ +U+240A 9226 ␊ +U+240B 9227 ␋ +U+240C 9228 ␌ +U+240D 9229 ␍ +U+2424 9252 ␤ +U+2500 9472 ─ +U+2502 9474 │ +U+250C 9484 ┌ +U+2510 9488 ┐ +U+2514 9492 └ +U+2518 9496 ┘ +U+251C 9500 ├ +U+2524 9508 ┤ +U+252C 9516 ┬ +U+2534 9524 ┴ +U+253C 9532 ┼ +U+2592 9618 ▒ +U+2588 9608 █ +U+25C6 9670 ◆ -- 2.9.0