Top Fields Constructors Methods
com.openhtmltopdf.pdfboxout

public Class PdfBoxReplacedElementFactory

extends Object
implements ReplacedElementFactory
Class Inheritance
All Implemented Interfaces
com.openhtmltopdf.extend.ReplacedElementFactory
Imports
com.openhtmltopdf.extend.*, com.openhtmltopdf.layout.LayoutContext, com.openhtmltopdf.outputdevice.helper.ExternalResourceType, com.openhtmltopdf.render.BlockBox, com.openhtmltopdf.resource.XMLResource, com.openhtmltopdf.util.ImageUtil, org.w3c.dom.Element, java.io.ByteArrayInputStream

Field Summary

Modifier and TypeField and Description
private final SVGDrawer
private final FSObjectDrawerFactory
private final PdfBoxOutputDevice
private final SVGDrawer

Constructor Summary

AccessConstructor and Description
public
PdfBoxReplacedElementFactory(PdfBoxOutputDevice outputDevice, SVGDrawer svgImpl, FSObjectDrawerFactory objectDrawerFactory, SVGDrawer mathmlImpl)

Method Summary

Modifier and TypeMethod and Description
public ReplacedElement
createReplacedElement(LayoutContext c, BlockBox box, UserAgentCallback uac, int
The CSS width of the element in dots (or -1 if width is auto)
cssWidth
,
int
The CSS height of the element in dots (or -1 if the height should be treated as auto)
cssHeight
)

Implements com.openhtmltopdf.extend.ReplacedElementFactory.createReplacedElement.

Note

Only block equivalent elements can be replaced.

public boolean
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

_mathmlImplback to summary
private final SVGDrawer _mathmlImpl
_objectDrawerFactoryback to summary
private final FSObjectDrawerFactory _objectDrawerFactory
_outputDeviceback to summary
private final PdfBoxOutputDevice _outputDevice
_svgImplback to summary
private final SVGDrawer _svgImpl

Constructor Detail

PdfBoxReplacedElementFactoryback to summary
public PdfBoxReplacedElementFactory(PdfBoxOutputDevice outputDevice, SVGDrawer svgImpl, FSObjectDrawerFactory objectDrawerFactory, SVGDrawer mathmlImpl)

Method Detail

createReplacedElementback to summary
public ReplacedElement createReplacedElement(LayoutContext c, BlockBox box, UserAgentCallback uac, int cssWidth, int cssHeight)

Implements com.openhtmltopdf.extend.ReplacedElementFactory.createReplacedElement.

Doc from com.openhtmltopdf.extend.ReplacedElementFactory.createReplacedElement.

Note

Only block equivalent elements can be replaced.

Parameters
cssWidth:int

The CSS width of the element in dots (or -1 if width is auto)

cssHeight:int

The CSS height of the element in dots (or -1 if the height should be treated as auto)

Returns:ReplacedElement

The ReplacedElement or null if no ReplacedElement applies

Annotations
@Override
isReplacedElementback to summary
public boolean isReplacedElement(Element e)

Implements com.openhtmltopdf.extend.ReplacedElementFactory.isReplacedElement.

Annotations
@Override