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.

123 lines
3.4 KiB

  1. /*************************************************
  2. * abcdsp.h *
  3. * *
  4. * Copyright (C) 1995-1999 Microsoft Inc. *
  5. * *
  6. *************************************************/
  7. #define IDM_ABOUT 100
  8. #define IDM_HOTKEY 999
  9. /* #define MyIcon 888 */
  10. #define WM_FONTLOAD WM_USER+0x100
  11. int PASCAL WinMain(HANDLE, HANDLE, LPSTR, int);
  12. BOOL InitApplication(HANDLE);
  13. BOOL FAR PASCAL About(HWND, unsigned, WORD, LONG);
  14. int FAR PASCAL EnumFunc(LPLOGFONT, LPTEXTMETRIC, short, LPSTR);
  15. int FAR PASCAL EditAdjust(HWND,HFONT);
  16. LONG FAR PASCAL CEditWndProc(HWND,unsigned,WORD,LONG);
  17. PASCAL RedrawScr(int,HWND);
  18. int PASCAL EditPrevChar(int);
  19. #define WM_IMCHANGE WM_USER+0x200
  20. #define WM_CODE WM_USER+0x201
  21. #define WM_IMRESET WM_USER+0x202
  22. #define WM_BACKSPACE WM_USER+0x203
  23. #define WM_CCREPEAT WM_USER+0x204
  24. #define DLL_PROLOG 3
  25. #define DBCS_MIN 0xa1
  26. #define SIGN_MASK 0x8000
  27. #define szGDI "GDI"
  28. #define szKBD "KEYBOARD"
  29. #define szThisModule "ABCDSP" /* It must be the name listed in .def file
  30. LIBRARY statement. */
  31. #define MAXFONTSIZE 128
  32. #define BITFONT 1
  33. #define NOTRUETYPE 4
  34. #define JMP_FAR (BYTE)0xea /* Machine code of far jmp */
  35. typedef LONG (FAR PASCAL *LFARPROC) ();
  36. typedef DWORD (WINAPI *DFARPROC)();
  37. typedef struct tagProCode
  38. {
  39. BYTE OneByte;
  40. DWORD FourByte;
  41. } PROCODE, FAR* LPPROCODE;
  42. typedef struct tagCodeInfo
  43. {
  44. HANDLE hCode;
  45. LPPROCODE CodeAddr;
  46. PROCODE OldCode;
  47. PROCODE NewCode;
  48. } CODEINFO, FAR* LPCODEINFO;
  49. typedef struct tagDBCFontInfo
  50. {
  51. TEXTMETRIC tm;
  52. int fBold;
  53. int fItalicOffset; /* Use in doing Italic style */
  54. double fta;
  55. } DBCFONTINFO, FAR* LPDBCFONTINFO;
  56. typedef struct tagDispDBCInfo
  57. {
  58. HDC hDC;
  59. HDC hMemDC;
  60. int x;
  61. int y;
  62. WORD DBCode;
  63. int FrameWidth;
  64. int FrameHeight;
  65. int FontSize;
  66. } DISPDBCINFO, FAR* LPDISPDBCINFO;
  67. /* Functions called by CWIN.EXE */
  68. BOOL WINAPI InitChdisp(HWND);
  69. BOOL WINAPI QuitChdisp();
  70. void WINAPI CwinNotify(BOOL, UINT);
  71. /* Substitution functions */
  72. BOOL WINAPI NewExtTextOut(HDC, int, int, UINT, LPRECT, LPSTR, UINT, LPINT);
  73. DWORD WINAPI NewGetTextExtent(HDC, LPSTR, int);
  74. BOOL WINAPI NewGetCharWidth(HDC, UINT, UINT, LPINT);
  75. void WINAPI NewXlat(char _huge*, char _huge*);
  76. void WINAPI NewXlatBuff(LPSTR, LPSTR, UINT);
  77. /* Now, character set is not changed. ZHX 1-6-1993
  78. HFONT WINAPI B7(int,int,int,int,int,BYTE,BYTE,BYTE,
  79. BYTE,BYTE,BYTE,BYTE,BYTE,LPSTR);
  80. HFONT WINAPI B8(LPLOGFONT);
  81. */
  82. void ChangeCode(HANDLE, HANDLE, LPCODEINFO, char*, char*);
  83. void ChangeProcCode(FARPROC,LPBYTE,FARPROC);
  84. //int ChangeProcCode2(FARPROC,LPBYTE,FARPROC);
  85. BOOL OldExtTextOut(HDC, int, int, WORD, LPRECT, LPSTR, WORD, LPINT);
  86. BOOL OldGetCharWidth(HDC, WORD, WORD, LPINT);
  87. DWORD OldGetTextExtent(HDC, LPSTR, WORD);
  88. void BitBltChineseChar(void);
  89. int DoFontStyle(int, int, LPDBCFONTINFO);
  90. void GetFontStyle(HDC, LPDBCFONTINFO);
  91. BOOL RestoreProcCode(FARPROC, LPBYTE);
  92. //int JudgeFont(HDC);
  93. //int IsPrintDC(HDC);
  94. void GetChnFace(HDC);
  95. WORD WINAPI AllocCSToDSAlias(WORD);
  96. //short WINAPI GET_HZ(short,short,short,short,short,LPSTR);
  97. short WINAPI GET_HZ(short,short,short,short,short,char _huge*);