public class CharStyleConverter extends StyleConverter
writer2latex.latex.ColorConverter
and
writer2latex.latex.style.I18n
declarations, styleMap, styleNames
Constructor and Description |
---|
CharStyleConverter(OfficeReader ofr,
LaTeXConfig config,
ConverterPalette palette)
Constructs a new
CharStyleConverter . |
Modifier and Type | Method and Description |
---|---|
void |
appendDeclarations(LaTeXDocumentPortion pack,
LaTeXDocumentPortion decl) |
void |
applyDefaultFont(StyleWithProperties style,
LaTeXDocumentPortion ldp)
Apply default font attributes (family, series, shape, size and color).
|
void |
applyFont(StyleWithProperties style,
boolean bDecl,
boolean bInherit,
BeforeAfter ba,
Context context)
Apply all font attributes (family, series, shape, size and color).
|
void |
applyFontEffects(StyleWithProperties style,
boolean bInherit,
BeforeAfter ba)
Apply font effects (position, underline, crossout, change case.
|
void |
applyHardCharFormatting(StyleWithProperties style,
BeforeAfter ba)
Apply hard character formatting (no inheritance).
|
void |
applyNormalFont(BeforeAfter ba)
Reset to normal font, size and color.
|
void |
applyTextStyle(java.lang.String sName,
BeforeAfter ba,
Context context)
Use a text style in LaTeX.
|
java.lang.String |
getFontName(java.lang.String sStyleName) |
java.lang.String |
getFontName(StyleWithProperties style) |
public CharStyleConverter(OfficeReader ofr, LaTeXConfig config, ConverterPalette palette)
Constructs a new CharStyleConverter
.
public void appendDeclarations(LaTeXDocumentPortion pack, LaTeXDocumentPortion decl)
appendDeclarations
in class StyleConverter
public void applyTextStyle(java.lang.String sName, BeforeAfter ba, Context context)
Use a text style in LaTeX.
sName
- the name of the text styleba
- a BeforeAfter
to put code intopublic java.lang.String getFontName(StyleWithProperties style)
public java.lang.String getFontName(java.lang.String sStyleName)
public void applyHardCharFormatting(StyleWithProperties style, BeforeAfter ba)
Apply hard character formatting (no inheritance).
This is used in sections and {foot|end}notes
style
- the style to useba
- the BeforeAfter
to add LaTeX code topublic void applyFont(StyleWithProperties style, boolean bDecl, boolean bInherit, BeforeAfter ba, Context context)
Apply all font attributes (family, series, shape, size and color).
style
- the OOo style to read attributesfrombDecl
- true if declaration form is requiredbInherit
- true if inherited properties should be usedba
- the BeforeAfter
to add LaTeX code to.public void applyNormalFont(BeforeAfter ba)
Reset to normal font, size and color.
ba
- the BeforeAfter
to add LaTeX code to.public void applyDefaultFont(StyleWithProperties style, LaTeXDocumentPortion ldp)
Apply default font attributes (family, series, shape, size and color).
style
- the OOo style to read attributesfromldp
- the LaTeXDocumentPortion
to add LaTeX code to.public void applyFontEffects(StyleWithProperties style, boolean bInherit, BeforeAfter ba)
Apply font effects (position, underline, crossout, change case.
style
- the OOo style to read attributesfrombInherit
- true if inherited properties should be usedba
- the BeforeAfter
to add LaTeX code to.