[wxpython-mac] Transparent systray icon in the Mac OS X dock
Cody Precord
codyprecord at gmail.com
Fri Jun 27 17:07:08 PDT 2008
Hello,
On Jun 26, 2008, at 6:25 PM, Gros Bedo wrote:
>
>
> Here's my code:
>
> icon = wx.Icon ('icon.ico', wx.BITMAP_TYPE_ANY)
> self.tbicon.SetIcon (icon, sTip)
> wx.EVT_TASKBAR_LEFT_UP (self.tbicon, self.OnTaskBarActivate)
>
> I've tried many changes in Main.py to include my own icon, but
> without any success, I can't even manage to show it. For the second
> problem, I've put some code in self.OnTaskBarActivate to show the
> form, but it seems this function is never called on Mac OS X. Do I
> have to use another event to catch left click ?
>
> My testing environment is Mac OS X 10.5 Leopard. I hope someone will
> be able to guide me for this problem, as after this my port will be
> finished ! :-)
What size is your icon? I think that only some "native" sizes are
supported on Mac or some scaling might take place and cause you to
loose the alpha channel. If you icon is not (64x64, 128x128), you
might want to try one with one of those sizes.
Also I am not sure how well using .ico files works under mac you might
have better luck with a .png image.
Hope this helps, otherwise if you can provide a small runnable sample
to test with I can check it out.
Cody
More information about the wxpython-mac
mailing list