Package org.openpdf.extend
Interface ReplacedElementFactory
- All Known Implementing Classes:
ITextReplacedElementFactory,SwingReplacedElementFactory
public interface ReplacedElementFactory
-
Method Summary
Modifier and TypeMethodDescription@Nullable ReplacedElementcreateReplacedElement(LayoutContext c, BlockBox box, UserAgentCallback uac, int cssWidth, int cssHeight) NOTE: Only block equivalent elements can be replaced.voidRemoves any reference toElemente.voidreset()Instructs theReplacedElementFactoryto discard any cached data (typically because a new page is about to be loaded).voidIdentifies the FSL which will be used for callbacks when a form submit action is executed; you can use aDefaultFormSubmissionListenerif you don't want any action to be taken.
-
Method Details
-
createReplacedElement
@Nullable ReplacedElement createReplacedElement(LayoutContext c, BlockBox box, UserAgentCallback uac, int cssWidth, int cssHeight) NOTE: Only block equivalent elements can be replaced.- Parameters:
cssWidth- The CSS width of the element in dots (or-1if width isauto)cssHeight- The CSS height of the element in dots (or-1if the height should be treated asauto)- Returns:
- The
ReplacedElementornullif noReplacedElementapplies
-
reset
void reset()Instructs theReplacedElementFactoryto discard any cached data (typically because a new page is about to be loaded). -
remove
Removes any reference toElemente. -
setFormSubmissionListener
Identifies the FSL which will be used for callbacks when a form submit action is executed; you can use aDefaultFormSubmissionListenerif you don't want any action to be taken.- Parameters:
listener- the listener instance to receive callbacks on form submission.
-