WinFntID.cs 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148
  1. #region MIT License
  2. /*Copyright (c) 2012 Robert Rouhani <robert.rouhani@gmail.com>
  3. SharpFont based on Tao.FreeType, Copyright (c) 2003-2007 Tao Framework Team
  4. Permission is hereby granted, free of charge, to any person obtaining a copy of
  5. this software and associated documentation files (the "Software"), to deal in
  6. the Software without restriction, including without limitation the rights to
  7. use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
  8. of the Software, and to permit persons to whom the Software is furnished to do
  9. so, subject to the following conditions:
  10. The above copyright notice and this permission notice shall be included in all
  11. copies or substantial portions of the Software.
  12. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  13. IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  14. FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  15. AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  16. LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  17. OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  18. SOFTWARE.*/
  19. #endregion
  20. using System;
  21. namespace SharpFont.Fnt
  22. {
  23. /// <summary>
  24. /// A list of valid values for the ‘charset’ byte in <see cref="Header"/>. Exact mapping tables for the various
  25. /// cpXXXX encodings (except for cp1361) can be found at <see href="ftp://ftp.unicode.org" /> in the
  26. /// MAPPINGS/VENDORS/MICSFT/WINDOWS subdirectory. cp1361 is roughly a superset of
  27. /// MAPPINGS/OBSOLETE/EASTASIA/KSC/JOHAB.TXT.
  28. /// </summary>
  29. public enum WinFntId : byte
  30. {
  31. /// <summary>
  32. /// ANSI encoding. A superset of ISO 8859-1.
  33. /// </summary>
  34. CP1252 = 0,
  35. /// <summary>
  36. /// This is used for font enumeration and font creation as a ‘don't care’ value. Valid font files don't contain
  37. /// this value. When querying for information about the character set of the font that is currently selected
  38. /// into a specified device context, this return value (of the related Windows API) simply denotes failure.
  39. /// </summary>
  40. Default = 1,
  41. /// <summary>
  42. /// There is no known mapping table available.
  43. /// </summary>
  44. Symbol = 2,
  45. /// <summary>
  46. /// Mac Roman encoding.
  47. /// </summary>
  48. Mac = 77,
  49. /// <summary>
  50. /// A superset of Japanese Shift-JIS (with minor deviations).
  51. /// </summary>
  52. CP932 = 128,
  53. /// <summary>
  54. /// A superset of Korean Hangul KS C 5601-1987 (with different ordering and minor deviations).
  55. /// </summary>
  56. CP949 = 129,
  57. /// <summary>
  58. /// Korean (Johab).
  59. /// </summary>
  60. CP1361 = 130,
  61. /// <summary>
  62. /// A superset of simplified Chinese GB 2312-1980 (with different ordering and minor deviations).
  63. /// </summary>
  64. CP936 = 134,
  65. /// <summary>
  66. /// A superset of traditional Chinese Big 5 ETen (with different ordering and minor deviations).
  67. /// </summary>
  68. CP950 = 136,
  69. /// <summary>
  70. /// A superset of Greek ISO 8859-7 (with minor modifications).
  71. /// </summary>
  72. CP1253 = 161,
  73. /// <summary>
  74. /// A superset of Turkish ISO 8859-9.
  75. /// </summary>
  76. CP1254 = 162,
  77. /// <summary>
  78. /// For Vietnamese. This encoding doesn't cover all necessary characters.
  79. /// </summary>
  80. CP1258 = 163,
  81. /// <summary>
  82. /// A superset of Hebrew ISO 8859-8 (with some modifications).
  83. /// </summary>
  84. CP1255 = 177,
  85. /// <summary>
  86. /// A superset of Arabic ISO 8859-6 (with different ordering).
  87. /// </summary>
  88. CP1256 = 178,
  89. /// <summary>
  90. /// A superset of Baltic ISO 8859-13 (with some deviations).
  91. /// </summary>
  92. CP1257 = 186,
  93. /// <summary>
  94. /// A superset of Russian ISO 8859-5 (with different ordering).
  95. /// </summary>
  96. CP1251 = 204,
  97. /// <summary>
  98. /// A superset of Thai TIS 620 and ISO 8859-11.
  99. /// </summary>
  100. CP874 = 222,
  101. /// <summary>
  102. /// A superset of East European ISO 8859-2 (with slightly different ordering).
  103. /// </summary>
  104. CP1250 = 238,
  105. /// <summary><para>
  106. /// From Michael Pöttgen &lt;michael@poettgen.de&gt;:
  107. /// The ‘Windows Font Mapping’ article says that <see cref="WinFntId.Oem"/> is used for the charset of vector
  108. /// fonts, like ‘modern.fon’, ‘roman.fon’, and ‘script.fon’ on Windows.
  109. /// </para><para>
  110. /// The ‘CreateFont’ documentation says: The <see cref="WinFntId.Oem"/> value specifies a character set that is
  111. /// operating-system dependent.
  112. /// </para><para>
  113. /// The ‘IFIMETRICS’ documentation from the ‘Windows Driver Development Kit’ says: This font supports an
  114. /// OEM-specific character set. The OEM character set is system dependent.
  115. /// </para><para>
  116. /// In general OEM, as opposed to ANSI (i.e., cp1252), denotes the second default codepage that most
  117. /// international versions of Windows have. It is one of the OEM codepages from
  118. /// <see href="http://www.microsoft.com/globaldev/reference/cphome.mspx"/>, and is used for the ‘DOS boxes’, to
  119. /// support legacy applications. A German Windows version for example usually uses ANSI codepage 1252 and OEM
  120. /// codepage 850.
  121. /// </para></summary>
  122. Oem = 255
  123. }
  124. }