home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 11 Util / 11-Util.zip / asci20b1.zip / ascii.h < prev    next >
Text File  |  1999-05-21  |  4KB  |  118 lines

  1. // ASCII Table 1.0
  2. // Copyright 1998 by D.J. van Enckevort
  3. // This program and sourcecode is released as freeware
  4. // You can use this code for your own programs
  5. // If you use it, please keep a notice of this copyright
  6.  
  7. // Resource IDs
  8. // Resource IDs for the main window
  9. #define DLG_ASCII                   100
  10. #define SET_ASCII                   101
  11. #define MLE_TEXT                    102
  12. #define ST_FONT                     106
  13. // Resource IDs for the About messagebox
  14. #define DLG_ABOUT                   200
  15. #define ST_TITLE                    201
  16. #define ST_COPYRIGHT                202
  17. #define ST_AUTHOR                   203
  18. #define ST_EMAIL                    204
  19. #define PB_OK                       205
  20. // Settings dialog
  21. #define DLG_SETTINGS                300
  22. #define SB_START                    301
  23. #define SB_END                      302
  24. #define ST_START                    303
  25. #define ST_END                      304
  26. #define GB_RANGE                    305
  27. #define PB_OK                       306
  28. #define PB_CANCEL                   307
  29. // Menu items
  30. #define ID_MENU                     400
  31. #define MN_FILE                     410
  32. #define MI_OPEN                     411
  33. #define MI_SAVE                     412
  34. #define MI_SAVEAS                   413
  35. #define MI_SETTINGS                 414
  36. #define MI_CLOSE                    415
  37. #define MN_EDIT                     420
  38. #define MI_CUT                      421
  39. #define MI_COPY                     422
  40. #define MI_PASTE                    423
  41. #define MI_CLEAR                    424
  42. #define MI_FONT                     425
  43. #define MI_CODEPAGE                 426
  44. #define MI_MLE                      427
  45. #define MI_DIRECTTYPE               428
  46. #define MN_HELP                     430
  47. #define MI_PRODUCTINFO              431
  48. // AccelTable
  49. #define ID_ACCELTABLE               500
  50. // Icon
  51. #define ID_ICON                     600
  52. // HelpTable & HelpSubTable
  53. #define ID_HELPTABLE                700
  54. #define SUBTABLE_ASCII              710
  55. #define SUBTABLE_ABOUT              720
  56. // Direct Type Dialog
  57. #define DLG_DIRECTTYPE              800
  58. #define LB_PROGRAMS                 801
  59. #define PB_DIRECTTYPE_OK            802
  60. #define PB_DIRECTTYPE_CANCEL        803
  61. #define PB_DIRECTTYPE_HELP          804
  62. #define ST_DIRECTTYPE               805
  63. // Help resources
  64. #define HLP_MAIN                   1000
  65. #define HLP_ABOUT                  3000
  66. #define HLP_ASCII                  1100
  67. #define HLP_TEXT                   1200
  68. #define HLP_FILE                   1300
  69. #define HLP_OPEN                   1310
  70. #define HLP_SAVE                   1320
  71. #define HLP_SAVEAS                 1330
  72. #define HLP_CLOSE                  1340
  73. #define HLP_EDIT                   1400
  74. #define HLP_COPY                   1410
  75. #define HLP_CUT                    1420
  76. #define HLP_PASTE                  1430
  77. #define HLP_CLEAR                  1440
  78. #define HLP_FONT                   1450
  79. #define HLP_CODEPAGE               1460
  80. #define HLP_HELP                   1500
  81. #define HLP_USINGHELP              1510
  82. #define HLP_GENERALHELP            1520
  83. #define HLP_HELPINDEX              1530
  84. #define HLP_PRODUCTINFO            1540
  85. #define HLP_OK                     3100
  86.  
  87. // User Messages
  88. #define UM_RESIZE WM_USER+100
  89. #define UM_SETMENUSTATE WM_USER+101
  90. #define UM_ADDCPMENU WM_USER+102
  91. #define UM_DIRECTTYPE WM_USER+103
  92.  
  93. // Constant variables
  94. #define MAX_BUFFER 8192
  95. #define TEMP_BUFFER 11
  96. #define CHAR_BUFFER 2
  97. #define MAX_ROW 8
  98. #define MAX_COLUMN 32
  99. #define DEFAULT_CODEPAGE 850
  100. #define DEFAULT_POINTSIZE 10
  101. #define MAX_CP 100
  102.  
  103. // Declaration of global variables
  104. extern HAB hab; // Handle to anchor block
  105. extern HWND hwndMain;
  106.  
  107. // Declaration of global functions
  108. void main(int argc, char *argv[]);
  109. // Message Hook
  110. extern BOOL EXPENTRY MessageHook(HAB hab, PQMSG pqmsg, ULONG fs);
  111. // Window procedure for the main window
  112. extern MRESULT EXPENTRY WinProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
  113. // Window procedure for the About messagebox
  114. extern MRESULT EXPENTRY AboutProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
  115. // Window procedure for the DirectType dialog
  116. extern MRESULT EXPENTRY DirectTypeProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
  117.  
  118.