wx.IconBundleFromFile seems to work only with icon resource files. Is
there a way to retrieve a wx.IconBundle-like object from an executable
file?
Thanks in advance,
-- tacao
No bits were harmed during the making of this e-mail.
wx.IconBundleFromFile seems to work only with icon resource files. Is
there a way to retrieve a wx.IconBundle-like object from an executable
file?
Thanks in advance,
-- tacao
No bits were harmed during the making of this e-mail.
E. A. Tacao wrote:
wx.IconBundleFromFile seems to work only with icon resource files. Is
there a way to retrieve a wx.IconBundle-like object from an executable
file?
I think you need to use wx.IconLocation to get the icons out of the .exe file, and then add them to a wx.IconBundle yourself.
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
Thursday, December 22, 2005, 4:08:49 PM, Robin Dunn wrote:
E. A. Tacao wrote:
wx.IconBundleFromFile seems to work only with icon resource files.
Is there a way to retrieve a wx.IconBundle-like object from an
executable file?I think you need to use wx.IconLocation to get the icons out of the
.exe file, and then add them to a wx.IconBundle yourself.
It doesn't seem to work. It seems that I can only add wx.Icons to a
wx.IconBundle, not wx.IconLocations. I also couldn't create an icon
from a wx.IconLocation.
I need to populate a TreeCtrl with some exe filenames read from disk,
and I'd like them to be displayed with their icons. The icons should
be 16x16 so my problem is how to retrieve the 16x16 icons that
might be embedded into an executable file.
-- tacao
No bits were harmed during the making of this e-mail.
E. A. Tacao wrote:
Thursday, December 22, 2005, 4:08:49 PM, Robin Dunn wrote:
E. A. Tacao wrote:
wx.IconBundleFromFile seems to work only with icon resource files.
Is there a way to retrieve a wx.IconBundle-like object from an
executable file?I think you need to use wx.IconLocation to get the icons out of the
.exe file, and then add them to a wx.IconBundle yourself.It doesn't seem to work. It seems that I can only add wx.Icons to a
wx.IconBundle, not wx.IconLocations. I also couldn't create an icon
from a wx.IconLocation.I need to populate a TreeCtrl with some exe filenames read from disk,
and I'd like them to be displayed with their icons. The icons should
be 16x16 so my problem is how to retrieve the 16x16 icons that
might be embedded into an executable file.-- tacao
No bits were harmed during the making of this e-mail.
---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
E. A. Tacao wrote:
Thursday, December 22, 2005, 4:08:49 PM, Robin Dunn wrote:
E. A. Tacao wrote:
wx.IconBundleFromFile seems to work only with icon resource files.
Is there a way to retrieve a wx.IconBundle-like object from an
executable file?I think you need to use wx.IconLocation to get the icons out of the
.exe file, and then add them to a wx.IconBundle yourself.It doesn't seem to work. It seems that I can only add wx.Icons to a
wx.IconBundle, not wx.IconLocations. I also couldn't create an icon
from a wx.IconLocation.
Something like this:
loc = wx.IconLocation(name, idx)
icon = wx.IconFromLocation(loc)
The second line converts from a wx.IconLocation to a wx.Icon.
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
Friday, December 23, 2005, 12:43:49 AM, Robin Dunn wrote:
Something like this:
loc = wx.IconLocation(name, idx)
icon = wx.IconFromLocation(loc)
The second line converts from a wx.IconLocation to a wx.Icon.
Yes, that gives me the application icon, but allows me to retrieve
only the 32x32 icon. I thought about using wx.IconBundle because it
allows me to select icons by size, but unfortunately it only reads
icon resource files.
-- tacao
No bits were harmed during the making of this e-mail.
E. A. Tacao wrote:
Friday, December 23, 2005, 12:43:49 AM, Robin Dunn wrote:
Something like this:
loc = wx.IconLocation(name, idx)
icon = wx.IconFromLocation(loc)The second line converts from a wx.IconLocation to a wx.Icon.
Yes, that gives me the application icon, but allows me to retrieve
only the 32x32 icon. I thought about using wx.IconBundle because it
allows me to select icons by size, but unfortunately it only reads
icon resource files.
But you can also add your own wx.Icons to the bundle, so presuming you can get the multiple sizes of the icon somehow then you can make a bundle that does what you are wanting.
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
Friday, December 23, 2005, 5:24:01 PM, Robin Dunn wrote:
But you can also add your own wx.Icons to the bundle, so presuming
you can get the multiple sizes of the icon somehow then you can make
a bundle that does what you are wanting.
Thanks, things are getting clearer now. And i've just realized what
are the desiredWidth/Height params for. 8^)
-- tacao
No bits were harmed during the making of this e-mail.