KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > lowagie > text > html > HtmlTags


1 /*
2  * $Id: HtmlTags.java 1728 2005-05-03 14:44:38Z blowagie $
3  * $Name$
4  *
5  * Copyright 2001, 2002 by Bruno Lowagie.
6  *
7  * The contents of this file are subject to the Mozilla Public License Version 1.1
8  * (the "License"); you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at http://www.mozilla.org/MPL/
10  *
11  * Software distributed under the License is distributed on an "AS IS" basis,
12  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
13  * for the specific language governing rights and limitations under the License.
14  *
15  * The Original Code is 'iText, a free JAVA-PDF library'.
16  *
17  * The Initial Developer of the Original Code is Bruno Lowagie. Portions created by
18  * the Initial Developer are Copyright (C) 1999, 2000, 2001, 2002 by Bruno Lowagie.
19  * All Rights Reserved.
20  * Co-Developer of the code is Paulo Soares. Portions created by the Co-Developer
21  * are Copyright (C) 2000, 2001, 2002 by Paulo Soares. All Rights Reserved.
22  *
23  * Contributor(s): all the names of the contributors are added in the source code
24  * where applicable.
25  *
26  * Alternatively, the contents of this file may be used under the terms of the
27  * LGPL license (the "GNU LIBRARY GENERAL PUBLIC LICENSE"), in which case the
28  * provisions of LGPL are applicable instead of those above. If you wish to
29  * allow use of your version of this file only under the terms of the LGPL
30  * License and not to allow others to use your version of this file under
31  * the MPL, indicate your decision by deleting the provisions above and
32  * replace them with the notice and other provisions required by the LGPL.
33  * If you do not delete the provisions above, a recipient may use your version
34  * of this file under either the MPL or the GNU LIBRARY GENERAL PUBLIC LICENSE.
35  *
36  * This library is free software; you can redistribute it and/or modify it
37  * under the terms of the MPL as stated above or under the terms of the GNU
38  * Library General Public License as published by the Free Software Foundation;
39  * either version 2 of the License, or any later version.
40  *
41  * This library is distributed in the hope that it will be useful, but WITHOUT
42  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
43  * FOR A PARTICULAR PURPOSE. See the GNU Library general Public License for more
44  * details.
45  *
46  * If you didn't download this code from the following link, you should check if
47  * you aren't using an obsolete version:
48  * http://www.lowagie.com/iText/
49  */

50
51 package com.lowagie.text.html;
52
53 /**
54  * A class that contains all the possible tagnames and their attributes.
55  */

56
57 public class HtmlTags {
58     
59 /** the root tag. */
60     public static final String JavaDoc HTML = "html";
61     
62 /** the head tag */
63     public static final String JavaDoc HEAD = "head";
64     
65 /** This is a possible HTML attribute for the HEAD tag. */
66     public static final String JavaDoc CONTENT = "content";
67     
68 /** the meta tag */
69     public static final String JavaDoc META = "meta";
70     
71 /** attribute of the root tag */
72     public static final String JavaDoc SUBJECT = "subject";
73     
74 /** attribute of the root tag */
75     public static final String JavaDoc KEYWORDS = "keywords";
76     
77 /** attribute of the root tag */
78     public static final String JavaDoc AUTHOR = "author";
79     
80 /** the title tag. */
81     public static final String JavaDoc TITLE = "title";
82     
83 /** the script tag. */
84     public static final String JavaDoc SCRIPT = "script";
85
86 /** This is a possible HTML attribute for the SCRIPT tag. */
87     public static final String JavaDoc LANGUAGE = "language";
88
89 /** This is a possible value for the LANGUAGE attribute. */
90     public static final String JavaDoc JAVASCRIPT = "JavaScript";
91
92 /** the body tag. */
93     public static final String JavaDoc BODY = "body";
94     
95 /** This is a possible HTML attribute for the BODY tag */
96     public static final String JavaDoc JAVASCRIPT_ONLOAD = "onLoad";
97
98 /** This is a possible HTML attribute for the BODY tag */
99     public static final String JavaDoc JAVASCRIPT_ONUNLOAD = "onUnLoad";
100
101 /** This is a possible HTML attribute for the BODY tag. */
102     public static final String JavaDoc TOPMARGIN = "topmargin";
103     
104 /** This is a possible HTML attribute for the BODY tag. */
105     public static final String JavaDoc BOTTOMMARGIN = "bottommargin";
106     
107 /** This is a possible HTML attribute for the BODY tag. */
108     public static final String JavaDoc LEFTMARGIN = "leftmargin";
109     
110 /** This is a possible HTML attribute for the BODY tag. */
111     public static final String JavaDoc RIGHTMARGIN = "rightmargin";
112     
113     // Phrases, Anchors, Lists and Paragraphs
114

115 /** the chunk tag */
116     public static final String JavaDoc CHUNK = "font";
117     
118 /** the phrase tag */
119     public static final String JavaDoc CODE = "code";
120     
121 /** the phrase tag */
122     public static final String JavaDoc VAR = "var";
123     
124 /** the anchor tag */
125     public static final String JavaDoc ANCHOR = "a";
126     
127 /** the list tag */
128     public static final String JavaDoc ORDEREDLIST = "ol";
129     
130 /** the list tag */
131     public static final String JavaDoc UNORDEREDLIST = "ul";
132     
133 /** the listitem tag */
134     public static final String JavaDoc LISTITEM = "li";
135     
136 /** the paragraph tag */
137     public static final String JavaDoc PARAGRAPH = "p";
138     
139 /** attribute of anchor tag */
140     public static final String JavaDoc NAME = "name";
141     
142 /** attribute of anchor tag */
143     public static final String JavaDoc REFERENCE = "href";
144     
145 /** attribute of anchor tag */
146     public static final String JavaDoc[] H = new String JavaDoc[6];
147     static {
148         H[0] = "h1";
149         H[1] = "h2";
150         H[2] = "h3";
151         H[3] = "h4";
152         H[4] = "h5";
153         H[5] = "h6";
154     }
155     
156     // Chunks
157

158 /** attribute of the chunk tag */
159     public static final String JavaDoc FONT = "face";
160     
161 /** attribute of the chunk tag */
162     public static final String JavaDoc SIZE = "point-size";
163     
164 /** attribute of the chunk/table/cell tag */
165     public static final String JavaDoc COLOR = "color";
166     
167 /** some phrase tag */
168     public static final String JavaDoc EM = "em";
169     
170 /** some phrase tag */
171     public static final String JavaDoc I = "i";
172     
173 /** some phrase tag */
174     public static final String JavaDoc STRONG = "strong";
175     
176 /** some phrase tag */
177     public static final String JavaDoc B = "b";
178     
179 /** some phrase tag */
180     public static final String JavaDoc S = "s";
181     
182 /** some phrase tag */
183     public static final String JavaDoc U = "u";
184     
185 /** some phrase tag */
186     public static final String JavaDoc SUB = "sub";
187     
188 /** some phrase tag */
189     public static final String JavaDoc SUP = "sup";
190     
191 /** the possible value of a tag */
192     public static final String JavaDoc HORIZONTALRULE = "hr";
193     
194     // tables/cells
195

196 /** the table tag */
197     public static final String JavaDoc TABLE = "table";
198     
199 /** the cell tag */
200     public static final String JavaDoc ROW = "tr";
201     
202 /** the cell tag */
203     public static final String JavaDoc CELL = "td";
204     
205 /** attribute of the cell tag */
206     public static final String JavaDoc HEADERCELL = "th";
207     
208 /** attribute of the table tag */
209     public static final String JavaDoc COLUMNS = "cols";
210     
211 /** attribute of the table tag */
212     public static final String JavaDoc CELLPADDING = "cellpadding";
213     
214 /** attribute of the table tag */
215     public static final String JavaDoc CELLSPACING = "cellspacing";
216     
217 /** attribute of the cell tag */
218     public static final String JavaDoc COLSPAN = "colspan";
219     
220 /** attribute of the cell tag */
221     public static final String JavaDoc ROWSPAN = "rowspan";
222     
223 /** attribute of the cell tag */
224     public static final String JavaDoc NOWRAP = "nowrap";
225     
226 /** attribute of the table/cell tag */
227     public static final String JavaDoc BORDERWIDTH = "border";
228     
229 /** attribute of the table/cell tag */
230     public static final String JavaDoc WIDTH = "width";
231     
232 /** attribute of the table/cell tag */
233     public static final String JavaDoc BACKGROUNDCOLOR = "bgcolor";
234     
235 /** attribute of the table/cell tag */
236     public static final String JavaDoc BORDERCOLOR = "bordercolor";
237     
238 /** attribute of paragraph/image/table tag */
239     public static final String JavaDoc ALIGN = "align";
240     
241 /** attribute of chapter/section/paragraph/table/cell tag */
242     public static final String JavaDoc LEFT = "left";
243     
244 /** attribute of chapter/section/paragraph/table/cell tag */
245     public static final String JavaDoc RIGHT = "right";
246     
247 /** attribute of the cell tag */
248     public static final String JavaDoc HORIZONTALALIGN = "align";
249     
250 /** attribute of the cell tag */
251     public static final String JavaDoc VERTICALALIGN = "valign";
252     
253 /** attribute of the table/cell tag */
254     public static final String JavaDoc TOP = "top";
255     
256 /** attribute of the table/cell tag */
257     public static final String JavaDoc BOTTOM = "bottom";
258     
259     // Misc
260

261 /** the image tag */
262     public static final String JavaDoc IMAGE = "img";
263     
264 /** attribute of the image tag */
265     public static final String JavaDoc URL = "src";
266     
267 /** attribute of the image tag */
268     public static final String JavaDoc ALT = "alt";
269     
270 /** attribute of the image tag */
271     public static final String JavaDoc PLAINWIDTH = "width";
272     
273 /** attribute of the image tag */
274     public static final String JavaDoc PLAINHEIGHT = "height";
275     
276 /** the newpage tag */
277     public static final String JavaDoc NEWLINE = "br";
278     
279     // alignment attribute values
280

281 /** the possible value of an alignment attribute */
282     public static final String JavaDoc ALIGN_LEFT = "Left";
283     
284 /** the possible value of an alignment attribute */
285     public static final String JavaDoc ALIGN_CENTER = "Center";
286     
287 /** the possible value of an alignment attribute */
288     public static final String JavaDoc ALIGN_RIGHT = "Right";
289     
290 /** the possible value of an alignment attribute */
291     public static final String JavaDoc ALIGN_JUSTIFIED = "Justify";
292     
293 /** the possible value of an alignment attribute */
294     public static final String JavaDoc ALIGN_TOP = "Top";
295     
296 /** the possible value of an alignment attribute */
297     public static final String JavaDoc ALIGN_MIDDLE = "Middle";
298     
299 /** the possible value of an alignment attribute */
300     public static final String JavaDoc ALIGN_BOTTOM = "Bottom";
301     
302 /** the possible value of an alignment attribute */
303     public static final String JavaDoc ALIGN_BASELINE = "Baseline";
304     
305 /** the possible value of an alignment attribute */
306     public static final String JavaDoc DEFAULT = "Default";
307     
308     /** The DIV tag. */
309     public static final String JavaDoc DIV = "div";
310
311     /** The SPAN tag. */
312     public static final String JavaDoc SPAN = "span";
313     /** The LINK tag. */
314     public static final String JavaDoc LINK = "link";
315     
316     /** This is a possible HTML attribute for the LINK tag. */
317     public static final String JavaDoc TEXT_CSS = "text/css";
318
319     /** This is a possible HTML attribute for the LINK tag. */
320     public static final String JavaDoc REL = "rel";
321
322     /** This is used for inline css style information */
323     public static final String JavaDoc STYLE = "style";
324
325     /** This is a possible HTML attribute for the LINK tag. */
326     public static final String JavaDoc TYPE = "type";
327
328     /** This is a possible HTML attribute. */
329     public static final String JavaDoc STYLESHEET = "stylesheet";
330
331 }
Popular Tags