• 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: Simple Question: Get NSString of the file name in an NSImage
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Simple Question: Get NSString of the file name in an NSImage


  • Subject: Re: Simple Question: Get NSString of the file name in an NSImage
  • From: Clark Cox <email@hidden>
  • Date: Tue, 14 Sep 2004 11:49:08 -0400

On Sun, 14 Sep 2003 07:50:14 -0700, Steven Harms <email@hidden> wrote:
> I have an NSImageView subclass that returns the NSImage that it is using
> if sent the message image:.
>
> But, I want that NSImage's name as a string (the NSImage will allways be
> one of the Resource files).  It's much less disk.expensive for me to
> archive the image names than the image data, so i would prefer to find
> out the name value, as an NSString.

And it never occured to you to look at the header or the NSImage documentation?

>From <http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/ObjC_classic/Classes/NSImage.html#//apple_ref/doc/uid/20000344/name>:

"- (NSString *)name
Returns the name assigned to the receiver, or nil if no name has been assigned."


--
Clark S. Cox III
email@hidden
http://www.livejournal.com/users/clarkcox3/
http://homepage.mac.com/clarkcox3/
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: controlTextDidChange, backspace possible?
  • Next by Date: Creating Help for my App.
  • Previous by thread: Re: Country codes vs. Language codes
  • Next by thread: Creating Help for my App.
  • Index(es):
    • Date
    • Thread