[Mono-osx] System.Windows.Forms.XplatUIOSX:SetIcon not implemented
kangaroo
grompf at sublimeintervention.com
Wed May 25 22:18:16 EDT 2005
On 25-May-05, at 10:13 PM, Troy Phillips wrote:
> On 26/5/05 12:27 AM, "millenomi aka l0ne" <millenomi at gmail.com> wrote:
>
>> Il giorno 25/mag/05, alle ore 12:12, Troy Phillips ha scritto:
>>
>>
>>> Since OS X doesn’t really have window icons, I thought that SetIcon
>>> should be ignored on OS X rather than throw a “not implemented”
>>> error. The only alternative that springs to mind is to alter the
>>> dock icon but I think that this would not look good?
>>>
>>
>> OS X does have window icons, although it's not good form to modify
>> them for they are document proxies. The use of one suggests that the
>> window is tied to a document -- an abstraction .NET does not have.
>>
>
> Wow - I am surprised that I never noticed that. I am looking around
> and
> noticing them in lots of applications now (Finder, Office,
> TextWrangler -
> all the applications that interact with file system objects)
>
Document icons != window icons; window icons should be the dock icon
(if I remember the api correctly)
>
>> Cocoa does not expose APIs to modify window icons directly. Carbon
>> should have this (quartz-wm uses them to mark X11 windows, for
>> instance) but I don't know if the two things are integrated.
>>
>
> I found a posting (refer
> http://mozdev.org/pipermail/camino/2003-July/000071.html) that
> implies that
> you could get a handle to use the Carbon API (refer
> http://developer.apple.com/documentation/Carbon/Reference/
> Window_Manager/win
> d_mgr_ref/chapter_1.2_section_10.html#//apple_ref/doc/uid/
> TP30000176-DontLin
> kChapterID_2-F09074) - but as you say this would probably be
> considered bad
> form.
>
>
>> I'm all
>> for stubbing it out to an empty subroutine, but there might be
>> reasons for this not to be true, although I can't think of any.
>>
>
> My vote is to stub to an empty subroutine
>
Well; thats not my vote because I'll forget to implement it then.
Thats why these things throw exceptions so people whine and they come
to my attention as needed.
Would you care to send a patch that sets the dock icon in that case;
and if I change the behvaiour later to a document icon we can still
sue the dock code elsewhere?
>
>> There's also NSWindow's -setMiniwindowImage:, which sets the image to
>> use as a Dock representation when the window is minimized (see
>> iChat's windows).
>>
>
> Personally I don't think that would be a good fit in general.
>
It wont be a fit at all as we dont have any Cocoa in MWF
-kangaroo
More information about the Mono-osx
mailing list