unicode: support legend in common method
[sheet.git] / Shiar_Sheet / FormatChar.pm
index 839144fb5e2328581ccd5e97f4a8c50d4aaaa5b2..b2e4d09cbf22b044434a84b2e63b2a709b714efc 100644 (file)
@@ -275,13 +275,21 @@ sub print {
 }
 
 sub legend {
-       my @classes = (
+       my $self = shift;
+       my @classes = $self->{style} eq 'univer' ? (
                [l5 => 'unicode 1.1'],
                [l4 => '20th century'],
                [l3 => 'in 6.0 (2010)'],
                [l2 => 'recent assignments'],
                [l1 => 'proposed'],
                [ex => 'irregular'],
+       ) : (
+               [l5 => 'ascii'],
+               [l4 => $self->{style} eq 'di' ? 'digraph' : 'latin1'],
+               [l3 => $self->{style} eq 'di' ? 'proposed' : 'HTML4'],
+               [l2 => 'unicode ≤6.0'],
+               [l1 => 'other unicode'],
+               [ex => 'discouraged'],
        );
 
        return (