charset: improve arabic inheritance
authorMischa POSLAWSKY <perl@shiar.org>
Sat, 8 Apr 2017 13:48:10 +0000 (15:48 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Mon, 24 Apr 2017 23:51:41 +0000 (01:51 +0200)
charset.plp

index 1f2be55..51c391c 100644 (file)
@@ -49,7 +49,7 @@ sub tabinput {
                baltic     => [qw( iso-8859-4 iso-8859-13 cp1257 cp775 )],
                nordic     => [qw( iso-8859-10 cp865 cp861 MacIcelandic MacSami )],
                cyrillic   => [qw( koi8-r koi8-u koi8-f iso-8859-5 cp1251 MacCyrillic cp866 cp855 )], # MacUkrainian is broken
-               arabic     => [qw( iso-8859-6 cp1006 cp864 cp1256 MacArabic )], # MacFarsi same as MacArabic?
+               arabic     => [qw( iso-8859-6 cp1256 MacArabic cp864 cp1006 MacFarsi )],
                greek      => [qw( iso-8859-7 cp1253 MacGreek cp737 cp869 )],
                hebrew     => [qw( iso-8859-8 cp1255 MacHebrew cp862 )],
                thai       => [qw( iso-8859-11 cp874 MacThai )],
@@ -87,10 +87,10 @@ sub tabinput {
                        'gsm0338'     => ['ascii' => '0-127'],
 
                        'iso-8859-2'  => ['iso-8859-1' => '160'],
-                       'iso-8859-3'  => ['iso-8859-1' => '160'],
+                       'iso-8859-3'  => ['iso-8859-1' => '160'], #TODO: also apply to iso-8859-9
                        'iso-8859-4'  => ['iso-8859-2' => '160'],
                        'iso-8859-5'  => ['iso-8859-1' => '160'],
-                       'iso-8859-6'  => ['iso-8859-1' => '160'],
+                       'iso-8859-6'  => ['cp1256' => '128', 'iso-8859-1' => '160'],
                        'iso-8859-7'  => ['iso-8859-1' => '160'],
                        'iso-8859-8'  => ['iso-8859-1' => '160'],
                        'iso-8859-9'  => ['iso-8859-1' => '208-223+240'],
@@ -123,11 +123,11 @@ sub tabinput {
                        'cp775'       => ['cp850' => '128'],  # partial cp437
                        'cp866'       => ['cp437' => '128-175+224'],
                        'cp855'       => ['cp437' => '128'],
-                       'cp1006'      => ['cp437' => '128'],
+                       'cp1006'      => ['iso-8859-6' => '160', 'cp437' => '128'],
                        'cp737'       => ['cp437' => '128-175+224'],
                        'cp869'       => ['cp437' => '128'],
                        'cp862'       => ['cp437' => '128-159'],
-                       'cp864'       => ['cp437' => '128'],
+                       'cp864'       => ['MacArabic' => '128', 'iso-8859-6' => '128', 'cp437' => '128'], #TODO: compare form variants
 
                        'koi8-u'      => ['koi8-r' => 128],
                        'koi8-f'      => ['koi8-u' => 128],
@@ -141,8 +141,8 @@ sub tabinput {
                        'MacSami'     => ['MacIcelandic' => '144', 'MacRoman' => '144'],
                        'MacGreek'    => ['MacRoman' => '128'],
                        'MacCyrillic' => ['MacRoman' => '128'],
-                       'MacHebrew'   => ['MacRoman' => '128-143+160'], # partial ascii
-                       'MacArabic'   => ['MacRoman' => '128'],
+                       'MacHebrew'   => ['iso-8859-8' => '128', 'MacRoman' => '128-143+160'], # partial ascii
+                       'MacArabic'   => ['iso-8859-6' => '128', 'cp864' => '128', 'MacRoman' => '128'], #TODO: multiple parents
                        'MacFarsi'    => ['MacArabic' => '176-191', 'MacRoman' => '128'],
                };