charset: indicate continued columns without overlap
[sheet.git] / charset.plp
index 5113b4214d9a4578b825dc614ce381553ddefe3c..5955c390a6da4327d490972a7bc3ea585659c873 100644 (file)
@@ -48,6 +48,7 @@ print join " •\n", (
        }
        [
                iso      => 'ISO',
        }
        [
                iso      => 'ISO',
+               win      => 'Windows',
                dos      => 'DOS',
                mac      => 'Apple',
                ebcdic   => 'EBCDIC',
                dos      => 'DOS',
                mac      => 'Apple',
                ebcdic   => 'EBCDIC',
@@ -78,7 +79,7 @@ sub tabinput {
 
        state $ALIAS = {
                default    => [qw( u+0-639 utf-8+realsize iso-8859-1 iso-8859-15 cp1252 cp437 cp850 )],
 
        state $ALIAS = {
                default    => [qw( u+0-639 utf-8+realsize iso-8859-1 iso-8859-15 cp1252 cp437 cp850 )],
-               unicode    => [qw( uu+cols=32 u+0-4095 u+4096-6319 u+6320-8191 )],
+               unicode    => [qw( uu+cols=32+realsize u+0-4095 u+4096-6319 u+6320-8191 )],
                us         => [qw( cp437 cp863 gsm0338 AdobeStandardEncoding )],
                ebcdic     => [qw( cp37 cp500 cp1047 posix-bc cp1026 cp875 )],
                iso        => [map {"iso-8859-$_"} 1 .. 11, 13 .. 16],
                us         => [qw( cp437 cp863 gsm0338 AdobeStandardEncoding )],
                ebcdic     => [qw( cp37 cp500 cp1047 posix-bc cp1026 cp875 )],
                iso        => [map {"iso-8859-$_"} 1 .. 11, 13 .. 16],
@@ -345,15 +346,16 @@ sub range_cell {
                if ($len -= $rest) {
                        # continued on new row
                        my @next = ($len * $colsize, "$class joinu");
                if ($len -= $rest) {
                        # continued on new row
                        my @next = ($len * $colsize, "$class joinu");
+                       my $separate = $cols - $len > $rest;  # columns not on next row
                        if ($len > $rest) {
                                # minority remains
                                push @next, $name, $title;
                                $title ||= $name;
                        if ($len > $rest) {
                                # minority remains
                                push @next, $name, $title;
                                $title ||= $name;
-                               $name = '';
+                               $name = $separate && '…';
                        }
                        else {
                                # minority on next row
                        }
                        else {
                                # minority on next row
-                               push @next, '"', $title || $name;
+                               push @next, $separate && '"', $title || $name;
                        }
                        $table->{$offset + $colsize*$rest} //= \@next;
                        $class .= ' joind';
                        }
                        $table->{$offset + $colsize*$rest} //= \@next;
                        $class .= ' joind';