PDF Clown
0.1.2

org.pdfclown.documents.interaction.annotations
Class Line

java.lang.Object
  extended by org.pdfclown.objects.PdfObjectWrapper<PdfDictionary>
      extended by org.pdfclown.documents.interaction.annotations.Annotation
          extended by org.pdfclown.documents.interaction.annotations.Line
All Implemented Interfaces:
Cloneable, ILayerable, IPdfObjectWrapper

@PDF(value=PDF13)
public final class Line
extends Annotation

Line annotation [PDF:1.6:8.4.5].

It displays displays a single straight line on the page. When opened, it displays a pop-up window containing the text of the associated note.

Since:
0.0.7
Version:
0.1.2, 12/21/12
Author:
Stefano Chizzolini (http://www.stefanochizzolini.it)

Nested Class Summary
static class Line.LineEndStyleEnum
          Line ending style [PDF:1.6:8.4.5].
 
Nested classes/interfaces inherited from class org.pdfclown.documents.interaction.annotations.Annotation
Annotation.FlagsEnum
 
Constructor Summary
Line(Page page, Point2D startPoint, Point2D endPoint, String text)
           
 
Method Summary
 Line clone(Document context)
          Gets a clone of the object, registered inside the given document context.
 Point2D getEndPoint()
          Gets the ending coordinates.
 Line.LineEndStyleEnum getEndStyle()
          Gets the style of the ending line ending.
 DeviceRGBColor getFillColor()
          Gets the color with which to fill the interior of the annotation's line endings.
 double getLeaderLineExtensionLength()
          Gets the length of leader line extensions that extend in the opposite direction from the leader lines.
 double getLeaderLineLength()
          Gets the length of leader lines that extend from each endpoint of the line perpendicular to the line itself.
 Point2D getStartPoint()
          Gets the starting coordinates.
 Line.LineEndStyleEnum getStartStyle()
          Gets the style of the starting line ending.
 boolean isCaptionVisible()
          Gets whether the contents should be shown as a caption.
 void setCaptionVisible(boolean value)
           
 void setEndPoint(Point2D value)
           
 void setEndStyle(Line.LineEndStyleEnum value)
           
 void setFillColor(DeviceRGBColor value)
           
 void setLeaderLineExtensionLength(double value)
           
 void setLeaderLineLength(double value)
           
 void setStartPoint(Point2D value)
           
 void setStartStyle(Line.LineEndStyleEnum value)
           
 
Methods inherited from class org.pdfclown.documents.interaction.annotations.Annotation
delete, getAction, getActions, getAppearance, getBorder, getBox, getColor, getFlags, getLayer, getModificationDate, getName, getPage, getText, isPrintable, isVisible, setAction, setActions, setAppearance, setBorder, setBox, setColor, setFlags, setLayer, setModificationDate, setName, setPrintable, setText, setVisible, wrap
 
Methods inherited from class org.pdfclown.objects.PdfObjectWrapper
checkCompatibility, equals, exists, getBaseDataObject, getBaseObject, getBaseObject, getContainer, getDataContainer, getDocument, getFile, getMetadata, retrieveName, retrieveNamedBaseObject, setBaseObject, setMetadata
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Line

public Line(Page page,
            Point2D startPoint,
            Point2D endPoint,
            String text)
Method Detail

clone

public Line clone(Document context)
Description copied from class: PdfObjectWrapper
Gets a clone of the object, registered inside the given document context.

Overrides:
clone in class Annotation
Parameters:
context - Which document the clone has to be registered in.

getEndPoint

public Point2D getEndPoint()
Gets the ending coordinates.


getEndStyle

public Line.LineEndStyleEnum getEndStyle()
Gets the style of the ending line ending.


getFillColor

public DeviceRGBColor getFillColor()
Gets the color with which to fill the interior of the annotation's line endings.


getLeaderLineExtensionLength

public double getLeaderLineExtensionLength()
Gets the length of leader line extensions that extend in the opposite direction from the leader lines.


getLeaderLineLength

public double getLeaderLineLength()
Gets the length of leader lines that extend from each endpoint of the line perpendicular to the line itself.

A positive value means that the leader lines appear in the direction that is clockwise when traversing the line from its starting point to its ending point; a negative value indicates the opposite direction.


getStartPoint

public Point2D getStartPoint()
Gets the starting coordinates.


getStartStyle

public Line.LineEndStyleEnum getStartStyle()
Gets the style of the starting line ending.


isCaptionVisible

public boolean isCaptionVisible()
Gets whether the contents should be shown as a caption.


setCaptionVisible

public void setCaptionVisible(boolean value)
See Also:
isCaptionVisible()

setEndPoint

public void setEndPoint(Point2D value)
See Also:
getEndPoint()

setEndStyle

public void setEndStyle(Line.LineEndStyleEnum value)
See Also:
getEndStyle()

setFillColor

public void setFillColor(DeviceRGBColor value)
See Also:
getFillColor()

setLeaderLineExtensionLength

public void setLeaderLineExtensionLength(double value)
See Also:
getLeaderLineExtensionLength()

setLeaderLineLength

public void setLeaderLineLength(double value)
See Also:
getLeaderLineLength()

setStartPoint

public void setStartPoint(Point2D value)
See Also:
getStartPoint()

setStartStyle

public void setStartStyle(Line.LineEndStyleEnum value)
See Also:
getStartStyle()

PDF Clown
0.1.2

Project home page

Copyright © 2006-2013 Stefano Chizzolini. Some Rights Reserved.
This documentation is available under the terms of the GNU Free Documentation License.