Matthias Miller schrieb:
> Windows Vista is not displaying my application icon correctly. If I
> create a shortcut, it shows the correct icon in the "Choose Icon"
> dialog, but Explorer shows the generic Windows application icon for the
> shortcut. I have found that changing the sublanguage for the icon to
> SUBLANG_DEFAULT resolves the issue. This seems like a sane value, but I
> cannot tell from the documentation whether this is the correct solution.
> The documentation is a bit sketchy at best (see
As usual :-(.
> I have attached a patch with my change. Is there a better way to solve
> this issue?
RCS file: /cvsroot/py2exe/py2exe/source/py2exe_util.c,v
retrieving revision 1.14
diff -r1.14 py2exe_util.c
< MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL),
> MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
I cannot (easily) test on vista. Are you sure that this patch fixes the issue?
Looking at the code, the above patch changes the langid in the 'add_resource' function,
not in the 'add_icon' function. How are you creating the application icon?
However, for maximum flexibility the py2exe_util functions could probably be changed
to take the langid as an additional, optional parameter, defaulting to what we have now.
At least this would make experimenting with different values easier, without having
to rebuild the extension.