Macintosh custom stack icons
Ray Horsley
ray at linkitonline.com
Sat Mar 29 15:34:01 EST 2003
My sincere thanks to Shari! Your step-by-step help on this did the trick.
Anybody having problems getting your stacks to show up with desktop custom
icons on a Mac? Here's how to do it.
Thanks,
Ray Horsley
Developer, LinkIt! Software
>I recently followed Shari's many notes with a lot of users regarding icons
>in Windows. Now I'm having a similar problem on the Mac. I've fooled with
>ResEdit and gotten document icons of my stacks to show up right, but I've
>really never understood it well. Now for some reason my stacks are showing
>up as generic icons. I've run Norton, rebuilt the desktop file multiple
>times, and even defragmented the whole hard disk, but nothing is bringing
>back the custom icons I originally had from my stacks. Does anybody have
>any direction they can provide on this?
>
>Thanks!
>
>Ray Horsley
>> I've made my own stand alone using Metacard's Standalone Builder, and it
>> runs the stacks. The stand alone (my app) shows my own custom icon, but the
>> stacks don't show theirs.
>
> Ah... gotcha....
>
> Only thing I forgot to ask, was WHICH flavour of Mac you are
> targeting... OSX or PPC. The following instructions are for OSX.
>
> You need to set the creator of the standalone, and the stacks.
>
> Step 1:
>
> The resource fork of the standalone, and stacks. Firstly, the stacks
> themselves do NOT need a resource fork. But the standalone does. In
> the stack that will become the standalone, you should have an ic14,
> ic18, icns, ics4, and ics8 resource. If you edit ic18, the rest
> should be edited for you automatically. Put your standalone icon
> into resource 128 of ic18. Put your stack icon into resource 129 and
> 130.
>
>
> Step 2:
>
> When you use the Standalone Builder, there is a field "Creator" that
> has "MSTD" in it. This is Metacard's creator code.
>
> You'll need to use a custom code for this. Creator codes are 4
> characters, letters or numbers, small or capital. If you plan to
> distribute the standalone to others, you should make sure not to use
> a code already in use. You can get creator code info at:
>
> http://developer.apple.com/dev/cftype/faq.html
>
> I register all mine with Apple thru this link. And check for
> existing codes before using one, to make sure it is not already
> registered. For Blackjack Gold I used "bJg3".
>
> Enter this code in the "Creator" field when you build the standalone.
>
>
> Step 3:
>
> You must save the icons as files, specifically ".icns" files, and put
> them into your "Resource" folder that Metacard OSX will create in the
> OSX package of your program. Save one for the standalone, and one
> for the stacks. Replace the Metacard .icns files with your own, and
> enter the new info into the info.plist file.
>
> The CFBundleTypeIconFile should be your icon for the stacks, for
> Blackjack Gold, I called the stack icon "Data.icns"
>
> <key>CFBundleTypeIconFile</key>
> <string>Data.icns</string>
>
> The CFBundleIconFile should be your icon for the standalone, for
> Blackjack Gold, I called the standalone icon "Gold.icns"
>
> <key>CFBundleIconFile</key>
> <string>Gold.icns</string>
>
> The CFBundleSignature is your creator code.
>
> <key>CFBundleSignature</key>
> <string>bJg3</string>
>
> I've attached the actual plist file I used for Blackjack Gold, so you
> can see the other changes I made to Metacard's.
>
> Step 4:
>
> The pkgInfo file.
>
> Open it, and change the text to "APPLXXXX", where XXXX is your creator code.
>
> Step 5:
>
> The standalone, and the stacks, should be in the MacOS folder of the package.
>
>
>
> Step 5:
>
> Open the resource for of the standalone with ResEdit or a similar
> program. There should be a resource named your chosen creator code.
> There should be the ic** series, and each one should have 128 as the
> standalone icon, and 129-130 as the stack icon. Except for icns,
> which you just leave alone.
>
> Open the BNDL resource and edit 128. The signature field should be
> your creator code. If it isn't, enter it there.
>
> There should be two types: APPL and MSTK. APPL should be your
> standalone icon, MSTK should be your stack icon. If they aren't,
> double click to edit them.
>
>
> Step 6:
>
> Set the creator code of your stacks. To do this, save your external
> stacks with stackfiletype "XXXXMSTK" where "XXXX" is your creator
> code.
>
> In the standalone, every place it saves a stack, set the stackFileType first:
>
> set the stackFileType to "XXXXMSTK"
> save stack someStack
>
>
> Step 7:
>
> You are done. Hopefully I haven't left anything out!
>
> Shari C
More information about the metacard
mailing list