[comp.sys.apple] icons and file types in GS/OS

davep@pro-graphics.cts.com (David Pirmann) (12/16/89)

I am wondering how I can change the "unknown" file type description in GS/OS. 
I designed an icon for $E0 files (ShrinkIt archives), and now want GS/OS to
display "Shrinkit Archive" on the info window and "view by type" lists instead
of simply "unknown."  Can this be done?  By the way, the icon works properly
for type $E0/$8002 shrinkit files.

 ProLine: davep@pro-graphics                  "We are all in the gutter,
    UUCP: ...crash!pro-graphics!davep          but some of us are looking at
ARPA/DDN: pro-graphics!davep@nosc.mil          the stars."  -OSCAR WILDE
Internet: davep@pro-graphics.cts.com

mattd@Apple.COM (Matt Deatherage) (12/17/89)

In article <0.apple_ii.info-apple@pro-graphics> davep@pro-graphics.cts.com (David Pirmann) writes:
>I am wondering how I can change the "unknown" file type description in GS/OS. 
>I designed an icon for $E0 files (ShrinkIt archives), and now want GS/OS to
>display "Shrinkit Archive" on the info window and "view by type" lists instead
>of simply "unknown."  Can this be done?  By the way, the icon works properly
>for type $E0/$8002 shrinkit files.
>
> ProLine: davep@pro-graphics                  "We are all in the gutter,

You can't literally change the "Unknown" description in the Finder (it's not
part of GS/OS, but a mechanism the Finder and other programs can use).  A
mechanism exists to supply your own strings, but "Unknown" is the only one
that should not be altered (you can't supercede it with your own, and you're
not supposed to mess with the files Apple provides).

The mechanism is described in Apple II File Type Note for file type $42,
"File Type Descriptors".  Basically, the data structure is a collection of
strings along with a file type and auxiliary type the string should match
for.  If you create a new structure with the string, filetype and auxiliary
type you want, as the FTN describes, the Finder will dutifully recognize and
use it.

The problem here is that the files that ship with 5.0 through 5.0.2 already
*have* a descriptor for ShrinkIt - it's something like "ShrinkIt (NuFX)
document".  If it doesn't appear on your system, there is one of two problems:

1)  Your *:Icons directory has the file FType.Main ($42/$0000), but not the
    file FType.Aux ($42/$0001).  If so, get the latter file from a friend.

2)  You only have 512K of memory.  In the minimum system configuration, Finder
    will only load the minimum File Type Descriptors and will ignore any
    other $42 files it finds, to save memory.  If this is the case, you can't
    add the string to your current system, but it (and a whole lot of others,
    including AppleWorks GS, Medley, HyperStudio, ORCA and TML identifiers)
    will start being automatically listed if you add more memory.

-- 
-----------------------------------------------------------------------------
Matt Deatherage, Apple Computer, Inc. | "The opinions expressed in this tome
Send PERSONAL mail ONLY (please) to:  | should not be construed to imply that
Amer. Online: Matt DTS                | Apple Computer, Inc., or any of its
ThisNet: mattd@apple.com              | subsidiaries, in whole or in part,
ThatNet: (stuff)!ames!apple!mattd     | have any opinion on any subject."
Other mail by request only, please.   | "So there."
-----------------------------------------------------------------------------