From: Mischa POSLAWSKY Date: Mon, 10 Apr 2017 23:29:51 +0000 (+0200) Subject: latin: rm4scc circumfix X-Git-Tag: v1.10~166 X-Git-Url: http://git.shiar.nl/sheet.git/commitdiff_plain/fa47b427173cfffa0080d4612e4e7819d5071a79?ds=sidebyside 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. --- 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 {