|
Gnostice PDFOne
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.gnostice.pdfone.PdfAnnot
com.gnostice.pdfone.PdfProAnnot
com.gnostice.pdfone.PdfWatermarkAnnot
This class represents a watermark annotation. A
PdfAppearanceStream
object is displayed by the watermark annotation. The contents of
the appearance stream object used by the watermark annotation
may
A watermark annotation does not have a popup window.
PdfFont fontHelvetica = PdfFont.create("Helvetica", 75, PdfEncodings.WINANSI); PdfTextFormatter tf = new PdfTextFormatter(); // Create an appearance stream PdfAppearanceStream ap1 = new PdfAppearanceStream(new PdfRect(0, 0, 1000, 1000)); ap1.writeText("WaterMarkAnnotation Demo", fontHelvetica, new PdfRect(0, 200, 1000, 1000), tf); // Create a watermark annotation PdfWatermarkAnnot waterAnnot1 = new PdfWatermarkAnnot( new PdfRect(0, 0, 100, 100), 0.5f, 0.5f, PdfWatermarkAnnot.ANNOT_TYPE_WATERMARK); waterAnnot1.setContents("WaterMark Demo"); waterAnnot1.setColor(java.awt.Color.BLUE); waterAnnot1.setNormalAppearance(ap1); // Create a PDF page PdfPage page = new PdfPage(); // Add the annotation to the page page.addAnnotation(waterAnnot1);
Field Summary |
Constructor Summary | |
PdfWatermarkAnnot()
Zero-argument default constructor. |
|
PdfWatermarkAnnot(PdfRect r,
double horizontalTranslation,
double verticalTranslation,
int flags)
|
|
PdfWatermarkAnnot(PdfRect r,
int flags)
|
Method Summary | |
PdfAppearanceStream |
getDownAppearance()
Returns the appearance stream that needs to be used by a viewer application to display the annotation/form field when the user places the mouse pointer over the annotation/form field and holds down the mouse button. |
double |
getHorizontalTranslation()
|
PdfAppearanceStream |
getNormalAppearance()
Returns the default appearance stream that needs to be used by a viewer application to display the annotation/form field (that is, when the user is not interacting with the annotation/form field). |
PdfPopUpAnnot |
getPopup()
Returns a popup annotation that needs to be used by a viewer application to display the popup window for this annotation. |
PdfAppearanceStream |
getRolloverAppearance()
Returns the appearance stream that needs to be used by a viewer application to display the annotation when the user places the mouse pointer over the annotation (and does not hold down the mouse button). |
double |
getVerticalTranslation()
|
void |
setDownAppearance(PdfAppearanceStream downAppearance)
Specifies the appearance stream that needs to be used by a viewer application to display the annotation/form field when the user places the mouse pointer over the annotation/form field and holds down the mouse button. |
void |
setHorizontalTranslation(double horizontalTranslation)
|
void |
setNormalAppearance(PdfAppearanceStream normalAppearance)
Specifies the default appearance stream that needs to be used by a viewer application to display the annotation/form field (that is, when the user is not interacting with the annotation/form field). |
void |
setPopup(PdfPopUpAnnot popup,
boolean overridePopUpProperties)
Specifies a popup annotation that needs to be used by a viewer application to display the popup window for this annotation. |
void |
setRolloverAppearance(PdfAppearanceStream rolloverAppearance)
Specifies the appearance stream that needs to be used by a viewer application to display the annotation/form field when the user places the mouse pointer over the annotation/form field (and does not hold down the mouse button). |
void |
setVerticalTranslation(double verticalTranslation)
|
Methods inherited from class com.gnostice.pdfone.PdfAnnot |
getAnnotName, getBorderStyle, getBorderWidth, getBottom, getColor, getContents, getDashPattern, getFlags, getLeft, getRect, getRight, getSubject, getTitle, getTop, getType, hashCode, isShowRect, setAnnotName, setBorderStyle, setBorderWidth, setColor, setContents, setDashPattern, setFlags, setRect, setRect, setRect, setRect, setRect, setShowRect, setSubject, setTitle |
Methods inherited from class java.lang.Object |
equals, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public PdfWatermarkAnnot()
public PdfWatermarkAnnot(PdfRect r, int flags) throws IOException, PdfException
public PdfWatermarkAnnot(PdfRect r, double horizontalTranslation, double verticalTranslation, int flags) throws IOException, PdfException
Method Detail |
public double getHorizontalTranslation()
public void setHorizontalTranslation(double horizontalTranslation)
public double getVerticalTranslation()
public void setVerticalTranslation(double verticalTranslation)
public PdfPopUpAnnot getPopup()
com.gnostice.pdfone.PdfProAnnot
public void setPopup(PdfPopUpAnnot popup, boolean overridePopUpProperties)
com.gnostice.pdfone.PdfProAnnot
popup
- popup annotation that needs to be used as the popup
windowoverridePopUpProperties
- whether a viewer application should override the
properties of the popup annotation with those of
this annotationPdfProAnnot.getPopup()
public PdfAppearanceStream getDownAppearance()
PdfProAnnot.getNormalAppearance()
,
PdfProAnnot.getDownAppearance()
,
PdfProAnnot.setNormalAppearance(PdfAppearanceStream)
,
PdfProAnnot.setRolloverAppearance(PdfAppearanceStream)
,
PdfProAnnot.setDownAppearance(PdfAppearanceStream)
public void setDownAppearance(PdfAppearanceStream downAppearance)
PdfProAnnot.getNormalAppearance()
,
PdfProAnnot.getDownAppearance()
,
PdfProAnnot.getRolloverAppearance()
,
PdfProAnnot.setNormalAppearance(PdfAppearanceStream)
,
PdfProAnnot.setRolloverAppearance(PdfAppearanceStream)
public PdfAppearanceStream getNormalAppearance()
PdfProAnnot.getDownAppearance()
,
PdfProAnnot.getRolloverAppearance()
,
PdfProAnnot.setNormalAppearance(PdfAppearanceStream)
,
PdfProAnnot.setDownAppearance(PdfAppearanceStream)
,
PdfProAnnot.setRolloverAppearance(PdfAppearanceStream)
public void setNormalAppearance(PdfAppearanceStream normalAppearance)
normalAppearance
- the specified appearance streamPdfProAnnot.setDownAppearance(PdfAppearanceStream)
,
PdfProAnnot.setRolloverAppearance(PdfAppearanceStream)
,
PdfProAnnot.getNormalAppearance()
,
PdfProAnnot.getDownAppearance()
,
PdfProAnnot.getRolloverAppearance()
public PdfAppearanceStream getRolloverAppearance()
PdfProAnnot.getNormalAppearance()
,
PdfProAnnot.getDownAppearance()
,
PdfProAnnot.setNormalAppearance(PdfAppearanceStream)
,
PdfProAnnot.setDownAppearance(PdfAppearanceStream)
,
PdfProAnnot.setRolloverAppearance(PdfAppearanceStream)
public void setRolloverAppearance(PdfAppearanceStream rolloverAppearance)
rolloverAppearance
- the specified appearance streamPdfProAnnot.setNormalAppearance(PdfAppearanceStream)
,
PdfProAnnot.setDownAppearance(PdfAppearanceStream)
,
PdfProAnnot.getNormalAppearance()
,
PdfProAnnot.getDownAppearance()
,
PdfProAnnot.getRolloverAppearance()
|
Free |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |