org.fife.ui.rtextfilechooser.filters
Class ImageFileFilter

java.lang.Object
  extended byjavax.swing.filechooser.FileFilter
      extended byorg.fife.ui.rtextfilechooser.filters.ImageFileFilter

public class ImageFileFilter
extends javax.swing.filechooser.FileFilter

A file filter for JFileChoosers that filters everything except image files supported by Swing (*.gif, *.jpg, *.png, and *.bmp (on 1.5+)).

Version:
1.0
Author:
Robert Futrell

Constructor Summary
ImageFileFilter()
          Constructor.
 
Method Summary
 boolean accept(java.io.File f)
          Accepts all gif, jpg, and png image files.
 java.lang.String getDescription()
          Returns the description of this file filter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ImageFileFilter

public ImageFileFilter()
Constructor.

Method Detail

accept

public boolean accept(java.io.File f)
Accepts all gif, jpg, and png image files.

Parameters:
f - The file to check.
Returns:
Whether the file is an image file.

getDescription

public java.lang.String getDescription()
Returns the description of this file filter.

Returns:
The description.