- NSIS Discussion
- "icon size mismatch" again and again...
Archive: "icon size mismatch" again and again...
DropF
23rd October 2003 10:10 UTC
"icon size mismatch" again and again...
Hi,
When I try to compile my installer, I got this error message:
Error finding icon resources: installer, uninstaller icon size mismatch - see the Icon instruction's documentation for more information -- failing!
Error - aborting creation process
I've read all the topics I've found about this subject, but no one got my solution. Indeed, my problem is that my installer icon has the same formats of my uninstaller icon, and both got a size of 23,558 bytes.
My uninstaller icon is the file ${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall-full.ico. And here I join my installer icon. And I'm using the latest CVS version of NSIS (updated with the NSIS Update tool).
Thank you for your help ;)
kichik
23rd October 2003 11:46 UTC
Your installer icon and uninstaller icon doesn't have the same order of internal icons.
I will think about this and see if there is a reason for this requirement. If there isn't, I'll remove it.
DOCa Cola
23rd October 2003 11:48 UTC
why is this requirement for same icon size in nsis anyway?
kichik
23rd October 2003 11:54 UTC
Because including a resource editor in the installer is a waste of space and so is including a full exeheader for the uninstaller.
DOCa Cola
23rd October 2003 19:17 UTC
ah, good idea, so you are using basicly the same header for the installer and uninstaller, right? :)
Joel
23rd October 2003 22:40 UTC
Try with this :)
DropF
23rd October 2003 23:02 UTC
Works fine with those icons. Thanks.
But what changes did you do??
Joel
24th October 2003 00:21 UTC
Two things:
1. Same size
2. Same color depth.
:D
BTW: Your welcome ;)
DropF
24th October 2003 09:26 UTC
But that's what I did :eek: : the both icons got the same size and the same color depth. But Kichik said:
Your installer icon and uninstaller icon doesn't have the same order of internal icons.
So how did you put those icons in the same order?
Joost Verburg
24th October 2003 12:43 UTC
I think most icon editors use the same order when resaving the files.
DropF
24th October 2003 21:29 UTC
Originally posted by Joost Verburg
I think most icon editors use the same order when resaving the files.
In fact, I only need to resave each icon to reorder the icons in the .ico files, that's it?
Joost Verburg
24th October 2003 22:05 UTC
I don't know. It probably depends on the icon editor. You will have to try.
Joel
26th October 2003 01:33 UTC
Joost It's right. You must save your icon structures with the same
Icon editor. Try to save'em with Microangelo, AW Icons, etc..
kichik
8th December 2003 09:33 UTC
Latest CVS version should not care about the order anymore. Note that I have not uploaded a compiled version yet.
lewellyn
9th December 2003 03:35 UTC
Keep in mind that the icon order is important if you're including certain icon sizes. Most good icon editors will automatically take care of this for you. (I use IconBuilder from www.iconfactory.com.)
Of particular note is (if I remember correctly...) 48x48 @ 16 colors. On most versions of Windows, if this icon size isn't in the correct location, no icons will show at all...
Also, if you care about size, proper ordering of the icons will reduce the total size of the icon file. I've never understood this, but have verified it numerous times with various editors. Just find some old, free editor to save a few icons. Then re-save the file with a "good" editor. Sometimes the results are amazing. (But usually nothing to write home about...)
Just my $0.02.
Joost Verburg
9th December 2003 19:05 UTC
NSIS needs installer and uninstaller icons with the same size because it has to overwrite the installer icon data with the uninstaller data and including a resource editor is a waste of size.
There is no reason for NSIS to care about the order, because it is possible to have totally correct icons with different orders.
The ICO format can contain icon in any order. I don't know about limitations in old Windows versions, but it's up to the user to handle these things.
lewellyn
9th December 2003 20:20 UTC
I agree with Joost's assessment. Just wanted to make note of a pitfall that many people come across (even if they don't notice...). In fact, you can go out and buy a few of our CDs and see the effects... :cry:
By forcing the user to keep the order the same makes it more likely that they have re-saved the icons with an editor recently. And most semi-recent editors will save in the proper order. (Even 2000 and XP have issues with out-of-order icons...)
Anyway, the requirement is fairly arbitrary it seems. I, personally, haven't seen that error in quite a while. So it affects me not. Just babbling on... ;)
--Matt
Joost Verburg
9th December 2003 21:21 UTC
Forcing the user to use icons with the same image order does not guarantee that the order is correct.
The ICO format does not contain any order requirements. Can you provide me with a link about Windows issues with icon order?
lewellyn
9th December 2003 21:51 UTC
Well, aside from the well-known "Don't include 24x24" and "1-bit icons are unnecessary" issues, the only thing I have at-hand is a PDF document that came with IconBuilder... I'll attach it in another message. Unfortunately, when I upgraded to XP, I lost my bookmarks (including all of my icon resources). If someone is suitably bored and ambitious, hopefully they can find the docs on either Google or Microsoft's site. I've found the info in both places... It's just a matter of finding the proper search terms, which I don't have time for at the moment.
--Matt
lewellyn
9th December 2003 22:00 UTC
Bah.
You can't attach to a previous post... Anyway, attached is the PDF. The note about 48x48x16 is on the last page. It also doesn't affect the newest versions of IconBuilder, so this is primarily of historical interest to me. They had a release note at one point saying that they rearranged the icon order to make it work...