public class SVGSaveDialog extends Object
Modifier and Type | Field and Description |
---|---|
(package private) static String |
automagic_format
Automagic file format
|
static String |
DEFAULT_TITLE
The default title.
|
(package private) static String[] |
formats
Supported file format (extensions)
|
private static Logging |
logger
Static logger reference
|
(package private) static String[] |
visibleformats
Visible file formats
|
Constructor and Description |
---|
SVGSaveDialog() |
Modifier and Type | Method and Description |
---|---|
static String[] |
getFormats() |
static String[] |
getVisibleFormats() |
static String |
guessFormat(String name)
Guess a supported format from the file name.
|
private static void |
showError(Component parent,
String title,
String msg)
Helper method to show a error message as "popup".
|
static int |
showSaveDialog(SVGPlot plot,
int width,
int height)
Show a "Save as" dialog.
|
public static final String DEFAULT_TITLE
private static final Logging logger
static final String automagic_format
static final String[] formats
static final String[] visibleformats
public static int showSaveDialog(SVGPlot plot, int width, int height)
plot
- The plot to be exported.width
- The width of the exported image (when export to JPEG/PNG).height
- The height of the exported image (when export to JPEG/PNG).JFileChooser.showSaveDialog(java.awt.Component)
public static String guessFormat(String name)
name
- File namepublic static String[] getFormats()
public static String[] getVisibleFormats()
private static void showError(Component parent, String title, String msg)
JOptionPane.showMessageDialog(java.awt.Component, Object)
.parent
- The parent component for the popup.msg
- The message to be displayed.