diff -r 608f976aa7bb -r 9aadd0f58300 file.cpp --- a/file.cpp Tue Jun 06 14:58:11 2006 +0000 +++ b/file.cpp Tue Aug 15 11:42:10 2006 +0000 @@ -303,3 +303,38 @@ } } +ImageIO::ImageIO () +{ + // Create list with supported image types + // foreach (QByteArray format, QImageWriter::supportedImageFormats()) + // imageTypes.append( tr("%1...").arg(QString(format).toUpper())); + imageFilters.append ("Images (*.png *.jpg *.jpeg *.bmp *.bmp *.ppm *.xpm *.xbm)"); + imageTypes.append ("PNG"); + imageFilters.append ("Portable Network Graphics (*.png)"); + imageTypes.append ("PNG"); + imageFilters.append ("Joint Photographic Experts Group (*.jpg)"); + imageTypes.append ("JPG"); + imageFilters.append ("Joint Photographic Experts Group (*.jpeg)"); + imageTypes.append ("JPG"); + imageFilters.append ("Windows Bitmap (*.bmp)"); + imageTypes.append ("BMP"); + imageFilters.append ("Portable Pixmap (*.ppm)"); + imageTypes.append ("PPM"); + imageFilters.append ("X11 Bitmap (*.xpm)"); + imageTypes.append ("XPM"); + imageFilters.append ("X11 Bitmap (*.xbm)"); + imageTypes.append ("XBM"); +} + +QStringList ImageIO::getFilters() +{ + return imageFilters; +} + +QString ImageIO::getType(QString filter) +{ + for (int i=0;i