Annotation of libwww/Library/src/HTMLPDTD.html, revision 2.7.2.1
2.7 frystyk 1: <HTML>
2: <HEAD>
3: <TITLE>The HTML PLUS DTD -- software interface in libwww</TITLE>
4: </HEAD>
5: <BODY>
6:
7: <H1>HTML Plus DTD - Software Interface</H1>
8:
9: <PRE>
10: /*
11: ** (c) COPYRIGHT CERN 1994.
12: ** Please first read the full copyright statement in the file COPYRIGH.
13: */
14: </PRE>
15:
16: SGML purists should excuse the use of the term "DTD" in this file to
17: represent DTD-related information which is not exactly a DTD
18: itself. The C modular structure doesn't work very well here, as the
19: dtd is partly in the .h and partly in the .c which are not very
20: independent. <EM>Tant pis!</EM> There are a couple of HTML-specific
21: utility routines also defined. <P>
22:
23: This module is a part of the <A
24: HREF="http://info.cern.ch/hypertext/WWW/Library/User/Guide/Guide.html">
25: Library of Common Code</A>.
26:
2.6 timbl 27: <PRE>
28: #ifndef HTMLDTD_H
2.1 timbl 29: #define HTMLDTD_H
30:
2.7.2.1 ! frystyk 31: #include "SGML.h"
! 32: </PRE>
! 33:
! 34: <H2>Entity numbers</H2>
2.6 timbl 35:
36: The entity names are defined in the C file. This gives the number of them.
2.7.2.1 ! frystyk 37:
! 38: <PRE>
2.6 timbl 39: #define HTML_ENTITIES 66
2.7.2.1 ! frystyk 40: </PRE>
! 41:
! 42: <H2>Element Numbers</H2>
2.6 timbl 43:
2.7.2.1 ! frystyk 44: Must Match all tables by element! These include tables in <A
! 45: HREF="HTMLPDTD.c" NAME="z1">HTMLPDTD.c</A> and code in <A
! 46: HREF="HTML.c" NAME="z0">HTML.c</A>.<P>
2.1 timbl 47:
2.7.2.1 ! frystyk 48: Differences from Internet Draft 00: HTML, H7,PLAINTEXT LISTINGand XMP
! 49: left in.
2.6 timbl 50:
2.7.2.1 ! frystyk 51: <PRE>
2.6 timbl 52: typedef enum _HTMLElement {
2.1 timbl 53: HTML_A,
54: HTML_ABBREV,
55: HTML_ABSTRACT,
56: HTML_ACRONYM,
57: HTML_ADDED,
58: HTML_ADDRESS,
59: HTML_ARG,
60: HTML_B,
61: HTML_BASE,
62: HTML_BLOCKQUOTE,
63: HTML_BODY,
64: HTML_BOX,
65: HTML_BR,
66: HTML_BYLINE,
67: HTML_CAPTION,
68: HTML_CHANGED,
69: HTML_CITE,
70: HTML_CMD,
71: HTML_CODE,
72: HTML_COMMENT,
73: HTML_DD,
74: HTML_DFN,
75: HTML_DIR,
76: HTML_DL,
77: HTML_DT,
78: HTML_EM,
79: HTML_FIG,
80: HTML_FOOTNOTE,
81: HTML_FORM,
82: HTML_H1,
83: HTML_H2,
84: HTML_H3,
85: HTML_H4,
86: HTML_H5,
87: HTML_H6,
88: HTML_H7,
89: HTML_HEAD,
90: HTML_HR,
91: HTML_HTML,
92: HTML_HTMLPLUS,
93: HTML_I,
94: HTML_IMAGE,
95: HTML_IMG,
96: HTML_INPUT,
97: HTML_ISINDEX,
98: HTML_KBD,
99: HTML_L,
100: HTML_LI,
101: HTML_LINK,
102: HTML_LISTING,
103: HTML_LIT,
104: HTML_MARGIN,
105: HTML_MATH,
106: HTML_MENU,
107: HTML_NEXTID,
108: HTML_NOTE,
109: HTML_OL,
110: HTML_OPTION,
111: HTML_OVER,
112: HTML_P,
113: HTML_PERSON,
114: HTML_PLAINTEXT,
115: HTML_PRE,
116: HTML_Q,
117: HTML_QUOTE,
118: HTML_RENDER,
119: HTML_REMOVED,
120: HTML_S,
121: HTML_SAMP,
122: HTML_SELECT,
123: HTML_STRONG,
124: HTML_SUB,
125: HTML_SUP,
126: HTML_TAB,
127: HTML_TABLE,
128: HTML_TD,
129: HTML_TEXTAREA,
130: HTML_TH,
131: HTML_TITLE,
132: HTML_TR,
133: HTML_TT,
134: HTML_U,
135: HTML_UL,
136: HTML_VAR,
137: HTML_XMP }
138: HTMLElement;
139:
140: #define HTMLP_ELEMENTS 85
141:
2.6 timbl 142: </PRE><H2>Attribute numbers</H2>Identifier is
143: HTML_<element>_<attribute>. These must match the tables in <A
144: HREF="HTMLPDTD.c" NAME="z2">HTMLPDTD.c</A> ! <PRE>
145: #define HTML_A_EFFECT 0
2.1 timbl 146: #define HTML_A_HREF 1
147: #define HTML_A_ID 2
148: #define HTML_A_METHODS 3
149: #define HTML_A_NAME 4
150: #define HTML_A_PRINT 5
151: #define HTML_A_REL 6
152: #define HTML_A_REV 7
153: #define HTML_A_SHAPE 8
154: #define HTML_A_TITLE 9
155: #define HTML_A_ATTRIBUTES 10
156:
157: #define HTML_BASE_ATTRIBUTES 1
158: #define HTML_FORM_ATTRIBUTES 5
159:
160: #define HTML_FIG_ATTRIBUTES 6
161:
162: #define HTML_GEN_ATTRIBUTES 3
163:
164: #define HTML_HTMLPLUS_ATTRIBUTES 2
165:
166: #define HTML_IMAGE_ATTRIBUTES 5
167:
168: #define HTML_CHANGED_ATTRIBUTES 2
2.3 frystyk 169: #define HTML_DL_ATTRIBUTES 3
2.1 timbl 170:
171: #define DL_COMPACT 0
172:
173: #define HTML_IMG_ALIGN 0
174: #define HTML_IMG_ALT 1
175: #define HTML_IMG_ISMAP 2 /* Obsolete but supported */
176: #define HTML_IMG_SEETHRU 3
177:
178: #define HTML_IMG_SRC 4
179:
180: #define HTML_IMG_ATTRIBUTES 5
181:
2.2 timbl 182: #define HTML_INPUT_ALIGN 0
183: #define HTML_INPUT_CHECKED 1
184: #define HTML_INPUT_DISABLED 2
185: #define HTML_INPUT_ERROR 3
186: #define HTML_INPUT_MAX 4
187: #define HTML_INPUT_MIN 5
188: #define HTML_INPUT_NAME 6
189: #define HTML_INPUT_SIZE 7
190: #define HTML_INPUT_SRC 8
191: #define HTML_INPUT_TYPE 9
192: #define HTML_INPUT_VALUE 10
193: #define HTML_INPUT_ATTRIBUTES 11
2.1 timbl 194:
195: #define HTML_L_ATTRIBUTES 4
196:
197: #define HTML_LI_ATTRIBUTES 4
198: #define HTML_LIST_ATTRIBUTES 4
199:
200: #define HTML_LINK_ATTRIBUTES 5
201:
202: #define HTML_ID_ATTRIBUTE 1
203:
204: #define HTML_NEXTID_ATTRIBUTES 1
205: #define HTML_NEXTID_N 0
206:
207: #define HTML_NOTE_ATTRIBUTES 4
208:
209: #define HTML_OPTION_ATTRIBUTES 3
210:
211: /* #define HTML_PRE_WIDTH 0
212: #define HTML_PRE_ATTRIBUTES 1
213: */
214: #define HTML_RENDER_ATTRIBUTES 2
215:
216: #define HTML_SELECT_ATTRIBUTES 4
217: #define HTML_TAB_ATTRIBUTES 2
218: #define HTML_TABLE_ATTRIBUTES 4
219: #define HTML_TD_ATTRIBUTES 4
220:
221: #define HTML_TEXTAREA_ATTRIBUTES 6
222:
223: #define HTML_TH_ATTRIBUTES 4
224:
225: #define HTML_UL_ATTRIBUTES 6
226:
227: extern CONST SGML_dtd HTMLP_dtd;
228:
229:
2.6 timbl 230: </PRE><H2>Start anchor element</H2>It is kinda convenient to have a particular
231: routine for starting an anchor element,
232: as everything else for HTML is simple anyway. <H3>On entry</H3>targetstream
233: poinst to a structured stream object.<P>name and href point to attribute
234: strings or are NULL if the attribute is to be omitted. <PRE>
235: extern void HTStartAnchor PARAMS((
2.1 timbl 236: HTStructured * targetstream,
237: CONST char * name,
238: CONST char * href));
239:
2.6 timbl 240:
241: </PRE><H2>Put image element</H2>Hopefully as useful as HTStartAnchor. <H3>
242: On entry</H3>targetstream point to a structured stream object.<P>src,
243: alt and align are omitted if they are set to NULL. <PRE>
2.4 frystyk 244: extern void HTMLPutImg PARAMS((HTStructured *obj,
245: CONST char *src,
246: CONST char *alt,
247: CONST char *align));
2.1 timbl 248:
2.6 timbl 249: </PRE><H2>Specify next ID to be used</H2>This is another convenience routine,
250: for specifying the next ID to be used by an editor in the series z1. z2,...
251: <PRE>
252: extern void HTNextID PARAMS((HTStructured * targetStream,
2.5 timbl 253: CONST char * s));
2.1 timbl 254:
255: #endif /* HTMLDTD_H */
256:
2.6 timbl 257: </PRE>End of module definition </BODY></HTML>
Webmaster