|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JFileChooser
jwo.landserf.gui.LSFileChooser
public class LSFileChooser
Creates a customised file chooser with appropriate filters and iconic representation of files.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.JFileChooser |
|---|
JFileChooser.AccessibleJFileChooser |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary |
|---|
| Fields inherited from class javax.swing.JComponent |
|---|
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
LSFileChooser()
Creates a customisable file chooser. |
|
LSFileChooser(int type)
Creates a customisable file chooser for selecting files of a particular type. |
|
| Method Summary | |
|---|---|
int |
getFileType()
Reports the type of file chosen by the user. |
File |
getSelectedFile()
Returns the selected file. |
void |
setDefaultOpenTypes()
Sets the default file types visible for opening with this chooser. |
void |
setDefaultSaveTypes(boolean includeRaster,
boolean includeVector,
boolean includeImage)
Sets the default file types visible for saving with this chooser. |
void |
setFileTypes(int[] types)
Sets the types of file that are choosable. |
void |
storeLastDirectory()
Saves the current directory in the LandSerf properties file. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public LSFileChooser()
public LSFileChooser(int type)
type - Type of file to select (see FileHandler for possible types).FileHandler| Method Detail |
|---|
public int getFileType()
FileHandlerpublic void setFileTypes(int[] types)
types - Array of file types that are choosable.public void setDefaultOpenTypes()
public void setDefaultSaveTypes(boolean includeRaster,
boolean includeVector,
boolean includeImage)
includeRaster - Raster formats included if true.includeVector - Vector formats included if true.includeImage - Image formats included if true.public void storeLastDirectory()
public File getSelectedFile()
setFile
or by a user action, such as either typing the filename into the UI or selecting the file from
a list in the UI. This version forces all files to have an appropriate file extension.
getSelectedFile in class JFileChooser
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||