Class RtfFontList
java.lang.Object
com.lowagie.text.rtf.RtfElement
com.lowagie.text.rtf.style.RtfFontList
- All Implemented Interfaces:
RtfBasicElement, RtfExtendedElement
The RtfFontList stores the list of fonts used in the rtf document. It also
has methods for writing this list to the document
Version: $Id: RtfFontList.java 3580 2008-08-06 15:52:00Z howard_s $
- Author:
- Mark Hall (Mark.Hall@mail.room3b.eu), Thomas Bickel (tmb99@inode.at)
-
Field Summary
FieldsFields inherited from class RtfElement
document, inHeader, inTableFields inherited from interface RtfBasicElement
CLOSE_GROUP, COMMA_DELIMITER, DELIMITER, OPEN_GROUP, TWIPS_FACTOR -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintgetFontNumber(RtfFont font) Gets the index of the font in the list of fonts.voidwriteContent(OutputStream out) unusedvoidwriteDefinition(OutputStream result) Writes the definition of the font listMethods inherited from class RtfElement
intToByteArray, isInTable, setInHeader, setInTable, setRtfDocumentMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface RtfBasicElement
setInHeader, setInTable, setRtfDocument
-
Field Details
-
FONT_NUMBER
public static final byte[] FONT_NUMBERConstant for the font number
-
-
Constructor Details
-
RtfFontList
Creates a RtfFontList- Parameters:
doc- The RtfDocument this RtfFontList belongs to
-
-
Method Details
-
writeContent
unused- Specified by:
writeContentin interfaceRtfBasicElement- Specified by:
writeContentin classRtfElement- Parameters:
out- TheOutputStreamto write the content to- Throws:
IOException
-
getFontNumber
Gets the index of the font in the list of fonts. If the font does not exist in the list, it is added.- Parameters:
font- The font to get the id for- Returns:
- The index of the font
-
writeDefinition
Writes the definition of the font list- Specified by:
writeDefinitionin interfaceRtfExtendedElement- Parameters:
result- TheOutputStreamto write the element definition to- Throws:
IOException
-