Annotation of libwww/Library/src/HTMLPDTD.html, revision 2.14

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

Webmaster