How to put icons on other files (still problem)
chuck hinkle
chuckbo at hinkles.us
Fri May 14 23:48:08 CDT 2004
> Hi Chuck,
>
>> Okay, either I'm blind or too ignorant to see what's wrong. I've used Xray.
>> When I first create the file, it has parameters:
>> Creator - Dash
>> Extension - <none>
>> Type - Vdsc
>> Bound to Valentina Carbon
>> After I go to Get Info and specify that my program should open it, I see:
>> Creator - Dash
>> Extension - <none>
>> Type - Vdsc
>> Bount to Slingshot
>>
>> If I review the file type and icon in RB, my
>> Mac Creator = Dash
>> Mac Type = Vdsc
>> Extension = .gdb
>
>> So is the problem coming from not having a file extension?
>
> The creator and type look fine to me so I think it could be. IIRC, OS X
> doesn't seem to handle bindings very well for files without extensions.
>
> Keith
>
Keith,
by forcing an extension of .gdb, it's working.
I ran into two extremely weird items along the way.
1) Even though I've changed the MacType in the file type dialog box to
"Dash" and I have a RB statement F.MacType = "Dash", after I Xray the file
that gets created with the Valentina .Create method, its Mactype is still
Vdsc.
2) I had a test to see if f.name ended with .gdb, and if it didn't, I
appended the .gdb to the f.name. This works if I put a break command before
the test and single-step through the code. But if I'm not tracing through
the code, the test fails (it thinks that there's a .gdb extension even
though there isn't), and the program creates the file without any extension.
I ended up having to test f.name to remove the extension if it finds it and
then to append it back into place. But now I'm wondering if I'm going to end
up with files named FILENAME.gdb.gdb. Doesn't matter, I suspect, because at
least it has the right icon and maps to my program.
chuck
More information about the Valentina
mailing list