Gnostice PDFOne
Pro. Ed. v5.4


com.gnostice.pdfone
Class PdfPolygonAnnot

java.lang.Object
  extended by com.gnostice.pdfone.PdfAnnot
      extended by com.gnostice.pdfone.PdfPolylineAnnot
          extended by com.gnostice.pdfone.PdfPolygonAnnot
All Implemented Interfaces:
Usable, Cloneable

public class PdfPolygonAnnot
extends PdfPolylineAnnot

This class represents a polygon annotation. A polygon annotation is a closed figure made of straight lines. To specify the shape of the polygon, use the setVertices() method inherited from the PdfPolylineAnnot class. Here is a sample code snippet that shows how to create a polygon annotation.

PdfWriter writer1 =
   PdfWriter.fileWriter(
       new File("PdfPolygonAnnot_example.pdf"));
PdfDocument doc1 = new PdfDocument(writer1);
PdfPage p1 = new PdfPage();
doc1.add(p1);

// Define x-y coordinates for the lines forming
// the polygons
double vertices1[] = 
           { 100, 100, 150, 150, 200, 250, 100, 300 };
double vertices2[] = 
           { 400, 100, 450, 150, 500, 250, 400, 300 };        

// Create new polygon annotations
PdfPolygonAnnot pa1 = 
    new PdfPolygonAnnot(vertices1, 
                        "First annotation subject", 
                        "First annotation contents", 
                        "First annotation title", 
                        PdfAnnot.FLAG_READONLY, 
                        Color.BLUE, true, 2); 

PdfPolygonAnnot pa2 = 
    new PdfPolygonAnnot(vertices2, 
                        "Second annotation subject", 
                        "Second annotation contents", 
                        "Second annotation title", 
                        PdfAnnot.FLAG_LOCKED, 
                        Color.BLUE, true, 0); 

// Add the polygons to the document
doc1.addAnnotation(pa1, 1);
doc1.addAnnotation(pa2, 1);

doc1.setOpenAfterSave(true);
doc1.write();
writer1.dispose();


Field Summary
 
Fields inherited from class com.gnostice.pdfone.PdfPolylineAnnot
LINEENDSTYLE_BUTT, LINEENDSTYLE_CIRCLE, LINEENDSTYLE_CLOSED_ARROW, LINEENDSTYLE_DIAMOND, LINEENDSTYLE_NONE, LINEENDSTYLE_OPEN_ARROW, LINEENDSTYLE_RCLOSED_ARROW, LINEENDSTYLE_ROPEN_ARROW, LINEENDSTYLE_SLASH, LINEENDSTYLE_SQUARE
 
Fields inherited from class com.gnostice.pdfone.PdfAnnot
ANNOT_TYPE_CARET, ANNOT_TYPE_CIRCLE, ANNOT_TYPE_FILE_ATTACHMENT, ANNOT_TYPE_FREE_TEXT, ANNOT_TYPE_INK, ANNOT_TYPE_LINE, ANNOT_TYPE_LINK, ANNOT_TYPE_MARKUP, ANNOT_TYPE_POLYGON, ANNOT_TYPE_POLYLINE, ANNOT_TYPE_POPUP, ANNOT_TYPE_SQUARE, ANNOT_TYPE_STAMP, ANNOT_TYPE_TEXT, ANNOT_TYPE_WATERMARK, BORDERSTYLE_BEVELED, BORDERSTYLE_DASHED, BORDERSTYLE_INSET, BORDERSTYLE_SOLID, BORDERSTYLE_UNDERLINE, FLAG_HIDDEN, FLAG_INVISIBLE, FLAG_LOCKED, FLAG_NO_ROTATE, FLAG_NO_VIEW, FLAG_NO_ZOOM, FLAG_PRINT, FLAG_READONLY, FLAG_TOGGLE_NO_VIEW
 
Fields inherited from interface com.gnostice.pdfone.Usable
INCHES_TO_POINTS, MM_TO_INCHES, MM_TO_POINTS, PDF_3D_ANNOT, PDF_3D_VIEW, PDF_3DBG, PDF_3DD, PDF_3DV, PDF_A, PDF_AA, PDF_AC, PDF_ACROFORM, PDF_ACTION, PDF_ALTERNATEPRESENTATIONS, PDF_ANNOT, PDF_ANNOT_DEFAULT_TITLE, PDF_ANNOT_NAME, PDF_ANNOT_SUBJECT, PDF_ANNOTS, PDF_AP, PDF_ARRAYEND, PDF_ARRAYSTART, PDF_ARTBOX, PDF_AS, PDF_ASCENT, PDF_ASCII85, PDF_ASCII85_NEW, PDF_ASCIIHEX, PDF_ASCIIHEX_NEW, PDF_AuthEvent, PDF_AUTHOR, PDF_AVGWIDTH, PDF_B, PDF_BASEFONT, PDF_BBOX, PDF_BC, PDF_BE, PDF_BEFOREFORMAT, PDF_BEGINTEXT, PDF_BG, PDF_BINARYDATA, PDF_BITS_PER_COMPONENT, PDF_BL, PDF_BLEEDBOX, PDF_BLINDS, PDF_BMC, PDF_BORDER, PDF_BOX, PDF_BS, PDF_BTN, PDF_BYTERANGE, PDF_C, PDF_CA, PDF_CA_SMALL, PDF_CAPHEIGHT, PDF_CARETANNOT, PDF_CARRIAGE, PDF_CATALOG, PDF_CENTER_WINDOW, PDF_CF, PDF_CFM, PDF_CH, PDF_CID_TO_GID_MAP, PDF_CIDFONT_TYPE0, PDF_CIDFONT_TYPE1, PDF_CIDFONT_TYPE2, PDF_CIDSYSTEM_INFO, PDF_CIRCLEANNOT, PDF_CL, PDF_CM, PDF_COLOMNS, PDF_COLOR, PDF_COLORSPACE, PDF_COLORSPACE_CALGRAY, PDF_COLORSPACE_CALRGB, PDF_COLORSPACE_DEVICEN, PDF_COLORSPACE_ICCBASED, PDF_COLORSPACE_LAB, PDF_COLORSPACE_SEPARATION, PDF_CONTACTINFO, PDF_CONTENTS, PDF_COUNT, PDF_COVER, PDF_CREATIONDATE, PDF_CREATOR, PDF_CROPBOX, PDF_CS, PDF_CSP, PDF_D, PDF_DA, PDF_DATE, PDF_DATE_FORMAT, PDF_DCTDECODE, PDF_DCTDECODE_NEW, PDF_DECODEPARMS, PDF_DESC, PDF_DESCENDANT, PDF_DESCENDANT_FONTS, PDF_DESCENDENTFONTS, PDF_DESCENT, PDF_DESTINATION, PDF_DESTS, PDF_DEVICE_CMYK, PDF_DEVICE_GRAY, PDF_DEVICE_RGB, PDF_DI, PDF_DICTEND, PDF_DICTSTART, PDF_DIFFERENCES, PDF_DIRECTION, PDF_DISPLAY_DOCTITLE, PDF_DISPLAY_DURATION, PDF_DISSOLVE, PDF_DM, PDF_DOC_SUBJECT, PDF_DOCMDP, PDF_DOS, PDF_DP, PDF_DR, PDF_DS, PDF_DV, PDF_DW, PDF_E, PDF_EF, PDF_EMBEDDEDFILE, PDF_EMBEDDEDFILES, PDF_EMC, PDF_ENCODING, PDF_ENCRYPT, PDF_ENCRYPTMETADATA, PDF_ENDOBJ, PDF_ENDPATH, PDF_ENDSTREAM, PDF_ENDTEXT, PDF_EOCLIP, PDF_EOF, PDF_EXTGSTATE, PDF_F, PDF_FADE, PDF_FALSE, PDF_FDESCRIPTOR, PDF_FIELD_FLAG, PDF_FIELDS, PDF_FILEATTACHMENTANNOT, PDF_FILESPEC, PDF_FILTER, PDF_FIRST, PDF_FIRST_PAGE, PDF_FIRSTCHAR, PDF_FIT, PDF_FIT_WINDOW, PDF_FITB, PDF_FITBH, PDF_FITBV, PDF_FITH, PDF_FITR, PDF_FITV, PDF_FIXEDPRINT, PDF_FLAGS, PDF_FLATE, PDF_FLATE_NEW, PDF_FLY, PDF_FO, PDF_FONT, PDF_FONTBBOX, PDF_FONTDESCRIPTOR, PDF_FONTFILE, PDF_FONTFILE_2, PDF_FontFile_3, PDF_FONTFILE2, PDF_FONTNAME, PDF_FONTNAMEPREFIX, PDF_FORM, PDF_FORMFEED, PDF_FORMFONTPREFIX, PDF_FREE_TEXT_CALLOUT, PDF_FREE_TEXT_TYPEWRITER, PDF_FREETEXTANNOT, PDF_FS, PDF_FT, PDF_FULLSCREEN, PDF_GLITTER, PDF_GOTO_ACTION, PDF_GROUP, PDF_GS, PDF_H, PDF_HEADER, PDF_HEIGHT, PDF_HEXSTRINGEND, PDF_HEXSTRINGSTART, PDF_HIDE_MENUBAR, PDF_HIDE_TOOLBAR, PDF_HIDE_WINDOWUI, PDF_HIGHLIGHT, PDF_HORIZ_STEM, PDF_HORIZONTAL, PDF_I, PDF_IC, PDF_ID, PDF_IDS, PDF_IF, PDF_IMAGE, PDF_IMAGEB, PDF_IMAGEC, PDF_IMAGEI, PDF_IMPORTDATA, PDF_INDEX, PDF_INDEXED, PDF_INFO, PDF_INK, PDF_INKLIST, PDF_INWARD, PDF_IT, PDF_ITALANGLE, PDF_IX, PDF_JAVASCRIPT, PDF_JAVASCRIPT_ACTION, PDF_JS, PDF_KEYSTROKE, PDF_KEYWORDS, PDF_KIDS, PDF_L, PDF_L2R, PDF_LANG, PDF_LAST, PDF_LAST_PAGE, PDF_LASTCHAR, PDF_LAUNCH_ACTION, PDF_LE, PDF_LEGAL, PDF_LENGTH, PDF_LENGTH_1, PDF_LENGTH_2, PDF_LENGTH_3, PDF_LF, PDF_LINEANNOT, PDF_LINKANNOT, PDF_LITERALSTRINGEND, PDF_LITERALSTRINGSTART, PDF_LOCATION, PDF_LZWDECODE, PDF_M, PDF_MAC, PDF_MARKINFO, PDF_MATRIX, PDF_MAXLEN, PDF_MAXWIDTH, PDF_MEDIABOX, PDF_METADATA, PDF_MISSINGWIDTH, PDF_MK, PDF_MODDATE, PDF_N, PDF_NAME, PDF_NAMED, PDF_NAMED_ACT_FIND, PDF_NAMED_ACT_OPEN, PDF_NAMED_ACT_PRINT, PDF_NAMED_ACT_SEARCH, PDF_NAMES, PDF_NAMESTART, PDF_NEEDAPPEARANCES, PDF_NEWLINE, PDF_NEWWINDOW, PDF_NEXT, PDF_NEXT_PAGE, PDF_NO_COMP_OBJ, PDF_NONFULLSCREEN_PAGEMODE, PDF_NULL, PDF_O, PDF_OBJ, PDF_OBJSTREAM, PDF_OCPROPERTIES, PDF_OE, PDF_OFF, PDF_ONECOLUMN, PDF_OPEN, PDF_OPEN_ACTION, PDF_OPT, PDF_OUTLINES, PDF_OUTPUTINTENTS, PDF_OUTWARD, PDF_P, PDF_PAGE, PDF_PAGECLOSE, PDF_PAGEINVISIBLE, PDF_PAGELABELS, PDF_PAGELAYOUT, PDF_PAGEMODE, PDF_PAGEOPEN, PDF_PAGES, PDF_PAGEVISIBLE, PDF_PAINT_TYPE, PDF_PARAMS, PDF_PARENT, PDF_PATTERN, PDF_PATTERN_TYPE, PDF_PBD, PDF_PC, PDF_PDC, PDF_PDF, PDF_PERMS, PDF_PFD, PDF_PH, PDF_PIECEINFO, PDF_POLYGONANNOT, PDF_POLYLINEANNOT, PDF_POPUP, PDF_PREDICTOR, PDF_PREV, PDF_PREV_PAGE, PDF_PROCSET, PDF_PRODUCER, PDF_PROPERTIES, PDF_PUSH, PDF_PV, PDF_Q, PDF_QUADPOINTS, PDF_R, PDF_R2L, PDF_RC, PDF_RD, PDF_RE, PDF_REASON, PDF_RECALCULATE, PDF_RECT, PDF_REMOTEGOTO_ACTION, PDF_RENDITIONS, PDF_REPLACE, PDF_RESET_FORM, PDF_RESOURCES, PDF_RESTORE_GS, PDF_RI, PDF_ROOT, PDF_ROTATE, PDF_RUNLENGTH, PDF_RUNLENGTH_NEW, PDF_S, PDF_SC, PDF_SCN, PDF_SHADING, PDF_SHOWIMG, PDF_SHOWTEXT, PDF_SHOWTEXT_TJ, PDF_SIG, PDF_SIG_FILTER_ADOBE_PPKLITE, PDF_SIG_FILTER_ADOBE_PPKMS, PDF_SIG_SUBFILTER_ADBE_PKCS7_DETACHED, PDF_SIG_SUBFILTER_ADBE_PKCS7_SHA1, PDF_SINGLE_QUOTES, PDF_SINGLEPAGE, PDF_SIZE, PDF_SP, PDF_SPIDERINFO, PDF_SPLIT, PDF_SQUAREANNOT, PDF_SQUIGGLY, PDF_SS, PDF_STAMPANNOT, PDF_STARTXREF, PDF_StmF, PDF_STORE_GS, PDF_STREAM, PDF_StrF, PDF_STRIKEOUT, PDF_STRUCT_TREE, PDF_SUBFILTER, PDF_SUBMIT_FORM, PDF_SUBTYPE, PDF_T, PDF_TAB, PDF_TEMPLATES, PDF_TEXT, PDF_TEXTANNOT, PDF_TEXTCHARSPACE, PDF_TEXTDIMENSION, PDF_TEXTFONT, PDF_TEXTHORIZONTALSCALE, PDF_TEXTLEAD, PDF_TEXTMATRIX, PDF_TEXTNEWLINESTART, PDF_TEXTRENDER, PDF_TEXTWORDSPACE, PDF_THREADS, PDF_THUMB, PDF_TILING_TYPE, PDF_TITLE, PDF_TJ_OPERAND_END, PDF_TJ_OPERAND_START, PDF_TM, PDF_TOUNICODE, PDF_TP, PDF_TRAILER, PDF_TRANSITION, PDF_TRIMBOX, PDF_TRUE, PDF_TRUETYPE, PDF_TU, PDF_TWOCOLUMN_LEFT, PDF_TWOCOLUMN_RIGHT, PDF_TWOPAGE_LEFT, PDF_TWOPAGE_RIGHT, PDF_TX, PDF_TYPE, PDF_TYPE0, PDF_TYPE1, PDF_U, PDF_U3D, PDF_UE, PDF_UNCOVER, PDF_UNDERLINE, PDF_UNIX, PDF_URI_ACTION, PDF_URL, PDF_URLS, PDF_USEATTACHMENTS, PDF_USENONE, PDF_USEOC, PDF_USEOUTLINES, PDF_USETHUMBS, PDF_V, PDF_VALUECHANGE, PDF_VERSION, PDF_VERT_STEM, PDF_VERTICAL, PDF_VERTICES, PDF_VIEWER_PREFERENCES, PDF_W, PDF_WATERMARKANNOT, PDF_WIDGET, PDF_WIDTH, PDF_WIDTHS, PDF_WINANSIENCODING, PDF_WIPE, PDF_X, PDF_XML, PDF_XOBJECT, PDF_XREF, PDF_XREFSTMOFFSET, PDF_XREFSTREAM, PDF_XSTEP, PDF_XYZ, PDF_YES, PDF_YSTEP, PIXEL_PER_INCH, RUBICON_EMBEDDED, SITE, TEXT, TWIPS_TO_POINTS
 
Constructor Summary
PdfPolygonAnnot()
          Zero-argument default constructor.
PdfPolygonAnnot(double[] vertices, Color c)
          Constructs a polygon annotation with specified vertices and color.
PdfPolygonAnnot(double[] vertices, int flags)
           
PdfPolygonAnnot(double[] vertices, int flags, Color c)
           
PdfPolygonAnnot(double[] vertices, String subject, String contents, String title)
           
PdfPolygonAnnot(double[] vertices, String subject, String contents, String title, Color c)
           
PdfPolygonAnnot(double[] vertices, String subject, String contents, String title, int flags)
           
PdfPolygonAnnot(double[] vertices, String subject, String contents, String title, int flags, Color c)
           
PdfPolygonAnnot(double[] vertices, String subject, String contents, String title, int flags, Color c, boolean isCloudy, int cloudIntensity)
          Constructs a polygon annotation with specified vertices, subject, contents, title, flags, color, annotation attributes, and edge setting.
PdfPolygonAnnot(PdfRect r, Color c)
          Deprecated. Instead, use PdfPolygonAnnot(double[], Color).
PdfPolygonAnnot(PdfRect r, int flags)
          Deprecated. Instead, use PdfPolygonAnnot(double[], int).
PdfPolygonAnnot(PdfRect r, int flags, Color c)
          Deprecated. Instead, use PdfPolygonAnnot(double[], int, Color).
PdfPolygonAnnot(PdfRect r, String subject, String contents, String title)
          Deprecated. Instead, use PdfPolygonAnnot(double[], String, String, String).
PdfPolygonAnnot(PdfRect r, String subject, String contents, String title, Color c)
          Deprecated. Instead, use PdfPolygonAnnot(double[], String, String, String, Color).
PdfPolygonAnnot(PdfRect r, String subject, String contents, String title, int flags)
          Deprecated. Instead, use PdfPolygonAnnot(double[], String, String, String, int).
PdfPolygonAnnot(PdfRect r, String subject, String contents, String title, int flags, Color c)
          Deprecated. Instead, use PdfPolygonAnnot(PdfRect, String, String, String, int, Color).
PdfPolygonAnnot(PdfRect r, String subject, String contents, String title, int flags, Color c, boolean isCloudy, int cloudIntensity)
          Deprecated. Instead, use PdfPolygonAnnot(PdfRect, String, String, String, int, Color, boolean, int).
 
Method Summary
 Object clone()
           
 int getCloudIntensity()
          Returns value representing the intensity of the "cloudy" effect on edges of the polygon annotation.
 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.
 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).
 boolean isCloudy()
          Returns whether border of the polygon annotation has a "cloudy" effect.
 void setCloudIntensity(int cloudIntensity)
          Specifies value representing the intensity of the "cloudy" effect on edges of the polygon annotation.
 void setCloudy(boolean cloudy)
          Specifies whether border of the polygon annotation needs to have a "cloudy" effect.
 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 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).
 
Methods inherited from class com.gnostice.pdfone.PdfPolylineAnnot
getInteriorColor, getLineEndStyle, getLineStartStyle, getTransparency, getVertices, setInteriorColor, setLineEndStyle, setLineStartStyle, setRect, setRect, setRect, setRect, setRect, setTransparency, setVertices, setVertices
 
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, setShowRect, setSubject, setTitle
 
Methods inherited from class java.lang.Object
equals, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PdfPolygonAnnot

public PdfPolygonAnnot()
Zero-argument default constructor.


PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       String subject,
                       String contents,
                       String title,
                       int flags,
                       Color c,
                       boolean isCloudy,
                       int cloudIntensity)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(PdfRect, String, String, String, int, Color, boolean, int).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       String subject,
                       String contents,
                       String title,
                       int flags,
                       Color c,
                       boolean isCloudy,
                       int cloudIntensity)
                throws IOException,
                       PdfException
Constructs a polygon annotation with specified vertices, subject, contents, title, flags, color, annotation attributes, and edge setting.

Parameters:
vertices - x-y coordinates of the vertices
subject - text that needs to be displayed in the subject line of the popup window
contents - text that needs to be used as the contents of the popup window
title - text that needs to displayed as the title of the popup window
flags - annotation attributes
c - color of the polygon
isCloudy - whether the polygon edges needs to have a "cloudy" effect
cloudIntensity - Values specifying "cloudy" effect of polygon edges - 0 (straight line), 1 (cloudy) and 2 (more cloudy)
Throws:
IOException - if an I/O error occurs.
PdfException - if an illegal argument is supplied.

PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       String subject,
                       String contents,
                       String title)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(double[], String, String, String).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       String subject,
                       String contents,
                       String title)
                throws IOException,
                       PdfException
Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       String subject,
                       String contents,
                       String title,
                       Color c)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(double[], String, String, String, Color).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       String subject,
                       String contents,
                       String title,
                       Color c)
                throws IOException,
                       PdfException
Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       String subject,
                       String contents,
                       String title,
                       int flags)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(double[], String, String, String, int).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       String subject,
                       String contents,
                       String title,
                       int flags)
                throws IOException,
                       PdfException
Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       String subject,
                       String contents,
                       String title,
                       int flags,
                       Color c)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(PdfRect, String, String, String, int, Color).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       String subject,
                       String contents,
                       String title,
                       int flags,
                       Color c)
                throws IOException,
                       PdfException
Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       int flags)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(double[], int).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       int flags)
                throws IOException,
                       PdfException
Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       int flags,
                       Color c)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(double[], int, Color).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       int flags,
                       Color c)
                throws IOException,
                       PdfException
Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(PdfRect r,
                       Color c)
                throws IOException,
                       PdfException
Deprecated. Instead, use PdfPolygonAnnot(double[], Color).

Throws:
IOException
PdfException

PdfPolygonAnnot

public PdfPolygonAnnot(double[] vertices,
                       Color c)
                throws IOException,
                       PdfException
Constructs a polygon annotation with specified vertices and color.

Parameters:
vertices - x-y coordinates of the vertices
c - color of the polygon
Throws:
IOException - if an I/O error occurs.
PdfException - if an illegal argument is supplied.
Method Detail

clone

public Object clone()
Overrides:
clone in class PdfPolylineAnnot

isCloudy

public boolean isCloudy()
Returns whether border of the polygon annotation has a "cloudy" effect.

Returns:
true if border has a "cloudy" effect; false if otherwise.
See Also:
setCloudy(boolean), getCloudIntensity(), setCloudIntensity(int), PdfPolygonAnnot(PdfRect, String, String, String, int, Color, boolean, int)

setCloudy

public void setCloudy(boolean cloudy)
Specifies whether border of the polygon annotation needs to have a "cloudy" effect.

Parameters:
cloudy - true if border needs to have a "cloudy" effect; false if otherwise.
See Also:
isCloudy(), getCloudIntensity(), setCloudIntensity(int), PdfPolygonAnnot(PdfRect, String, String, String, int, Color, boolean, int)

getCloudIntensity

public int getCloudIntensity()
Returns value representing the intensity of the "cloudy" effect on edges of the polygon annotation.

Returns:
0 (straight line), 1 (cloudy) and 2 (more cloudy)
See Also:
setCloudIntensity(int), isCloudy(), setCloudy(boolean), PdfPolygonAnnot(PdfRect, String, String, String, int, Color, boolean, int)

setCloudIntensity

public void setCloudIntensity(int cloudIntensity)
Specifies value representing the intensity of the "cloudy" effect on edges of the polygon annotation.

Parameters:
cloudIntensity - 0 (straight line), 1 (cloudy) and 2 (more cloudy)
See Also:
getCloudIntensity(), isCloudy(), setCloudy(boolean), PdfPolygonAnnot(PdfRect, String, String, String, int, Color, boolean, int)

getPopup

public PdfPopUpAnnot getPopup()
Returns a popup annotation that needs to be used by a viewer application to display the popup window for this annotation.

Returns:
popup annotation that needs to be used as the popup window

setPopup

public 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.

Parameters:
popup - popup annotation that needs to be used as the popup window
overridePopUpProperties - whether a viewer application should override the properties of the popup annotation with those of this annotation
See Also:
getPopup()

getDownAppearance

public 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.

Returns:
appearance that needs to be displayed
See Also:
getNormalAppearance(), getDownAppearance(), setNormalAppearance(PdfAppearanceStream), setRolloverAppearance(PdfAppearanceStream), setDownAppearance(PdfAppearanceStream)

setDownAppearance

public 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.

See Also:
getNormalAppearance(), getDownAppearance(), getRolloverAppearance(), setNormalAppearance(PdfAppearanceStream), setRolloverAppearance(PdfAppearanceStream)

getNormalAppearance

public 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).

See Also:
getDownAppearance(), getRolloverAppearance(), setNormalAppearance(PdfAppearanceStream), setDownAppearance(PdfAppearanceStream), setRolloverAppearance(PdfAppearanceStream)

setNormalAppearance

public 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).

Parameters:
normalAppearance - the specified appearance stream
See Also:
setDownAppearance(PdfAppearanceStream), setRolloverAppearance(PdfAppearanceStream), getNormalAppearance(), getDownAppearance(), getRolloverAppearance()

getRolloverAppearance

public 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).

See Also:
getNormalAppearance(), getDownAppearance(), setNormalAppearance(PdfAppearanceStream), setDownAppearance(PdfAppearanceStream), setRolloverAppearance(PdfAppearanceStream)

setRolloverAppearance

public 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).

Parameters:
rolloverAppearance - the specified appearance stream
See Also:
setNormalAppearance(PdfAppearanceStream), setDownAppearance(PdfAppearanceStream), getNormalAppearance(), getDownAppearance(), getRolloverAppearance()

Gnostice PDFOne
Pro. Ed. v5.4

To contact our support team, send an e-mail to support@gnostice.com.
 
© 2015 Gnostice Information Technologies Private Limited. All rights reserved.
www.gnostice.com