public class PDFIcon extends DynamicEditorIcon
This class uses pdf-renderer, obtainable from https://pdf-renderer.dev.java.net/. This is an "an open source, all Java library which renders PDF documents to the screen using Java2D." By using this icon, an actor or attribute in Vergil can be defined by a PDF file. Using this icon requires that PDFRenderer.jar in the classpath, it is usually found in $PTII/lib/PDFRenderer.jar.
NamedObj.ContainedObjectsIterator
_figures
_containerToBe, _iconCache
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _deferChangeRequests, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS
Constructor and Description |
---|
PDFIcon(NamedObj container,
java.lang.String name)
Create a new icon with the given name in the given container.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
clone(Workspace workspace)
Clone the object into the specified workspace.
|
Figure |
createBackgroundFigure()
Create a new default background figure, which is an instance
of PDFFigure.
|
void |
setPage(com.sun.pdfview.PDFPage page)
Specify an PDF page to display.
|
void |
setScale(double scalePercentage)
Specify a scaling percentage of the PDF page.
|
_addLiveFigure, _liveFigureIterator, _trimLiveFigures
_createDefaultBackgroundFigure, _isPropertySet, _recreateFigure, createFigure, createIcon, getContainerOrContainerToBe, setContainerToBe
_checkContainer, _getContainedObject, _propagateExistence, getContainer, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, setContainer, setName, updateContent
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _containedDecorators, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _description, _executeChangeRequests, _exportMoMLContents, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, _validateSettables, addChangeListener, addDebugListener, addHierarchyListener, attributeChanged, attributeDeleted, attributeList, attributeList, attributeTypeChanged, clone, containedObjectsIterator, decorators, deepContains, depthInHierarchy, description, description, event, executeChangeRequests, exportMoML, exportMoML, exportMoML, exportMoML, exportMoML, exportMoMLPlain, getAttribute, getAttribute, getAttributes, getChangeListeners, getClassName, getDecoratorAttribute, getDecoratorAttributes, getDerivedLevel, getDerivedList, getDisplayName, getElementName, getFullName, getModelErrorHandler, getName, getName, getPrototypeList, getSource, handleModelError, isDeferringChangeRequests, isOverridden, isPersistent, lazyContainedObjectsIterator, message, notifyOfNameChange, propagateExistence, propagateValue, propagateValues, removeAttribute, removeChangeListener, removeDebugListener, removeHierarchyListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, toString, uniqueName, validateSettables, workspace
public PDFIcon(NamedObj container, java.lang.String name) throws IllegalActionException, NameDuplicationException
container
- The container.name
- The name of the attribute.IllegalActionException
- If the attribute is not of an
acceptable class for the container.NameDuplicationException
- If the name coincides with
an attribute already in the container.public java.lang.Object clone(Workspace workspace) throws java.lang.CloneNotSupportedException
clone
in class DynamicEditorIcon
workspace
- The workspace for the cloned object.java.lang.CloneNotSupportedException
- Not thrown in this base classNamedObj.exportMoML(Writer, int, String)
,
NamedObj.setDeferringChangeRequests(boolean)
public Figure createBackgroundFigure()
createBackgroundFigure
in class EditorIcon
public void setPage(com.sun.pdfview.PDFPage page)
page
- The PDF page to display.public void setScale(double scalePercentage)
scalePercentage
- The scale percentage.