|
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.PdfTextAnnot
This class represents a text annotation. A text annotation is identified by its icon, which is displayed in its annotation rectangle.
// Create a PDF page PdfPage page = new PdfPage(); // Create a PDF font PdfFont fontHelvetica = PdfFont.create("Helvetica", 15, PdfEncodings.WINANSI); fontHelvetica.setColor(Color.BLUE); page.writeText("Text Annotations: ", fontHelvetica,80, 100); // Create a text annotation and set its properties PdfTextAnnot textAnnot = new PdfTextAnnot(120, 160, PdfTextAnnot.ICON_HELP, false); textAnnot.setColor(Color.BLUE); textAnnot.setContents("This is a Text Annotation."); textAnnot.setTitle("Annotation Title"); textAnnot.setSubject("Annotation Subject"); textAnnot.setFlags(PdfAnnot.FLAG_PRINT); // Add the text annotation to page page.addAnnotation(textAnnot);
Field Summary | |
static int |
ICON_COMMENT
|
static int |
ICON_HELP
|
static int |
ICON_INSERT
|
static int |
ICON_KEY
|
static int |
ICON_NEWPARAGRAPH
|
static int |
ICON_NOTE
|
static int |
ICON_PARAGRAPH
|
Constructor Summary | |
PdfTextAnnot()
|
|
PdfTextAnnot(double x,
double y,
Color c)
|
|
PdfTextAnnot(double x,
double y,
int flags)
|
|
PdfTextAnnot(double x,
double y,
int iconName,
boolean open)
|
|
PdfTextAnnot(double x,
double y,
int flags,
Color c)
|
|
PdfTextAnnot(double x,
double y,
String subject,
String contents,
String title)
|
|
PdfTextAnnot(double x,
double y,
String subject,
String contents,
String title,
Color c)
|
|
PdfTextAnnot(double x,
double y,
String subject,
String contents,
String title,
int flags)
|
|
PdfTextAnnot(double x,
double y,
String subject,
String contents,
String title,
int flags,
Color c)
|
|
PdfTextAnnot(double x,
double y,
String subject,
String contents,
String title,
int flags,
Color c,
int iconName,
boolean open)
|
Method Summary | |
Object |
clone()
|
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. |
int |
getIconName()
|
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). |
float |
getTransparency()
|
boolean |
isOpen()
|
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 |
setIconName(int name)
|
void |
setLocation(double x,
double y)
|
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 |
setOpen(boolean open)
|
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 |
setTransparency(float transparecyLevel)
|
Methods inherited from class com.gnostice.pdfone.PdfAnnot |
delete, getAnnotName, getBorderStyle, getBorderWidth, getBottom, getColor, getContents, getDashPattern, getFlags, getLeft, getRect, getRight, getSubject, getTitle, getTop, getType, hashCode, isDeleted, 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 |
Field Detail |
public static final int ICON_COMMENT
public static final int ICON_KEY
public static final int ICON_NOTE
public static final int ICON_HELP
public static final int ICON_NEWPARAGRAPH
public static final int ICON_PARAGRAPH
public static final int ICON_INSERT
Constructor Detail |
public PdfTextAnnot()
public PdfTextAnnot(double x, double y, String subject, String contents, String title, int flags, Color c, int iconName, boolean open) throws IOException, PdfException
public PdfTextAnnot(double x, double y, int iconName, boolean open)
public PdfTextAnnot(double x, double y, String subject, String contents, String title) throws IOException, PdfException
public PdfTextAnnot(double x, double y, String subject, String contents, String title, Color c) throws IOException, PdfException
public PdfTextAnnot(double x, double y, String subject, String contents, String title, int flags) throws IOException, PdfException
public PdfTextAnnot(double x, double y, String subject, String contents, String title, int flags, Color c) throws IOException, PdfException
public PdfTextAnnot(double x, double y, int flags) throws IOException, PdfException
public PdfTextAnnot(double x, double y, int flags, Color c) throws IOException, PdfException
public PdfTextAnnot(double x, double y, Color c) throws IOException, PdfException
Method Detail |
public Object clone()
public boolean isOpen()
public void setOpen(boolean open)
public int getIconName()
public void setIconName(int name)
public void setLocation(double x, double y)
public void setTransparency(float transparecyLevel)
public float getTransparency()
public PdfPopUpAnnot getPopup()
public void setPopup(PdfPopUpAnnot popup, boolean overridePopUpProperties)
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()
|
Pro. Ed. v5.0.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |