Nico, I had a look at the document icon script and have some comments: I had two problems getting the script to work (mostly my fault, but anyway):
1. If the vim-noshadow-512.png file is missing the following is logged
Traceback (most recent call last):
File "make_icons.py", line 159, in <module>
main()
File "make_icons.py", line 148, in main
createIcon(TMPFILE, NSString.stringWithString_(text))
File "make_icons.py", line 108, in createIcon
icon.drawInRect_fromRect_operation_fraction_(
AttributeError: 'NoneType' object has no attribute
'drawInRect_fromRect_operation_fraction_'
...it would probably be nicer with a "File missing" warning. It took
me a while to figure out what the problem was (despite you having
stated this clearly in your post...yes, I can be a bit slow). ;-)
2. The "LucidaSans-Demi" does not exist on my system. Again, if the
font is missing you get an unhelpful message:
2008-11-30 16:03:35.751 Python[615:613] *** -[NSNull
screenFontWithRenderingMode:]: unrecognized selector sent to instance
0xa0018020
Traceback (most recent call last):
File "make_icons.py", line 159, in <module>
main()
File "make_icons.py", line 148, in main
createIcon(TMPFILE, NSString.stringWithString_(text))
File "make_icons.py", line 111, in createIcon
text.drawInRect_withAttributes_( ((0.5, 23.5), (511, 120)), attribs)
ValueError: NSInvalidArgumentException - *** -[NSNull
screenFontWithRenderingMode:]: unrecognized selector sent to instance
0xa0018020
I tried using "LucidaGrande" instead (the only Lucida variant on my
system) and then everything works. Is there a big difference between
these two fonts?
When I saw this line
BACKGROUND = '/System/Library/CoreServices/CoreTypes.bundle/' + \
'Contents/Resources/GenericDocumentIcon.icns' # might require leopard?
I started up Tiger -- that icon does exist on Tiger as well...so no
problems there.
Anyway, all in all my concern is that there may be more problems
lurking and I worry that adding the icon making a separate build step
would cause problems when trying to build MacVim. We should be able
to iron out these problems but before I add this to the repo I think
we need to ensure that it will build on a "clean" Tiger/Leopard
install. It might be sufficient for me to just make a patch and send
it out asking people to try it out before I merge.
Finally, I really think we need to do something about the smaller
sized icons: they are completely illegible. I have attached the icon
for ".h" files to illustrate this point. This is the simplest icon
but even it is impossible to make out what it is supposed to be (even
at 32x32). I'm not sure exactly what to do about this, but one
suggestion is to make the file extension text cover the entire
document at 32x32 and lower. The MacVim icon could perhaps be toned
down or, in the case of 16x16, completely removed?
The problem with smaller icons is particularly important since they
are often the icons you see in Finder (at least if you use list/column
view in Finder) and since they are also displayed as proxy icons.
Björn
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_mac" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---
doc-bm-h.icns
Description: Binary data
