Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1.2 KiB

  1. /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  2. Copyright (c) 1995-1999 Microsoft Corporation
  3. Module Name:
  4. mbcs.cxx
  5. Abstract:
  6. MBCS support related code used by the lexer.
  7. Notes:
  8. History:
  9. RyszardK Sep-1996 Created.
  10. ----------------------------------------------------------------------------*/
  11. class CharacterSet
  12. {
  13. private:
  14. unsigned char DbcsLeadByteTable[256];
  15. unsigned long CurrentLCID;
  16. public:
  17. typedef enum
  18. {
  19. dbcs_Failure = 0,
  20. dbcs_Success,
  21. dbcs_LCIDConflict,
  22. dbcs_BadLCID,
  23. } DBCS_ERRORS;
  24. CharacterSet();
  25. DBCS_ERRORS
  26. SetDbcsLeadByteTable( unsigned long ulLocale );
  27. inline
  28. unsigned short
  29. IsMbcsLeadByte(
  30. unsigned char ch )
  31. {
  32. return DbcsLeadByteTable[ ch ];
  33. }
  34. int
  35. CompareDBCSString
  36. (
  37. char* szLHStr,
  38. char* szRHStr,
  39. unsigned long ulFlags = 0
  40. );
  41. int
  42. DBCSDefaultToCaseSensitive();
  43. };
  44. extern CharacterSet CurrentCharSet;