Re: File Icon
Re: File Icon
- Subject: Re: File Icon
- From: Sam Goldman <email@hidden>
- Date: Mon, 05 Nov 2001 22:13:33 -0800
That depends where you put it. Normally, for NSImageCells, the default is
that it will scale for you. Now, of course you'll have to choose a suitable
size (icons only scale well to certain dimensions). If you look in the
NSImageCell docs it *should* (it's been a while) be a method where you
choose the scaling behavior.
Feel free to correct me if I am wrong.
- Sam
On 11/5/01 9:53 PM, "Joshua Clements" <email@hidden> wrote:
>
Thanks Finlay, for the pointer to NSWorkspace.
>
I've got that returning me an icon but it doesn't look
>
so hot at 16x16. I'm assuming that NSWorkspace is
>
returning me the 32x32 icon and the NSImageCell is
>
scaling it down to 16x16. Is there a way to get load the 16x16 icon?
>
>
>
On Sunday, November 4, 2001, at 02:56 PM, Finlay Dobbie wrote:
>
>
>
>
> On Sunday, November 4, 2001, at 07:45 pm, Joshua Clements wrote:
>
>
>
>> Anyone know how to get the icon associated with a file that can be
>
>> used in Cocoa?
>
>
>
> RTFM NSWorkspace.
>
>
>
>> I have located a function in Carbon "GetIconRefFromFile" which returns
>
>> an IconRef.
>
>> Is that IconRef usable in Cocoa for displaying on the screen?
>
>
>
> Yes, indirectly, but you should probably use the NSWorkspace method.
>
>
>
> -- Finlay
>
_______________________________________________
>
cocoa-dev mailing list
>
email@hidden
>
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
References: | |
| >Re: File Icon (From: Joshua Clements <email@hidden>) |