[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
How to support Finder preview pane for new application file types
> quoting Rick Hoge and David Dunham:
>
>>> Generally the Finder seems able to show a preview image, as well as
>>> the text fields Name, Kind, Size, Created, and Modified. How are
>>> these fields generated? Is it possible to provide custom fields for
>>> new file types?
>>
>> I don't think you can customize Finder so that your file shows
>> different fields. I assume you're not asking about how Name, Size,
>> Created, and Modified are genereated -- Kind once came from the 'kind'
>> resource but now would be from the application's property list.
>
> (1) I don't know if this is what you want or if it might be sufficient
> for
> your purposes, but think of, say, the preview pane in column view: In
> it, eg. the actual contents of a PDF file can be displayed as a
> thumbnail. Also, if I create ordinary text files in BBEdit, the preview
> column will show the beginning of the actual text (the file's
> contents). I
> have a hunch that it /should/ be possible to utilise the underlying
> plumbing behind these features, allowing this to work with new file
> types
> and content.
>
Thanks - I am starting to think it will be easier and more
forward-compatible to make use NSBrowser to make my own file-system
browser that handles this. On the other hand, if there were some way
to do something even as simple as writing an icns or PICT resource to
my files that would be really cool because it would give a bit of
context in the finder. I am working with Medical image files which,
for backward compatibility, should not have anything extra in the data
fork. I do everything in Cocoa though and know nothing about Carbon,
which is where all the API's for writing resources seem to be -
Rick