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.

137 lines
2.8 KiB

  1. // This file is for things that are common across projects
  2. #ifndef __INCLUDE_COMMON
  3. #define __INCLUDE_COMMON
  4. // And of course, DBG
  5. #ifdef DBG
  6. #ifndef DBG
  7. #define DBG 1
  8. #endif //!DBG
  9. #endif //!DBG
  10. #ifdef DBG
  11. #ifndef DBG
  12. #define DBG 1
  13. #endif //!DBG
  14. #endif //!DBG
  15. // Include WINDOWS headers
  16. #include <windows.h>
  17. #include <windowsx.h>
  18. // Include 'pen' stuff
  19. #include "penwin32.h"
  20. // We really don't want these defines to mean anything
  21. #define INLINE
  22. #define EXPORT
  23. #define _loadds
  24. #define _far
  25. #define _pascal
  26. #define PUBLIC
  27. #define PRIVATE
  28. #define BLOCK
  29. // Use const only when ROM_IT is set. Most tables need to be modifiable
  30. // at train/tune time, but should be ROM in the final release.
  31. #ifdef ROM_IT
  32. #define ROMMABLE const
  33. #else
  34. #define ROMMABLE
  35. #endif
  36. // Include the memory management functions
  37. #include "memmgr.h"
  38. // Include the system dependent file management layer
  39. #include "cestubs.h"
  40. #ifndef UNDER_CE
  41. #include <stdio.h>
  42. #include "util.h"
  43. #endif
  44. // Include the common error handling stuff
  45. #include "errsys.h"
  46. #define ALC_NUMERIC_PUNC 0x00001000L // Non digit characters in numbers
  47. #define ALC_BEGINPUNC 0x20000000L // English: [ { ( " etc.
  48. #define ALC_ENDPUNC 0x40000000L // English: ] } ) " etc.
  49. #define ALC_JIS2 0x00040000L // kanji JPN, ShiftJIS 2+3
  50. LPPENDATA WINAPI BeginEnumStrokes(HPENDATA);
  51. LPPENDATA WINAPI EndEnumStrokes(HPENDATA);
  52. BOOL WINAPI GetPenDataStroke(LPPENDATA, UINT, LPPOINT FAR*,
  53. LPVOID FAR*, LPSTROKEINFO);
  54. // include the unicode checking string functions
  55. #include <tchar.h>
  56. // Include the math code
  57. #include "math.h"
  58. #include "mathx.h"
  59. #ifndef abs
  60. #define abs(x) ((x) < 0 ? -(x) : (x))
  61. #endif
  62. // Include the 'Mars' stuff
  63. #include "frame.h"
  64. #include "glyph.h"
  65. // For now, include the XJIS layer. When we switch to UNICODE
  66. // this will be replaced
  67. #include "xjis.h"
  68. #include "unicode.h"
  69. // Fundemental types and structures everybody needs to know about
  70. typedef struct tagCHARSET
  71. {
  72. ALC recmask; // Specifies which character types are to be returned
  73. ALC recmaskPriority; // What types should be at the top of the list.
  74. UINT uDir; // direction of writing.
  75. } CHARSET;
  76. #define MAX_ALT_LIST 20
  77. typedef struct tagALT_LIST
  78. {
  79. UINT cAlt; // Count of valid alternatives
  80. FLOAT aeScore[MAX_ALT_LIST]; // Scores for each alternatives
  81. wchar_t awchList[MAX_ALT_LIST]; // List of alternatives
  82. } ALT_LIST;
  83. extern void SortAltList(ALT_LIST *pAltList);
  84. #define HWX_SUCCESS 0
  85. #define HWX_FAILURE 1
  86. #define HWX_ERROR 2
  87. // Partial recognition modes
  88. #define RECO_MODE_REMAINING 0
  89. #define RECO_MODE_INCREMENTAL 1
  90. // Include support for translations between codepage 1252 and unicode.
  91. #include "cp1252.h"
  92. // Include the XRCRESULT support.
  93. #include "xrcreslt.h"
  94. #include "langtax.h"
  95. #include "foldchar.h"
  96. #endif // !__INCLUDE_COMMON