API Overview API Index Package Overview Direct link to this page
JDK 1.6
  javax.swing.text.html. MinimalHTMLWriter View Source
Author(s)
Sunita Mani
Since
Version
1.15, 11/17/05
Serial
Hierarchy
 Object
      AbstractWriter
          MinimalHTMLWriter
Implements
Subclasses
Description
public class MinimalHTMLWriter
  MinimalHTMLWriter is a fallback writer used by the HTMLEditorKit to write out HTML for a document that is a not produced by the EditorKit.
See also:   
Constructors
public MinimalHTMLWriter (Writer w, StyledDocument doc)
  Creates a new MinimalHTMLWriter.
public MinimalHTMLWriter (Writer w, StyledDocument doc, int pos, int len)
  Creates a new MinimalHTMLWriter.
Methods
Hide/Show inherited methods
protected void decrIndent () [Inherited From AbstractWriter]
Decrements the indent level.
protected void endFontTag () throws IOException
  This is no longer used, instead <span> will be written out.
protected boolean getCanWrapLines () [Inherited From AbstractWriter]
  Returns whether or not the lines can be wrapped.
protected int getCurrentLineLength () [Inherited From AbstractWriter]
  Returns the current line length.
protected Document getDocument () [Inherited From AbstractWriter]
  Fetches the document.
protected ElementIterator getElementIterator () [Inherited From AbstractWriter]
  Fetches the ElementIterator.
public int getEndOffset () [Inherited From AbstractWriter]
  Returns the last offset to be output.
protected int getIndentLevel () [Inherited From AbstractWriter]
  Returns the current indentation level.
protected int getIndentSpace () [Inherited From AbstractWriter]
  Returns the amount of space to indent.
protected int getLineLength () [Inherited From AbstractWriter]
  Returns the maximum line length.
public String getLineSeparator () [Inherited From AbstractWriter]
  Returns the string used to represent newlines.
public int getStartOffset () [Inherited From AbstractWriter]
  Returns the first offset to be output.
protected String getText (Element elem) throws BadLocationException [Inherited From AbstractWriter]
  Returns the text associated with the element.
protected Writer getWriter () [Inherited From AbstractWriter]
  Returns the Writer that is used to output the content.
protected void incrIndent () [Inherited From AbstractWriter]
  Increments the indent level.
protected void indent () throws IOException [Inherited From AbstractWriter]
  Does indentation.
protected boolean inFontTag ()
Returns true if we are currently in a <font> tag.
protected boolean inRange (Element next) [Inherited From AbstractWriter]
  This method determines whether the current element is in the range specified.
protected boolean isLineEmpty () [Inherited From AbstractWriter]
  Returns true if the current line should be considered empty.
protected boolean isText (Element elem)
Returns true if the element is a text element.
protected void output (char[] content, int start, int length) throws IOException [Inherited From AbstractWriter]
  The last stop in writing out content.
protected void setCanWrapLines (boolean newValue) [Inherited From AbstractWriter]
  Sets whether or not lines can be wrapped.
protected void setCurrentLineLength (int length) [Inherited From AbstractWriter]
  Sets the current line length.
protected void setIndentSpace (int space) [Inherited From AbstractWriter]
  Enables subclasses to specify how many spaces an indent maps to.
protected void setLineLength (int l) [Inherited From AbstractWriter]
  Enables subclasses to set the number of characters they want written per line.
public void setLineSeparator (String value) [Inherited From AbstractWriter]
  Sets the String used to reprsent newlines.
protected void startFontTag (String style) throws IOException
  This is no longer used, instead <span> will be written out.
protected void text (Element elem) throws IOException BadLocationException [Overrides AbstractWriter]
  Writes out text.
public void write () throws IOException BadLocationException [Specified in AbstractWriter]
  Generates HTML output from a StyledDocument.
protected void write (char ch) throws IOException [Inherited From AbstractWriter]
  Writes out a character.
protected void write (char[] chars, int startIndex, int length) throws IOException [Inherited From AbstractWriter]
  All write methods call into this one.
protected void write (String content) throws IOException [Inherited From AbstractWriter]
  Writes out a string.
protected void writeAttributes (AttributeSet attr) throws IOException [Overrides AbstractWriter]
  Writes out all the attributes for the following types: StyleConstants.ParagraphConstants, StyleConstants.CharacterConstants, StyleConstants.FontConstants, StyleConstants.ColorConstants.
protected void writeBody () throws IOException BadLocationException
  Iterates over the elements in the document and processes elements based on whether they are branch elements or leaf elements.
protected void writeComponent (Element elem) throws IOException
  Responsible for handling Component Elements; deliberately unimplemented.
protected void writeContent (Element elem, boolean needsIndenting) throws IOException BadLocationException
  Writes out the attribute set in an HTML-compliant manner.
protected void writeEndParagraph () throws IOException
  Emits an end tag for a <p> tag.
protected void writeEndTag (String endTag) throws IOException
  Writes out an end tag appropriately indented.
protected void writeHeader () throws IOException
  Writes out the <head> and <style> tags, and then invokes writeStyles() to write out all the named styles as the content of the <style> tag.
protected void writeHTMLTags (AttributeSet attr) throws IOException
  Generates bold <b>, italic <i>, and <u> tags for the text based on its attribute settings.
protected void writeImage (Element elem) throws IOException
  Responsible for handling Icon Elements; deliberately unimplemented.
protected void writeLeaf (Element elem) throws IOException
  Responsible for writing out other non-text leaf elements.
protected void writeLineSeparator () throws IOException [Inherited From AbstractWriter]
  Writes the line separator.
protected void writeNonHTMLAttributes (AttributeSet attr) throws IOException
  Writes out the remaining character-level attributes (attributes other than bold, italic, and underline) in an HTML-compliant way.
protected void writeStartParagraph (Element elem) throws IOException
  Emits the start tag for a paragraph.
protected void writeStartTag (String tag) throws IOException
  Writes out a start tag appropriately indented.
protected void writeStyles () throws IOException
  Writes out all the named styles as the content of the <style> tag.
Fields
Hide/Show inherited fields
pack-private int endOffset
protectedfinalstatic char NEWLINE = "10" [Inherited From AbstractWriter]
  How the text packages models newlines.
pack-private int startOffset
Nested Classes
Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar