|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwriter2latex.latex.ConverterHelper
writer2latex.latex.HeadingConverter
public class HeadingConverter
Field Summary | |
---|---|
private java.lang.String[] |
sHeadingStyles
|
Fields inherited from class writer2latex.latex.ConverterHelper |
---|
config, ofr, palette |
Constructor Summary | |
---|---|
HeadingConverter(OfficeReader ofr,
Config config,
ConverterPalette palette)
Constructs a new HeadingConverter . |
Method Summary | |
---|---|
void |
appendDeclarations(LaTeXDocumentPortion pack,
LaTeXDocumentPortion decl)
|
private void |
appendHeadingStyles(LaTeXDocumentPortion ldp)
Convert heading styles and outline numbering to LaTeX. |
private void |
applyHardHeadingStyle(int nLevel,
java.lang.String sStyleName,
BeforeAfter baPage,
BeforeAfter baText,
Context context)
Use a paragraph style on a heading. |
boolean |
containsElements(org.w3c.dom.Node node)
|
void |
handleHeading(org.w3c.dom.Element node,
LaTeXDocumentPortion ldp,
Context oc)
Process a heading. |
(package private) static java.lang.String |
sectionName(int nLevel)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.lang.String[] sHeadingStyles
Constructor Detail |
---|
public HeadingConverter(OfficeReader ofr, Config config, ConverterPalette palette)
Constructs a new HeadingConverter
.
Method Detail |
---|
public void appendDeclarations(LaTeXDocumentPortion pack, LaTeXDocumentPortion decl)
appendDeclarations
in class ConverterHelper
public void handleHeading(org.w3c.dom.Element node, LaTeXDocumentPortion ldp, Context oc)
Process a heading.
node
- The text:h element node containing the headingldp
- The LaTeXDocumentPortion
to add LaTeX code tooc
- The current contextprivate void applyHardHeadingStyle(int nLevel, java.lang.String sStyleName, BeforeAfter baPage, BeforeAfter baText, Context context)
Use a paragraph style on a heading. If hard paragraph formatting is applied to a heading, page break and font is converted - other hard formatting is ignored.
This method also collects name of heading style and master page
nLevel
- The level of this headingsStyleName
- the name of the paragraph style to usebaPage
- a BeforeAfter
to put page break code intobaText
- a BeforeAfter
to put character formatting code intocontext
- the current context. This method will use and update the formatting contextprivate void appendHeadingStyles(LaTeXDocumentPortion ldp)
Convert heading styles and outline numbering to LaTeX.
An array of stylenames to use is required: The OOo writer file format allows different paragraph styles to be applied to individual headings, so this is not included in the styles. LaTeX (and OOo Writer!) usually uses the same format for all headings.
ldp
- the LaTeXDocumentPortion
to add definitions to.public boolean containsElements(org.w3c.dom.Node node)
static final java.lang.String sectionName(int nLevel)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |