Class RunFormatProviderBase<T>
- java.lang.Object
-
- com.vladsch.flexmark.docx.converter.util.RunFormatProviderBase<T>
-
- All Implemented Interfaces:
FormatProvider<T>
,RunFormatProvider<T>
- Direct Known Subclasses:
AttributeRunFormatProvider
,BoldRunFormatProvider
,FootnoteRunFormatProvider
,ItalicRunFormatProvider
,SourceCodeRunFormatProvider
,StrikethroughRunFormatProvider
,SubscriptRunFormatProvider
,SuperscriptRunFormatProvider
,UnderlineRunFormatProvider
public class RunFormatProviderBase<T> extends java.lang.Object implements RunFormatProvider<T>
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
myBaseStyleId
protected DocxContext<T>
myDocx
protected T
myFrame
protected java.lang.String
myHighlightShadingColor
protected boolean
myNoCharacterStyles
protected RunFormatProvider<T>
myParent
-
Fields inherited from interface com.vladsch.flexmark.docx.converter.util.RunFormatProvider
SPACE_PRESERVE
-
-
Constructor Summary
Constructors Constructor Description RunFormatProviderBase(DocxContext<T> docx, java.lang.String baseStyleId, boolean noCharacterStyles, java.lang.String highlightShadingColor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
finalize, add elements to the document after main part as needed after this method returns no more calls will be made to this providerT
getProviderFrame()
get the node for this formatting blockvoid
getRPr(org.docx4j.wml.RPr rPr)
RunFormatProvider<T>
getRunParent()
org.docx4j.wml.Style
getStyle()
java.lang.String
getStyleId()
these are the hard-coded styles on which this block is based used for reference purposes by children to figure out what they need to combineprotected RunFormatProvider<T>
getStyleParent()
Get the style parent for the next P of this blockprotected void
inheritParentStyle(org.docx4j.wml.RPr rPr, org.docx4j.wml.RPr parentRPr)
void
open()
initialize internal stuff based on the parent for future use optionally add elements to doc before main elements any P creates will call the getPPr(), getParaRPr() and addP() for this provider so don't create elements until you are ready to handle these calls
-
-
-
Field Detail
-
myDocx
protected final DocxContext<T> myDocx
-
myFrame
protected final T myFrame
-
myParent
protected final RunFormatProvider<T> myParent
-
myBaseStyleId
protected final java.lang.String myBaseStyleId
-
myNoCharacterStyles
protected final boolean myNoCharacterStyles
-
myHighlightShadingColor
protected final java.lang.String myHighlightShadingColor
-
-
Constructor Detail
-
RunFormatProviderBase
public RunFormatProviderBase(DocxContext<T> docx, java.lang.String baseStyleId, boolean noCharacterStyles, java.lang.String highlightShadingColor)
-
-
Method Detail
-
getProviderFrame
public T getProviderFrame()
Description copied from interface:FormatProvider
get the node for this formatting block- Specified by:
getProviderFrame
in interfaceFormatProvider<T>
- Returns:
- node for this format provider
-
open
public void open()
Description copied from interface:FormatProvider
initialize internal stuff based on the parent for future use optionally add elements to doc before main elements any P creates will call the getPPr(), getParaRPr() and addP() for this provider so don't create elements until you are ready to handle these calls- Specified by:
open
in interfaceFormatProvider<T>
-
close
public void close()
Description copied from interface:FormatProvider
finalize, add elements to the document after main part as needed after this method returns no more calls will be made to this provider- Specified by:
close
in interfaceFormatProvider<T>
-
getStyle
public org.docx4j.wml.Style getStyle()
- Specified by:
getStyle
in interfaceFormatProvider<T>
-
getStyleId
public java.lang.String getStyleId()
Description copied from interface:FormatProvider
these are the hard-coded styles on which this block is based used for reference purposes by children to figure out what they need to combine- Specified by:
getStyleId
in interfaceFormatProvider<T>
- Returns:
- style id
-
getRunParent
public RunFormatProvider<T> getRunParent()
- Specified by:
getRunParent
in interfaceRunFormatProvider<T>
-
getStyleParent
protected RunFormatProvider<T> getStyleParent()
Get the style parent for the next P of this block- Returns:
- parent to use for style inheritance
-
inheritParentStyle
protected void inheritParentStyle(org.docx4j.wml.RPr rPr, org.docx4j.wml.RPr parentRPr)
-
getRPr
public void getRPr(org.docx4j.wml.RPr rPr)
- Specified by:
getRPr
in interfaceRunFormatProvider<T>
-
-