Annotation of libwww/Library/src/HTAlert.html, revision 2.8
2.6 timbl 1: <HTML>
2: <HEAD>
3: <TITLE>/Net/dxcern/userd/timbl/hypertext/WWW/Library/Implementation/HTAlert.html</TITLE>
4: <NEXTID N="z3">
5: </HEAD>
6: <BODY>
7: <H1>Displaying messages and getting input
8: for <A
9: NAME="z0" HREF="Overview.html">WWW Library</A></H1>This module may be overridden for
10: GUI clients. It allows progress
11: indications and warning messages
12: to be communicated to the user in
13: a portable way. It should be used
14: for this purpose throughout the library
15: but isn't yet (July 93)
16: <UL>
17: <LI>May 92 Created By C.T. Barker
18: <LI>Feb 93 Portablized etc TBL
19: </UL>
20: <PRE>#include <A
21: NAME="z1" HREF="HTUtils.html">"HTUtils.h"</A>
22: #include <A
23: NAME="z2" HREF="tcp.html">"tcp.h"</A>
24:
2.8 ! luotonen 25: #ifdef SHORT_NAMES
! 26: #define HTPrPass HTPromptPassword
! 27: #define HTPUnAPw HTPromptUsernameAndPassword
! 28: #endif /*SHORT_NAMES*/
! 29:
2.6 timbl 30: </PRE>
2.7 luotonen 31: <H2>HTPrompt and HTPromptPassword: Display a message and get
2.6 timbl 32: the input</H2>
2.7 luotonen 33: HTPromptPassword() doesn't echo reply on the screen.
2.6 timbl 34: <H3>On entry,</H3>
35: <DL>
36: <DT>Msg
37: <DD> String to be displayed.
2.7 luotonen 38: <DT>deflt
39: <DD> If NULL the default value (only for HTPrompt())
2.6 timbl 40: </DL>
41:
42: <H3>On exit,</H3>
43: <DL>
44: <DT>Return value
45: <DD> is malloc'd string which
46: must be freed.
47: </DL>
48:
49: <PRE>
1.1 timbl 50: extern char * HTPrompt PARAMS((CONST char * Msg, CONST char * deflt));
2.7 luotonen 51: extern char * HTPromptPassword PARAMS((CONST char * Msg));
1.1 timbl 52:
2.8 ! luotonen 53: </PRE>
! 54: <H2>HTPromptUsernameAndPassword: Get both username and password</H2>
! 55: <H3>On entry,</H3>
! 56: <DL>
! 57: <DT>Msg<DD>String to be displayed.
! 58: <DT>username<DD> Pointer to char pointer, i.e. <CODE>*username</CODE>
! 59: points to a string. If non-NULL it is taken to be a default value.
! 60: <DT>password<DD> Pointer to char pointer, i.e. <CODE>*password</CODE>
! 61: points to a string. Initial value discarded.
! 62: </DL>
! 63: <H3>On exit,</H3>
! 64: <DL>
! 65: <DT>*username<DD> and
! 66: <DT>*password<DD> point to newly allocated strings representing
! 67: the typed-in username and password. Initial strings pointed to
! 68: by them are NOT freed!
! 69: </DL>
! 70: <PRE>
! 71: extern void HTPromptUsernameAndPassword PARAMS((CONST char * Msg,
! 72: char ** username,
! 73: char ** password));
1.1 timbl 74:
2.6 timbl 75: </PRE>
76: <H2>Display a message, don't wait for
77: input</H2>
78: <H3>On entry,</H3>
79: <DL>
80: <DT>Msg
81: <DD> String to be displayed.
82: </DL>
83:
84: <PRE>
1.1 timbl 85: extern void HTAlert PARAMS((CONST char * Msg));
86:
87:
2.6 timbl 88: </PRE>
89: <H2>Display a progress message for information
90: (and diagnostics) only</H2>
91: <H3>On entry,</H3>The input is a list of parameters
92: for printf.
93: <PRE>extern void HTProgress PARAMS((CONST char * Msg));
94:
95:
96: </PRE>
97: <H2>Display a message, then wait for
98: 'yes' or 'no'.</H2>
99: <H3>On entry,</H3>
100: <DL>
101: <DT>Msg
102: <DD> String to be displayed
103: </DL>
104:
105: <H3>On exit,</H3>
106: <DL>
107: <DT>Returns
108: <DD> If the user reacts in the
109: affirmative, returns TRUE, returns
110: FALSE otherwise.
111: </DL>
112:
113: <PRE>
1.1 timbl 114: extern BOOL HTConfirm PARAMS ((CONST char * Msg));
2.6 timbl 115:
116:
117:
118:
119: </PRE></BODY>
120: </HTML>
Webmaster