Hi,
Check out the source code for
Win32::Exe
Win32::Exe::IconFile
Win32::Exe::Resource::Icon;
Win32::Exe::Resource::GroupIcon;
Instead of specifying '-icon' as a param to pp, you should be able to figure
out how to add icons with specific id's after you have built the exec.
untested, but looks something like following should work:
# get icons from an iconfile
my @icons = Win32::Exe::IconFile->new($iconfile)->icons;
# @icons = array of Win32::Exe::Resource::Icon objects
# reorder @icons setting Id of each one
my $exe = Win32::Exe->new($execfile);
$exe->set_icons([EMAIL PROTECTED]).
To repeat, untested so the correct approach may not be exactly as above.
Mark
John wrote:
Philippe Schaffnit wrote:
Hi!
I haven't managed either exactly what you are attempting (though I would
be really interested!), but a fairly painless workaround (which I
actually use), is to pack the icon additionally with '--addfile', and
get it from there afterwards (it's messy, but the file is tiny
anyway...).
Good luck!
Philippe
Thank you Phillipe
I eventually came up with that idea as well. May be someone else will
chip in with a response and we will both learn something new.
John
John wrote:
Hi
I am packaging a Win32::GUI app with:
pp -i myicon.ico -M Math::Trig -M Win32::GUI -M Win32::GUI::Grid -g -o
b.exe guess1.plw
in my app Iam using:
my $icon = new Win32::GUI::Icon(105);
$main->ChangeIcon($icon);
to access and set my apps title bar icon. Looking in the packaged app
with a resource editor myicon appears as 101. When I use that number in
the statement above (currently 105) I get a camel. Changing that number
I get a variety of other icons but not the one I want.
Could someone please suggest how I might achieve what I want and
possibly explain what is happening. As I write this I think that the
camel icon is coming from parl.exe which I understand to be part of the
executable component of the package.
--
Regards
John McMahon
[EMAIL PROTECTED]