home *** CD-ROM | disk | FTP | other *** search
/ Network Support Encyclopedia 96-1 / novell-nsepro-1996-1-cd2.iso / download / gw / oddev.exe / MULTIPAD.H < prev    next >
C/C++ Source or Header  |  1994-08-09  |  5KB  |  188 lines

  1. #include <stdarg.h>
  2. #include "windows.h"
  3. #include "drivinit.h"
  4. #include "odma.h"
  5.  
  6. #ifndef CDECL
  7. #define CDECL cdecl
  8. #endif
  9.  
  10. #define WINDOWMENU  3    /* position of window menu         */
  11. #define SHORTMENU   2    /* position of short version window menu */
  12.  
  13. #define DEFFILESEARCH    (LPSTR) "*.TXT"
  14.  
  15. #ifdef RC_INVOKED
  16. #define ID(id) id
  17. #else
  18. #define ID(id) MAKEINTRESOURCE(id)
  19. #endif
  20.  
  21. /* edit control identifier */
  22. #define ID_EDIT 0xCAC
  23.  
  24. /* resource ID's */
  25. #define IDMULTIPAD  ID(1)
  26. #define IDMULTIPAD2 ID(3)
  27. #define IDNOTE        ID(2)
  28.  
  29. /* Window word values for child windows */
  30. #define GWW_HWNDEDIT     0
  31. #define GWW_CHANGED         2
  32. #define GWW_WORDWRAP     4
  33. #define GWW_UNTITLED     6
  34. #define GWW_FILEPTR         8
  35. #define GWW_ODMADOCID    10
  36. #define GWW_ODMA_SAVE    12
  37. #define GWW_READ_ONLY    14
  38. #define CBWNDEXTRA        18
  39.  
  40. /* menu ID's */
  41. #define IDM_FILENEW    1001
  42. #define IDM_FILEOPEN    1002
  43. #define IDM_FILESAVE    1003
  44. #define IDM_FILESAVEAS    1004
  45. #define IDM_FILEPRINT    1005
  46. #define IDM_FILEEXIT    1006
  47. #define IDM_FILEABOUT    1007
  48. #define IDM_FILESETUP    1008
  49. #define IDM_FILEMENU    1009
  50. #define IDM_GOTOPROFILE    1010
  51. #define IDM_FILECLOSE    1011
  52.  
  53. #define IDM_EDITUNDO    2001
  54. #define IDM_EDITCUT    2002
  55. #define IDM_EDITCOPY    2003
  56. #define IDM_EDITPASTE    2004
  57. #define IDM_EDITCLEAR    2005
  58. #define IDM_EDITSELECT    2006
  59. #define IDM_EDITTIME    2007
  60. #define IDM_EDITWRAP    2008
  61. #define IDM_EDITFONT    2009
  62. #define IDM_EDITFIRST    IDM_EDITUNDO
  63. #define IDM_EDITLAST    IDM_EDITFONT
  64.  
  65. #define IDM_SEARCHFIND    3001
  66. #define IDM_SEARCHNEXT    3002
  67. #define IDM_SEARCHPREV    3003
  68. #define IDM_SEARCHFIRST IDM_SEARCHFIND
  69. #define IDM_SEARCHLAST    IDM_SEARCHPREV
  70.  
  71. #define IDM_WINDOWTILE    4001
  72. #define IDM_WINDOWCASCADE 4002
  73. #define IDM_WINDOWCLOSEALL  4003
  74. #define IDM_WINDOWICONS 4004
  75.  
  76. #define IDM_WINDOWCHILD 4100
  77.  
  78. #define IDM_HELPHELP    5001
  79. #define IDM_HELPABOUT    5002
  80. #define IDM_HELPSPOT    5003
  81.  
  82. #define IDD_FILEOPEN    ID(200)
  83. #define IDD_FILENAME    201
  84. #define IDD_FILES    202
  85. #define IDD_PATH    203
  86. #define IDD_DIRS    204
  87.  
  88. /* dialog ids */
  89. #define IDD_ABOUT    ID(300)
  90.  
  91. #define IDD_FIND    ID(400)
  92. #define IDD_SEARCH    401
  93. #define IDD_PREV    402
  94. #define IDD_NEXT    IDOK
  95. #define IDD_CASE    403
  96.  
  97. #define IDD_SAVEAS    ID(500)
  98. #define IDD_SAVEFROM    501
  99. #define IDD_SAVETO    502
  100.  
  101. #define IDD_PRINT    ID(600)
  102. #define IDD_PRINTDEVICE 601
  103. #define IDD_PRINTPORT    602
  104. #define IDD_PRINTTITLE    603
  105.  
  106. #define IDD_FONT    ID(700)
  107. #define IDD_FACES    701
  108. #define IDD_SIZES    702
  109. #define IDD_BOLD    703
  110. #define IDD_ITALIC    704
  111. #define IDD_FONTTITLE    705
  112.  
  113. /* strings */
  114. #define IDS_CANTOPEN    1
  115. #define IDS_CANTREAD    2
  116. #define IDS_CANTCREATE    3
  117. #define IDS_CANTWRITE    4
  118. #define IDS_ILLFNM    5
  119. #define IDS_ADDEXT    6
  120. #define IDS_CLOSESAVE    7
  121. #define IDS_CANTFIND    8
  122. #define IDS_HELPNOTAVAIL 9
  123. #define IDS_NOMEM        10
  124. #define IDS_NOTNAMED    11
  125. #define IDS_READONLY    12
  126.  
  127. #define IDS_CLIENTTITLE 16
  128. #define IDS_UNTITLED    17
  129. #define IDS_APPNAME    18
  130. #define IDS_RDONLY_TITLE 19
  131.  
  132. #define IDS_PRINTJOB    24
  133. #define IDS_PRINTERROR    25
  134. #define IDS_SAVE_RDONLY    26
  135.  
  136. /* attribute flags for DlgDirList */
  137. #define ATTR_DIRS    0xC010        /* find drives and directories */
  138. #define ATTR_FILES    0x0000        /* find ordinary files           */
  139. #define PROP_FILENAME    szPropertyName    /* name of property for dialog */
  140.  
  141. /*
  142.  *  External variable declarations
  143.  */
  144. extern HANDLE hInst;        /* application instance handle          */
  145. extern HANDLE hAccel;        /* resource handle of accelerators      */
  146. extern HWND hwndFrame;        /* main window handle              */
  147. extern HWND hwndMDIClient;    /* handle of MDI Client window          */
  148. extern HWND hwndActive;     /* handle of current active MDI child      */
  149. extern HWND hwndActiveEdit;    /* handle of edit control in active child */
  150. extern LONG styleDefault;    /* default child creation state       */
  151. extern char szChild[];        /* class of child              */
  152. extern char szSearch[];     /* search string              */
  153. extern char *szDriver;        /* name of printer driver          */
  154. extern char szPropertyName[];    /* filename property for dialog box      */
  155. extern int iPrinter;        /* level of printing capability       */
  156. extern BOOL fCase;        /* searches case sensitive          */
  157. extern WORD cFonts;        /* number of fonts enumerated          */
  158. extern ODMHANDLE odmHandle;    /* ODMA handle */
  159.  
  160. /*  externally declared functions
  161.  */
  162. extern BOOL FAR PASCAL InitializeApplication(VOID);
  163. extern BOOL FAR PASCAL InitializeInstance(LPSTR,WORD);
  164. extern BOOL FAR PASCAL AboutDlgProc(HWND,WORD,WORD,LONG);
  165. extern VOID FAR PASCAL ParseCmdLine(char *);
  166. extern HWND FAR PASCAL AddFile(char *);
  167. extern VOID FAR PASCAL SelectFile(HWND);
  168. extern VOID FAR PASCAL SaveFile(HWND);
  169. extern BOOL FAR PASCAL ChangeFile(HWND);
  170. extern int FAR PASCAL LoadFile(HWND, char *);
  171. extern VOID FAR PASCAL PrintFile(HWND);
  172. extern BOOL FAR PASCAL GetInitializationData(HWND);
  173. extern short FAR CDECL MPError(HWND,WORD,WORD,LPSTR);
  174. extern VOID FAR PASCAL Find(void);
  175. extern VOID FAR PASCAL FindNext(void);
  176. extern VOID FAR PASCAL FindPrev(void);
  177. extern VOID FAR PASCAL MPSpotHelp(HWND,POINT);
  178. extern LONG FAR PASCAL MPFrameWndProc(HWND,UINT,WPARAM,LPARAM);
  179. extern LONG FAR PASCAL MPMDIChildWndProc(HWND,UINT,WPARAM,LPARAM);
  180. extern HDC FAR PASCAL GetPrinterDC(void);
  181. extern VOID NEAR PASCAL SetSaveFrom (HWND, PSTR);
  182. extern BOOL NEAR PASCAL RealSlowCompare (PSTR, PSTR);
  183. extern VOID FAR PASCAL FindPrev (void);
  184. extern VOID FAR PASCAL FindNext (void);
  185. extern BOOL NEAR PASCAL IsWild (PSTR);
  186. extern VOID NEAR PASCAL SelectFile (HWND);
  187. extern VOID NEAR PASCAL MyFindText ( int );
  188.