public class PDAnnotationSquareCircle extends PDAnnotationMarkup
Modifier and Type | Field and Description |
---|---|
static String |
SUB_TYPE_CIRCLE
Constant for an elliptical type of annotation.
|
static String |
SUB_TYPE_SQUARE
Constant for a Rectangular type of annotation.
|
IT_FREE_TEXT, IT_FREE_TEXT_CALLOUT, IT_FREE_TEXT_TYPE_WRITER, RT_GROUP, RT_REPLY, SUB_TYPE_CARET, SUB_TYPE_FREETEXT, SUB_TYPE_INK, SUB_TYPE_POLYGON, SUB_TYPE_POLYLINE, SUB_TYPE_SOUND
Constructor and Description |
---|
PDAnnotationSquareCircle(COSDictionary field)
Creates a Line annotation from a COSDictionary, expected to be a correct object definition.
|
PDAnnotationSquareCircle(String subType)
Creates a Circle or Square annotation of the specified sub type.
|
Modifier and Type | Method and Description |
---|---|
void |
constructAppearances()
Create the appearance entry for this annotation.
|
void |
constructAppearances(PDDocument document)
Create the appearance entry for this annotation.
|
PDBorderEffectDictionary |
getBorderEffect()
This will retrieve the border effect dictionary, specifying effects to be applied used in drawing the line.
|
PDBorderStyleDictionary |
getBorderStyle()
This will retrieve the border style dictionary, specifying the width and dash pattern used in drawing the line.
|
PDColor |
getInteriorColor()
This will retrieve the interior color of the drawn area color is in DeviceRGB color space.
|
PDRectangle |
getRectDifference()
This will get the rectangle difference rectangle.
|
float[] |
getRectDifferences()
This will get the differences between the annotations "outer" rectangle defined by
/Rect and the border.
|
String |
getSubtype()
This will retrieve the sub type (and hence appearance, AP taking precedence) For this annotation.
|
void |
setBorderEffect(PDBorderEffectDictionary be)
This will set the border effect dictionary, specifying effects to be applied when drawing the line.
|
void |
setBorderStyle(PDBorderStyleDictionary bs)
This will set the border style dictionary, specifying the width and dash pattern used in drawing the line.
|
void |
setCustomAppearanceHandler(PDAppearanceHandler appearanceHandler)
Set a custom appearance handler for generating the annotations appearance streams.
|
void |
setInteriorColor(PDColor ic)
This will set interior color of the drawn area color is in DeviceRGB colo rspace.
|
void |
setRectDifference(PDRectangle rd)
This will set the rectangle difference rectangle.
|
void |
setRectDifferences(float difference)
This will set the difference between the annotations "outer" rectangle defined by /Rect and
the border.
|
void |
setRectDifferences(float differenceLeft,
float differenceTop,
float differenceRight,
float differenceBottom)
This will set the difference between the annotations "outer" rectangle defined by
/Rect and the border.
|
void |
setSubtype(String subType)
This will set the sub type (and hence appearance, AP taking precedence) For this annotation.
|
getCallout, getConstantOpacity, getCreationDate, getDefaultAppearance, getDefaultStyleString, getEndPointEndingStyle, getExternalData, getInkList, getInReplyTo, getIntent, getLineEndingStyle, getPath, getPopup, getQ, getReplyType, getRichContents, getStartPointEndingStyle, getSubject, getTitlePopup, getVertices, setCallout, setConstantOpacity, setCreationDate, setDefaultAppearance, setDefaultStyleString, setEndPointEndingStyle, setExternalData, setInkList, setInReplyTo, setIntent, setLineEndingStyle, setPopup, setQ, setReplyType, setRichContents, setStartPointEndingStyle, setSubject, setTitlePopup, setVertices
createAnnotation, equals, getAnnotationFlags, getAnnotationName, getAppearance, getAppearanceState, getBorder, getColor, getColor, getContents, getCOSObject, getModifiedDate, getNormalAppearanceStream, getOptionalContent, getPage, getRectangle, getStructParent, hashCode, isHidden, isInvisible, isLocked, isLockedContents, isNoRotate, isNoView, isNoZoom, isPrinted, isReadOnly, isToggleNoView, setAnnotationFlags, setAnnotationName, setAppearance, setAppearanceState, setBorder, setColor, setContents, setHidden, setInvisible, setLocked, setLockedContents, setModifiedDate, setModifiedDate, setNoRotate, setNoView, setNoZoom, setOptionalContent, setPage, setPrinted, setReadOnly, setRectangle, setStructParent, setToggleNoView
public static final String SUB_TYPE_SQUARE
public static final String SUB_TYPE_CIRCLE
public PDAnnotationSquareCircle(String subType)
subType
- the subtype the annotation represents.public PDAnnotationSquareCircle(COSDictionary field)
field
- the PDF object to represent as a field.public void setInteriorColor(PDColor ic)
setInteriorColor
in class PDAnnotationMarkup
ic
- color in the DeviceRGB color space.public PDColor getInteriorColor()
getInteriorColor
in class PDAnnotationMarkup
public void setBorderEffect(PDBorderEffectDictionary be)
setBorderEffect
in class PDAnnotationMarkup
be
- The border effect dictionary to set.public PDBorderEffectDictionary getBorderEffect()
getBorderEffect
in class PDAnnotationMarkup
public void setRectDifference(PDRectangle rd)
setRectDifference
in class PDAnnotationMarkup
rd
- the rectangle differencepublic PDRectangle getRectDifference()
getRectDifference
in class PDAnnotationMarkup
public void setSubtype(String subType)
subType
- The subtype of the annotationpublic String getSubtype()
getSubtype
in class PDAnnotation
public void setBorderStyle(PDBorderStyleDictionary bs)
setBorderStyle
in class PDAnnotationMarkup
bs
- the border style dictionary to set. TODO not all annotations may have a BS entrypublic PDBorderStyleDictionary getBorderStyle()
getBorderStyle
in class PDAnnotationMarkup
public void setRectDifferences(float difference)
This will set an equal difference for all sides
setRectDifferences
in class PDAnnotationMarkup
difference
- from the annotations /Rect entrypublic void setRectDifferences(float differenceLeft, float differenceTop, float differenceRight, float differenceBottom)
setRectDifferences
in class PDAnnotationMarkup
differenceLeft
- left difference from the annotations /Rect entrydifferenceTop
- top difference from the annotations /Rect entrydifferenceRight
- right difference from the annotations /Rect entrydifferenceBottom
- bottom difference from the annotations /Rect entrypublic float[] getRectDifferences()
getRectDifferences
in class PDAnnotationMarkup
public void setCustomAppearanceHandler(PDAppearanceHandler appearanceHandler)
setCustomAppearanceHandler
in class PDAnnotationMarkup
appearanceHandler
- public void constructAppearances()
PDAnnotation
constructAppearances
in class PDAnnotationMarkup
public void constructAppearances(PDDocument document)
PDAnnotation
constructAppearances
in class PDAnnotationMarkup
Copyright © 2002–2023 The Apache Software Foundation. All rights reserved.