PDF4Java Reference Documentation
com.o2sol.pdf4java.annotations Package / PDFAnnotationBorder Class / setColor Method
A com.o2sol.pdf4java.graphics.colors.PDFColor object specifying the color with which to stroke the annotation's border.
Collapse All Expand All
In This Topic

setColor Method
In This Topic
Sets the border color.
The border color must be RGB, CMYK or Gray.
Syntax

    public void setColor(
       PDFColor value
    )

#### Parameters

value
  A com.o2sol.pdf4java.graphics.colors.PDFColor object specifying the color with which to stroke the annotation's border.

Exceptions

Exception | Description
--- | ---
java.lang.IllegalArgumentException | Thrown when the property is set to a color other than Gray, RGB or CMYK.

See Also

#### Reference

PDFAnnotationBorder Class
PDFAnnotationBorder Members

© 2025 O2 Solutions All Rights Reserved.

Send comments on this topic.