home *** CD-ROM | disk | FTP | other *** search
/ c't freeware shareware 1997 / CT_SW_97.ISO / pc / software / kommunik / win95 / w32-253.exe / WPM-LMTT.R < prev   
Text File  |  1996-12-18  |  15KB  |  376 lines

  1. ##
  2. ##  WPM-LMTT.R  (Local Mime Translation Table)
  3. ##  Copyright (c) 1994, David Harris, All Rights Reserved.
  4. ##
  5. ##  This file can be used as a model for a local resource which
  6. ##  maps ISO character sets to the code pages in use on the PCs
  7. ##  at your site.
  8. ##
  9. ##  Character translation tables:
  10. ##  Each translation table maps the characters in a particular
  11. ##  ISO set to your codepage's character set: the table can be used
  12. ##  bidirectionally when composing or decoding quoted-printable or
  13. ##  8BIT messages. Only characters from 128-255 are included in
  14. ##  the table, and each table must end with an ASCII NUL (0).
  15. ##
  16. ##  The sample tables in this file are the ones Pegasus Mail uses
  17. ##  by default: they map ISO character sets to the standard IBM
  18. ##  code page 437. You may define as many character sets as you
  19. ##  wish and Pegasus Mail will use them to translate incoming mail
  20. ##  but for outgoing mail it will only use ISO character sets.
  21. ##
  22. ##  The last resource in the file must be a "charset_list"
  23. ##  structure which ties the character strings naming an ISO
  24. ##  character set to the resource which maps it.
  25. ##
  26. #==========================================================
  27. #
  28. #   OPTIMAL CHARACTER TRANSLATIONS, should be used as
  29. #   a example for user defined tables in multilanguage fonts
  30. #   environment.
  31. #
  32. # WEST   ISO-8859-1 -->   CP 1252
  33. # CE     ISO-8859-2 -->   CP 1250
  34. # TR,AFR ISO-8859-3 --> ? CP 1252
  35. # BALTIC ISO-8859-4 -->   CP 1257
  36. # CYR    ISO-8859-5 -->   CP 1251
  37. # ARAB   ISO-8859-6 -->   CP 1256
  38. # GREEK  ISO-8859-7 -->   CP 1253
  39. # HEBR   ISO-8859-8 -->   CP 1255
  40. # TR     ISO-8859-9 -->   CP 1254
  41. # RUSS   KOI-8R     -->   CP 1251
  42. # VIETN                   CP 1258 (currently not implemented)
  43. #        ISO-8859-10      ???     (currently not implemented)
  44. #   Conversion tables from Jiri Kuchta, 8-12-96, kuchta@fee.vutbr.cz
  45. #
  46. #=========================================================
  47. ##
  48. ##  To use this file, modify it as required, then compile it with
  49. ##  the Pegasus Mail system resource compiler, RESCOM, using the
  50. ##  command 'rescom PM-LMTT.R'. This will produce the file
  51. ##  PM-LMTT.RSC, which should be copied into the same directory
  52. ##  as PMAIL.EXE, or into your home mailbox.
  53.  
  54. ##
  55. ##  The "charset_list" type is used to tie a particular name of
  56. ##  a character set to the table used to decode it.
  57. ##
  58.  
  59. typedef charset_list 25
  60.    {
  61.    repeat,
  62.    string 20,     # Character set name
  63.    integer        # resource ID of table to load.
  64.    };
  65.  
  66.  
  67. ###----------------------------------------------------------------
  68. ##                I S O - 8 8 5 9 - 1     (Latin 1)
  69. ###----------------------------------------------------------------
  70. ## Danish, Dutch, English, Faeroese, Finnish, French, German, Icelandic,
  71. ## Irish, Italian, Norwegian, Portuguese, Spanish and Swedish.
  72. ##
  73. ## optimal conversion into CP850, CP1252
  74.  
  75. structure iso8859_1
  76.     {
  77. # conversion ISO-1 --> 1252
  78.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  79.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  80.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  81.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  82. '\160', '°', '¢', '£', '§', '•', '|', 'ß',      #a0
  83.     '®', '©', '™', '´', '¨', '≠', 'Æ', 'ñ',      #a8
  84.    '∞', '±', '≤', '≥', '¥', 'µ', '∂', '∑',      #b0
  85.     '∏', 'π', '∫', 'ª', 'º', 'Ω', 'æ', 'ø',      #b8
  86.    '¿', '¡', '¬', '√', 'ƒ', '≈', 'Δ', '«',      #c0
  87.     '»', '…', ' ', 'À', 'Ã', 'Õ', 'Œ', 'œ',      #c8
  88.    '–', '—', '“', '”', '‘', '’', '÷', '◊',      #d0
  89.    'ÿ', 'Ÿ', '⁄', '€', '‹', '›', 'fi', 'fl',      #d8
  90.    '‡', '·', '‚', '„', '‰', 'Â', 'Ê', 'Á',      #e0
  91.    'Ë', 'È', 'Í', 'Î', 'Ï', 'Ì', 'Ó', 'Ô',      #e8
  92.    '', 'Ò', 'Ú', 'Û', 'Ù', 'ı', 'ˆ', '˜',      #f0
  93.    '¯', '˘', '˙', '˚', '¸', '˝', '˛', 'ˇ',      #f8
  94.    0
  95.     };
  96.  
  97. ###----------------------------------------------------------------
  98. ##                I S O - 8 8 5 9 - 2     (Latin 2)
  99. ###----------------------------------------------------------------
  100. ## Albanian, Czech, English, German, Hungarian, Polish, Rumanian,
  101. ## Serbo-Croatian, Slovak, Slovene and Swedish.
  102. ##
  103. ## optimal conversion into CP852, CP1250
  104.  
  105. structure iso8859_2
  106.    {
  107. # conversion ISO-2 --> 1250 (CE)
  108.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  109.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  110.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  111.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  112. '\160', '•', '¢', '£', '§', 'º', 'å', 'ß',      #a0
  113.     '®', 'ä', '™', 'ç', 'è', '≠', 'é', 'Ø',      #a8
  114.     '∞', 'π', '≤', '≥', '¥', 'æ', 'ú', '°',      #b0
  115.     '∏', 'ö', '∫', 'ù', 'ü', 'Ω', 'û', 'ø',      #b8
  116.    '¿', '¡', '¬', '√', 'ƒ', '≈', 'Δ', '«',      #c0
  117.     '»', '…', ' ', 'À', 'Ã', 'Õ', 'Œ', 'œ',      #c8
  118.    '–', '—', '“', '”', '‘', '’', '÷', '◊',      #d0
  119.     'ÿ', 'Ÿ', '⁄', '€', '‹', '›', 'fi', 'fl',      #d8
  120.    '‡', '·', '‚', '„', '‰', 'Â', 'Ê', 'Á',      #e0
  121.    'Ë', 'È', 'Í', 'Î', 'Ï', 'Ì', 'Ó', 'Ô',      #e8
  122.    '', 'Ò', 'Ú', 'Û', 'Ù', 'ı', 'ˆ', '˜',      #f0
  123.    '¯', '˘', '˙', '˚', '¸', '˝', '˛', '∑',      #f8
  124.    0
  125.    };
  126.  
  127. ###----------------------------------------------------------------
  128. ##                I S O - 8 8 5 9 - 3     (Latin 3)
  129. ###----------------------------------------------------------------
  130. ## Afrikaans, Catalan, English, Esperanto, French, Galician, German,
  131. ## Italian, Maltese and Turkish.
  132. ##
  133. ## optimal conversion into CP85x, CP125x
  134.  
  135. structure iso8859_3
  136.     {
  137. # conversion ISO-3 --> 1252
  138.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  139.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  140.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  141.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  142. '\160', 'H', 'Ø', '£', '§', ' ', 'H', 'ß',      #a0
  143.     '®', 'I', 'S', 'G', 'J', '≠', ' ', 'Z',      #a8
  144.     '∞', 'h', '≤', '≥', '¥', 'µ', 'h', '∑',      #b0
  145.     '∏', 'i', 's', 'g', 'j', 'Ω', ' ', 'z',      #b8
  146.     '¿', '¡', '¬', ' ', 'ƒ', 'C', 'C', '«',      #c0
  147.     '»', '…', ' ', 'À', 'Ã', 'Õ', 'Œ', 'œ',      #c8
  148.     ' ', '—', '“', '”', '‘', 'G', '÷', '◊',      #d0
  149.     'G', 'Ÿ', '⁄', '€', '‹', 'U', 'ä', 'fl',      #d8
  150.    '‡', '·', '‚', ' ', '‰', 'c', 'c', 'Á',      #e0
  151.     'Ë', 'È', 'Í', 'Î', 'Ï', 'Ì', 'Ó', 'Ô',      #e8
  152.    ' ', 'Ò', 'Ú', 'Û', 'Ù', 'g', 'ˆ', '˜',      #f0
  153.    'g', '˘', '˙', '˚', '¸', 'u', 'ö', 'ˇ',      #f8
  154.   0
  155.    };
  156.  
  157. ###----------------------------------------------------------------
  158. ##                I S O - 8 8 5 9 - 4     (Latin 4)
  159. ###----------------------------------------------------------------
  160. ## Danish, English, Estonian, Finnish, German, Greenlandic, Lappish,
  161. ## Latvian, Lithuanian, Norwegian and Swedish.
  162. ##
  163. ## optimal conversion into CP85x, CP1257
  164.  
  165.  
  166. structure iso8859_4
  167.     {
  168. # conversion ISO-4 --> 1257
  169.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  170.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  171.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  172.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  173. '\160', '¿', 'k', '™', '§', 'I', 'œ', 'ß',      #a0
  174.     'ç', '–', '«', 'Ã', 'T', '≠', 'fi', 'ù',      #a8
  175.     '∞', '‡', 'û', '∫', '¥', 'i', 'Ô', 'é',      #b0
  176.     'è', '', 'Á', 'Ï', 't', '?', '˛', '?',      #b8
  177.     '¬', 'A', 'A', 'A', 'ƒ', '≈', 'Ø', '¡',      #c0
  178.     '»', '…', 'Δ', 'E', 'À', 'I', 'I', 'Œ',      #c8
  179.     'D', '“', '‘', 'Õ', 'O', '’', '÷', '◊',      #d0
  180.     'ÿ', 'U', 'U', '‹', 'U', 'U', '€', 'fl',      #d8
  181.     '‚', 'a', 'a', 'a', '‰', 'Â', 'ø', '·',      #e0
  182.     'Ë', 'È', 'Ê', 'e', 'Î', 'i', 'i', 'Ó',      #e8
  183.     'd', 'Ú', 'Ù', 'Ì', 'o', 'ı', 'ˆ', '˜',      #f0
  184.     '¯', 'u', 'u', '¸', 'u', 'u', '˚', 'ˇ',      #f8
  185.    0
  186.    };
  187.  
  188.  
  189. structure iso8859_5
  190.    {
  191. # conversion ISO-5 --> 1251
  192.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  193.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  194.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  195.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  196. '\160', '®', 'Ä', 'Å', '™', 'Ω', '≤', 'Ø',      #a0
  197.     '£', 'ä', 'å', 'é', 'ç', '≠', '°', 'è',      #a8
  198.     '¿', '¡', '¬', '√', 'ƒ', '≈', 'Δ', '«',      #b0
  199.     '»', '…', ' ', 'À', 'Ã', 'Õ', 'Œ', 'œ',      #b8
  200.     '–', '—', '“', '”', '‘', '’', '÷', '◊',      #c0
  201.     'ÿ', 'Ÿ', '⁄', '€', '‹', '›', 'fi', 'fl',      #c8
  202.     '‡', '·', '‚', '„', '‰', 'Â', 'Ê', 'Á',      #d0
  203.     'Ë', 'È', 'Í', 'Î', 'Ï', 'Ì', 'Ó', 'Ô',      #d8
  204.     '', 'Ò', 'Ú', 'Û', 'Ù', 'ı', 'ˆ', '˜',      #e0
  205.     '¯', '˘', '˙', '˚', '¸', '˝', '˛', 'ˇ',      #e8
  206.     'π', '∏', 'ê', 'É', '∫', 'æ', '≥', 'ø',      #f0
  207.     'º', 'ö', 'ú', 'û', 'ù', ' ', '¢', 'ü',      #f8
  208.    0
  209.    };
  210.  
  211.  
  212. structure iso8859_6
  213.     {
  214. ## conversion ISO-6--> 1256
  215.     ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',         #80
  216.     ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',         #88
  217.     ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',         #90
  218.     ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',         #98
  219.     '\160',' ',   ' ',   ' ',   '§',   ' ',   ' ',   ' ',         #a0
  220.     ' ',   ' ',   ' ',   ' ',   '\161','\173',' ',   ' ',         #a8
  221.     ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',         #b0
  222.     ' ',   ' ',   ' ',   '\186',' ',   ' ',   ' ',   '\191',      #b8
  223.     ' ',   '\193','\194','\195','\196','\197','\198','\199',      #c0
  224.     '\200','\201','\202','\203','\204','\205','\206','\207',      #c8
  225.     '\208','\209','\210','\211','\212','\213','\214','\216',      #d0
  226.     '\217','\218','\219',' ',   ' ',   ' ',   ' ',   ' ',         #d8
  227.     '\220','\221','\222','\223','\225','\227','\228','\229',      #e0
  228.     '\230','\236','\237','\240','\241','\242','\243','\245',      #e8
  229.     '\246','\248','\250',' ',   ' ',   ' ',   ' ',   ' ',         #f0
  230.     ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',   ' ',         #f8
  231.     0
  232.    };
  233.  
  234. ###----------------------------------------------------------------
  235. ##                I S O - 8 8 5 9 - 7     (Greek)
  236. ###----------------------------------------------------------------
  237. ## This set is suited for multiple-language applications involving the
  238. ## Latin and the Greek scripts. It allows handling of data and text
  239. ## expressed in Greek.
  240. ##
  241. ## optimal conversion into CP85x, CP1253
  242.  
  243. structure iso8859_7
  244.     {
  245. ## conversion ISO-7--> 1253
  246.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  247.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  248.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  249.    ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  250. '\160', ',', '`', '£', ' ', ' ', '¶', 'ß',      #a0
  251.     '®', '©', ' ', '´', '¨', '≠', ' ', 'Ø',      #a8
  252.     '∞', '±', '≤', '≥', '¥', '°', '¢', '∑',      #b0
  253.    '∏', 'π', '∫', 'ª', 'º', 'Ω', 'æ', 'ø',      #b8
  254.    '¿', '¡', '¬', '√', 'ƒ', '≈', 'Δ', '«',      #c0
  255.    '»', '…', ' ', 'À', 'Ã', 'Õ', 'Œ', 'œ',      #c8
  256.    '–', '—', ' ', '”', '‘', '’', '÷', '◊',      #d0
  257.    'ÿ', 'Ÿ', '⁄', '€', '‹', '›', 'fi', 'fl',      #d8
  258.    '‡', '·', '‚', '„', '‰', 'Â', 'Ê', 'Á',      #e0
  259.    'Ë', 'È', 'Í', 'Î', 'Ï', 'Ì', 'Ó', 'Ô',      #e8
  260.    '', 'Ò', 'Ú', 'Û', 'Ù', 'ı', 'ˆ', '˜',      #f0
  261.    '¯', '˘', '˙', '˚', '¸', '˝', '˛', ' ',      #f8
  262.     0
  263.    };
  264.  
  265. ###----------------------------------------------------------------
  266. ##                I S O - 8 8 5 9 - 8     (Hebrew)
  267. ###----------------------------------------------------------------
  268. ## This set is suited for multiple-language applications involving the
  269. ## Latin and the Hebrew scripts. It allows handling of data and text
  270. ## expressed in Hebrew.
  271. ##
  272. ## optimal conversion into CP85x, CP1255
  273.  
  274.  
  275. structure iso8859_8
  276.    {
  277. ## conversion ISO-8--> 1255
  278.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  279.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  280.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  281.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  282. '\160', ' ', '¢', '£', '§', '•', '¶', 'ß',      #a0
  283.     '®', '©', 'x', '´', '¨', '≠', 'Æ', '?',      #a8
  284.     '∞', '±', '≤', '≥', '¥', 'µ', '∂', '∑',      #b0
  285.     ',', 'π', '/', 'ª', 'º', 'Ω', 'æ', ' ',      #b8
  286.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #c0
  287.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #c8
  288.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #d0
  289.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', '?',      #d8
  290.     '\224','\225','\226','\227','\228','\229','\230','\231',      #e0
  291.     '\232','\233','\234','\235','\236','\237','\238','\239',      #e8
  292.     '\240','\241','\242','\243','\244','\245','\246','\247',      #f0
  293.     '\248','\249','\250',' ',   ' ',   ' ',   ' ',   ' ',         #f8
  294.     0
  295.     };
  296.  
  297.  
  298. ###----------------------------------------------------------------
  299. ##                I S O - 8 8 5 9 - 9     (Latin 5)
  300. ###----------------------------------------------------------------
  301. ## English, Finnish, French, German, Irish, Italian, Norwegian,
  302. ## Portuguese, Spanish and Swedish and Turkish.
  303. ##
  304. ## optimal conversion into CP85x, CP1254
  305.  
  306.  
  307. structure iso8859_9
  308.     {
  309. # conversion ISO-9 --> 1254
  310.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #80
  311.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #88
  312.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #90
  313.     ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ',      #98
  314. '\160', '°', '¢', '£', '§', '•', '¶', 'ß',      #a0
  315.     '®', '©', '™', '´', '¨', '≠', 'Æ', 'Ø',      #a8
  316.     '∞', '±', '≤', '≥', '¥', 'µ', '∂', '∑',      #b0
  317.     '∏', 'π', '∫', 'ª', 'º', 'Ω', 'æ', 'ø',      #b8
  318.     '¿', '¡', '¬', '√', 'ƒ', '≈', 'Δ', '«',      #c0
  319.     '»', '…', ' ', 'À', 'Ã', 'Õ', 'Œ', 'œ',      #c8
  320.     '–', '—', '“', '”', '‘', '’', '÷', '◊',      #d0
  321.     'ÿ', 'Ÿ', '⁄', '€', '‹', '›', 'fi', 'fl',      #d8
  322.     '‡', '·', '‚', '„', '‰', 'Â', 'Ê', 'Á',      #e0
  323.     'Ë', 'È', 'Í', 'Î', 'Ï', 'Ì', 'Ó', 'Ô',      #e8
  324.     '', 'Ò', 'Ú', 'Û', 'Ù', 'ı', 'ˆ', '˜',      #f0
  325.     '¯', '˘', '˙', '˚', '¸', '˝', '˛', 'ˇ',      #f8
  326.     0
  327.     };
  328.  
  329. ###----------------------------------------------------------------
  330. ##                K O I - 8 R             (Cyrilic)
  331. ###----------------------------------------------------------------
  332. ## Bulgarian, Bielorussian, English, Macedonian, Russian,
  333. ## Serbo-Croatian and Ukrainian.
  334. ##
  335. ## optimal conversion into CP855, CP866, CP1251
  336.  
  337.  
  338. structure koi_8r
  339.    {
  340. # conversion KOI-8R --> 1251
  341.     '-', '|', '+', '+', '+', '+', '|', '|',      #80
  342.     '-', '-', '+', '#', '#', '#', '#', '#',      #88
  343.     '#', '#', '#', '|', '#', '?', '?', '~',      #90
  344.     '?', '?', ' ', '|', '?', '2', '.', '/',      #98
  345.     '-', '|', '+', '∏', '+', '+', '+', '+',      #a0
  346.     '+', '+', '+', '+', '+', '+', '+', '|',      #a8
  347.     '|', '|', '|', '®', '|', '|', '-', '-',      #b0
  348.     '-', '-', '-', '-', '+', '+', '+', '©',      #b8
  349.     '˛', '‡', '·', 'ˆ', '‰', 'Â', 'Ù', '„',      #c0
  350.     'ı', 'Ë', 'È', 'Í', 'Î', 'Ï', 'Ì', 'Ó',      #c8
  351.     'Ô', 'ˇ', '', 'Ò', 'Ú', 'Û', 'Ê', '‚',      #d0
  352.     '¸', '˚', 'Á', '¯', '˝', '˘', '˜', '˙',      #d8
  353.     'fi', '¿', '¡', '÷', 'ƒ', '≈', '‘', '√',      #e0
  354.     '’', '»', '…', ' ', 'À', 'Ã', 'Õ', 'Œ',      #e8
  355.     'œ', 'fl', '–', '—', '“', '”', 'Δ', '¬',      #f0
  356.     '‹', '€', '«', 'ÿ', '›', 'Ÿ', '◊', '⁄',      #f8
  357.    0
  358.     };
  359.  
  360. charset_list _mime_csets
  361.    {
  362.    "ISO-8859-1", iso8859_1,
  363.    "ISO-8859-2", iso8859_2,
  364.    "ISO-8859-3", iso8859_3,
  365.    "ISO-8859-4", iso8859_4,
  366.    "ISO-8859-5", iso8859_5,
  367.    "ISO-8859-6", iso8859_6,
  368.    "ISO-8859-7", iso8859_7,
  369.    "ISO-8859-8", iso8859_8,
  370.    "ISO-8859-9", iso8859_9,
  371.    "KOI-8R",     koi_8r,
  372.    "", -1
  373.    };
  374.  
  375.  
  376.