• 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: Human readable file type?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Human readable file type?


  • Subject: Re: Human readable file type?
  • From: Nathan Day <email@hidden>
  • Date: Mon, 8 Jul 2002 01:35:35 +0930

Use launch service, there is a simple wrapper class for launch service on my iTools web site, though it's pretty easy to call the function directly.

LSCopyKindStringForURL( (CFURLRef)aURL, (CFStringRef *)&theKind )

you can pass an NSURL and return a NSString

http://homepage.mac.com/nathan_day/

On Sunday, July 7, 2002, at 10:17 PM, Allan Odgaard wrote:

I need to display a human readable filetype, similar to how the "Show Info" of the Finder does (e.g. "MP3 Audio File").

I have not been able to figure out where this is stored, other than use NSWorkspace's getInfoForFile and then look in the Info.plist of the application which opens the file (to read the CFBundleTypeName property), but this is really hacky (and I'm not sure Info.plist is the only place that the supported filetypes of an app can be stored).
_______________________________________________
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.

References: 
 >Human readable file type? (From: Allan Odgaard <email@hidden>)

  • Prev by Date: Re: [solved, really!] Re: Human readable file type?
  • Next by Date: Re: Preview in Internet Explorer
  • Previous by thread: [solved, but a little dirty] Re: Human readable file type?
  • Next by thread: NSMenuItem separatorItem -- default spacing?
  • Index(es):
    • Date
    • Thread