• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSOpenPanel and JPG files
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSOpenPanel and JPG files


  • Subject: Re: NSOpenPanel and JPG files
  • From: Nicko van Someren <email@hidden>
  • Date: Mon, 26 Apr 2004 14:29:59 +0100

On 26 Apr 2004, at 13:17, Mary Waller wrote:

I can't get an NSOpenPanel to allow me to select .JPG files, although all the other types I specify are OK.
What am I doing wrong? (OS X 10.28 and OS X 10.3)

NSArray *fileTypes = [NSArray arrayWithObjects:@"jpg",@"JPG",@"png",@"bmp",@"tif", nil];

Looking at the values in the list coming back from [NSImage imageFileTypes] you might want to add, "jpeg", "JPEG" and "'JPEG'". I think that last one has something to do with the file type being set in the old fashioned manner rather than with a file name extension. Alternatively, if you simply want to be able to load all sorts of image you can just use the value returned by [NSImage imageFileTypes] rather than building your own array.

Cheers,

Nicko
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: NSOpenPanel and JPG files
      • From: Mary Waller <email@hidden>
References: 
 >NSOpenPanel and JPG files (From: Mary Waller <email@hidden>)

  • Prev by Date: NSCombobox delay in updation of selection!!
  • Next by Date: Re: NSTableView and multiple NSArrayControllers
  • Previous by thread: NSOpenPanel and JPG files
  • Next by thread: Re: NSOpenPanel and JPG files
  • Index(es):
    • Date
    • Thread