2 GEOS dialog box functions
4 by Maciej 'YTM/Elysium' Witkowiak
10 char __fastcall__ DoDlgBox(const char *dboxstring);
11 char RstrFrmDialogue(void);
13 /* These are custom, predefined dialog boxes, I'm sure you'll find them usable
14 Most of them show 2 lines of text */
16 char __fastcall__ DlgBoxYesNo(const char *line1, const char *line2);
17 char __fastcall__ DlgBoxOkCancel(const char *line1, const char *line2);
18 void __fastcall__ DlgBoxOk(const char *line1, const char *line2);
19 char __fastcall__ DlgBoxGetString(char *myString, char strLength,
20 const char *line1, const char *line2);
21 char __fastcall__ DlgBoxFileSelect(const char *classtxt, char ftype,
24 /* This is a more general dialog box, works like printf in a window */
25 char MessageBox(char mode, const char *format, ...);
27 /* mode argument for MessageBox() */
35 /* Now the command string type */
37 typedef void dlgBoxStr;
39 /* and command string commands - macros */
41 #define DB_DEFPOS(pattern) (char)(DEF_DB_POS | (pattern))
42 #define DB_SETPOS(pattern,top,bot,left,right) \
43 (char)(SET_DB_POS | (pattern)), (char)(top), (char)(bot), \
44 (unsigned)(left), (unsigned)(right)
45 #define DB_ICON(i,x,y) (char)(i), (char)(x), (char)(y)
46 #define DB_TXTSTR(x,y,text) (char)DBTXTSTR, (char)(x), (char)(y), (text)
47 #define DB_VARSTR(x,y,ptr) (char)DBVARSTR, (char)(x), (char)(y), (char)(ptr)
48 #define DB_GETSTR(x,y,ptr,length) (char)DBGETSTRING, (char)(x), (char)(y), (char)(ptr), (char)(length)
49 #define DB_SYSOPV(ptr) (char)DBSYSOPV, (unsigned)(ptr)
50 #define DB_GRPHSTR(ptr) (char)DBGRPHSTR, (unsigned)(ptr)
51 #define DB_GETFILES(x,y) (char)DBGETFILES, (char)(x), (char)(y)
52 #define DB_OPVEC(ptr) (char)DBOPVEC, (unsigned)(ptr)
53 #define DB_USRICON(x,y,ptr) (char)DBUSRICON, (char)(x), (char)(y), (unsigned)(ptr)
54 #define DB_USRROUT(ptr) (char)DB_USR_ROUT, (unsigned)(ptr)
55 #define DB_END (char)NULL
58 part of constants below is used internally, but some are useful for macros above
61 /* icons for DB_ICON */
68 /* commands - internally used by command macros */
71 #define DBGETSTRING 13
77 #define DB_USR_ROUT 19
78 /* icons tabulation in standard window */
85 /* standard window size defaults */
87 #define DEF_DB_POS 0x80
89 #define DEF_DB_BOT 127
90 #define DEF_DB_LEFT 64
91 #define DEF_DB_RIGHT 255
92 /* text tabulation in standard window */
99 /* system icons size */
100 #define SYSDBI_HEIGHT 16
101 #define SYSDBI_WIDTH 6
102 /* dialogbox string offsets */
103 #define OFF_DB_FORM 0
106 #define OFF_DB_LEFT 3
107 #define OFF_DB_RIGHT 5
108 #define OFF_DB_1STCMD 7