From fa47b427173cfffa0080d4612e4e7819d5071a79 Mon Sep 17 00:00:00 2001 From: Mischa POSLAWSKY Date: Tue, 11 Apr 2017 01:29:51 +0200 Subject: [PATCH] latin: rm4scc circumfix Include start and (distinct) end lines in samples, to better match the official specification, even though it remains invalid by not appending the checksum mark. --- latinsample.js | 2 +- writing-latn.inc.pl | 25 +++++++++++++++---------- 2 files changed, 16 insertions(+), 11 deletions(-) diff --git a/latinsample.js b/latinsample.js index 3ef69a4..a3ce6db 100644 --- a/latinsample.js +++ b/latinsample.js @@ -55,7 +55,7 @@ function appendsample() { } if (cols[29] && !cols[28]) { // circumfix sign if no repetition - output = cols[29] + output + cols[29]; + output = cols[29] + output + (cols[30] || cols[29]); } samplecol.innerHTML = output; } diff --git a/writing-latn.inc.pl b/writing-latn.inc.pl index 2eadbc7..f313a31 100644 --- a/writing-latn.inc.pl +++ b/writing-latn.inc.pl @@ -301,15 +301,19 @@ my $U = 0; # optional unicode alternatives ) ], 'RM4SCC' => [ - map { sprintf - '' - . '', - join ' m2', - map { sprintf ',%dv%dm0,-%d', - ($_ & 1 ? 0 : 2), 2 + ($_ & 2) + ($_ & 1) * 2, - ($_ & 1 ? 0 : 2) + 2 + ($_ & 2) + ($_ & 1) * 2, - } - split // + map { + my $len = length $_; + !$len ? '' : sprintf( + '' + . '', + $len * 5, $len * 2, + join ' m2', + map { sprintf ',%dv%dm0,-%d', + ($_ & 1 ? 0 : 2), 2 + ($_ & 2) + ($_ & 1) * 2, + ($_ & 1 ? 0 : 2) + 2 + ($_ & 2) + ($_ & 1) * 2, + } + split // + ); } qw( 2121 2301 @@ -318,7 +322,8 @@ my $U = 0; # optional unicode alternatives 1032 1212 1230 3012 3030 3210 1122 1302 1320 3102 3120 3300 0033 - ) # 0 for space + ), # 0 for space + '', 1, 3 # start/end ], 'Pigpen' => [ map { -- 2.30.0