unicodeducet.pas 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. { Unicode DUCET unit.
  2. Copyright (c) 2013 by Inoussa OUEDRAOGO
  3. The source code is distributed under the Library GNU
  4. General Public License with the following modification:
  5. - object files and libraries linked into an application may be
  6. distributed without source code.
  7. If you didn't receive a copy of the file COPYING, contact:
  8. Free Software Foundation
  9. 675 Mass Ave
  10. Cambridge, MA 02139
  11. USA
  12. This program is distributed in the hope that it will be useful,
  13. but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  15. }
  16. {$IFNDEF FPC_DOTTEDUNITS}
  17. unit unicodeducet;
  18. {$ENDIF FPC_DOTTEDUNITS}
  19. {$IFDEF FPC}
  20. {$mode delphi}
  21. {$H+}
  22. {$PACKENUM 1}
  23. {$ENDIF FPC}
  24. {$IFNDEF FPC}
  25. {$DEFINE ENDIAN_LITTLE}
  26. {$ENDIF !FPC}
  27. {$SCOPEDENUMS ON}
  28. interface
  29. implementation
  30. {$IFDEF FPC_DOTTEDUNITS}
  31. uses
  32. System.CodePages.unicodedata;
  33. {$ELSE FPC_DOTTEDUNITS}
  34. uses
  35. unicodedata;
  36. {$ENDIF FPC_DOTTEDUNITS}
  37. {$INCLUDE ucadata.inc}
  38. {$IFDEF ENDIAN_LITTLE}
  39. {$INCLUDE ucadata_le.inc}
  40. {$ENDIF ENDIAN_LITTLE}
  41. {$IFDEF ENDIAN_BIG}
  42. {$INCLUDE ucadata_be.inc}
  43. {$ENDIF ENDIAN_BIG}
  44. const
  45. UCA_DataBookRecord : TUCA_DataBook = (
  46. Base : nil;
  47. Version :
  48. ( Ord('9'),Ord('.'),Ord('0'),Ord('.'),Ord('0'),0,0,0,
  49. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,
  50. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,
  51. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,
  52. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0
  53. );
  54. CollationName :
  55. (
  56. Ord('D'),Ord('U'),Ord('C'),Ord('E'),Ord('T'),0,0,0,
  57. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,
  58. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,
  59. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,
  60. 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0, 0,0,0,0,0,0,0,0,0,0
  61. );//'Default Unicode Collation Element Table (DUCET)'
  62. VariableWeight : TUCA_VariableKind(VARIABLE_WEIGHT);
  63. Backwards : (BACKWARDS_0,BACKWARDS_1,BACKWARDS_2,BACKWARDS_3);
  64. BMP_Table1 : @UCA_TABLE_1[0];
  65. BMP_Table2 : @UCA_TABLE_2[0];
  66. OBMP_Table1 : @UCAO_TABLE_1[0];
  67. OBMP_Table2 : @UCAO_TABLE_2[0];
  68. PropCount : PROP_COUNT;
  69. Props : @UCA_PROPS[0];
  70. VariableLowLimit : VARIABLE_LOW_LIMIT;
  71. VariableHighLimit : VARIABLE_HIGH_LIMIT;
  72. NoNormalization : False;
  73. ComparisonStrength : DEFAULT_UCA_COMPARISON_STRENGTH;
  74. Dynamic : False;
  75. );
  76. initialization
  77. RegisterCollation(@UCA_DataBookRecord,['ROOT']);
  78. end.