java.lang.Object
org.jibble.epsgraphics.EpsDocument
This represents an EPS document. Several EpsGraphics2D objects may point
to the same EpsDocument.
Copyright Paul Mutton, http://www.jibble.org/
-
Constructor Summary
ConstructorDescriptionEpsDocument
(String title) Constructs an empty EpsDevice.EpsDocument
(String title, OutputStream outputStream, int minX, int minY, int maxX, int maxY) Constructs an empty EpsDevice that writes directly to a file. -
Method Summary
Modifier and TypeMethodDescriptionvoid
append
(EpsGraphics2D g, String line) Appends a line to the EpsDocument.void
close()
void
flush()
getTitle()
Returns the title of the EPS document.boolean
void
setClipSet
(boolean isClipSet) void
updateBounds
(double x, double y) Updates the bounds of the current EPS document.void
Outputs the contents of the EPS document to the specified Writer, complete with headers and bounding box.
-
Constructor Details
-
EpsDocument
Constructs an empty EpsDevice. -
EpsDocument
public EpsDocument(String title, OutputStream outputStream, int minX, int minY, int maxX, int maxY) throws IOException Constructs an empty EpsDevice that writes directly to a file. Bounds must be set before use.- Throws:
IOException
-
-
Method Details
-
getTitle
Returns the title of the EPS document. -
updateBounds
public void updateBounds(double x, double y) Updates the bounds of the current EPS document. -
append
Appends a line to the EpsDocument. A new line character is added to the end of the line when it is added. -
write
Outputs the contents of the EPS document to the specified Writer, complete with headers and bounding box.- Throws:
IOException
-
flush
- Throws:
IOException
-
close
- Throws:
IOException
-
isClipSet
public boolean isClipSet() -
setClipSet
public void setClipSet(boolean isClipSet)
-