|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectweka.gui.visualize.JComponentWriter
weka.gui.visualize.PostscriptWriter
public class PostscriptWriter
This class takes any Component and outputs it to a Postscript file.
Note:
This writer does not work with Components that rely on clipping, like e.g.
scroll lists. Here the complete list is printed, instead of only in the
borders of the scroll list (may overlap other components!). This is due to
the way, clipping is handled in Postscript. There was no easy way around
this issue. :-(
PostscriptGraphics
Constructor Summary | |
---|---|
PostscriptWriter()
initializes the object |
|
PostscriptWriter(javax.swing.JComponent c)
initializes the object with the given Component |
|
PostscriptWriter(javax.swing.JComponent c,
java.io.File f)
initializes the object with the given Component and filename |
Method Summary | |
---|---|
java.lang.String |
getDescription()
returns the name of the writer, to display in the FileChooser. |
java.lang.String |
getExtension()
returns the extension (incl. |
static void |
main(java.lang.String[] args)
for testing only |
void |
toOutput()
saves the current component to the currently set file |
static void |
toOutput(javax.swing.JComponent c,
java.io.File f)
outputs the given component as Postscript in the specified file |
Methods inherited from class weka.gui.visualize.JComponentWriter |
---|
getComponent, getFile, getScalingEnabled, getXScale, getYScale, setComponent, setFile, setScale, setScalingEnabled |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PostscriptWriter()
public PostscriptWriter(javax.swing.JComponent c)
c
- the component to print in the output formatpublic PostscriptWriter(javax.swing.JComponent c, java.io.File f)
c
- the component to print in the output formatf
- the file to store the output inMethod Detail |
---|
public java.lang.String getDescription()
getDescription
in class JComponentWriter
public java.lang.String getExtension()
getExtension
in class JComponentWriter
public static void toOutput(javax.swing.JComponent c, java.io.File f) throws java.lang.Exception
c
- the component to print in the output formatf
- the file to store the output in
java.lang.Exception
- if component of file are null
public void toOutput() throws java.lang.Exception
toOutput
in class JComponentWriter
java.lang.Exception
- if component of file are null
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |