Application Binding in Mac OS X
A slightly technical discussion (but only slightly)
Before Mac OS X
Since the release of the very first Mac in 1984 there have been two pieces of information associated every file on a Macintosh: |
|
Its creator signature : a 4-character code which uniquely identifies the application to which that code is registered with Apple Computer. File Buddy's creator signature is 'FBud'. |
|
Its file type : a 4-character code which denotes the nature of the data stored in a file. A plain text file would have type 'TEXT', an application would have type 'APPL' and so on. |
|
Prior to Mac OS X, every version of the Macintosh Finder relied exclusively a file's creator signature (or creator) to determine which application should be used to open the file in the Finder. (The technical term for his is application binding. The creator signature determines to which application a file is bound.) File types were used to determine if a particular file could be opened in an application, such as when dragging a file to the application's icon, as well as some other things for some file types (we're only going to be a little technical here). |
|
The Problem |
|
Okay, it's not quite true to say extensions were only for your benefit. They were when the file was on a Macintosh. However, such extensions have more significance on other computer platforms where they are used to provide the information your Mac gets from creators and file types. |
|
The file which opens correctly on a Macintosh may leave the other operating system confused as to what should be done with it if the file has no extension. And the file which comes from someone using the other operating system has an extension but no file type or creator, and hence you're Mac might not know which application should open the file. In most cases the program on your Macintosh uses to transfer the file to your Mac would set the file type and creator based on a file's extension, but files could still find their way onto your Mac which your Mac didn't know how to open. |
With Mac OS X
The Solution |
|
Apparently Apple felt the issue of cross-platform compatibility was significant enough to warrant a greater dependence on file extensions for Macintosh users, while at the same time relaxing dependence on file types and creators. Yes, this means Apple decided Mac OS X should act more like the other operating system. |
|
Mac OS X still supports file types and creators, and most files don't need an extension on the name to open in the correct application on your Macintosh. |
|
Mac OS X can also use file extensions to determine which application should be used to open a file. |
|
The Mac OS X Finder also provides a third, completely different mechanism for application binding: The "Open with application" feature of the Finder's Show Info window. We avoid this as much as possible for assigning an application to individual files. When an application is selected with this feature for an individual file, the Finder adds a small resource containing information about which application should be used to open the file to the file's resource fork (creating one if necessary), and gives the file a custom icon so it will appear in the Finder to belong to the application you've chosen. This can add as much as 80K more commonly around 40K to the size of the file, the vast majority of which is for the custom icon. Whenever possible (and it's usually possible), changing the file's creator signature to that of the application is much more efficient. |
|
Thus Mac OS X can use any of five separate and distinct pieces of information (referred to as meta-data) for binding files to applications:
1 |
An application selected for an individual file using the Finder's Show Info window. |
2 |
An application selected for all files of a particular using the Finder's Show Info window. |
3 |
Creator signatures |
4 |
File Types |
5 |
Extensions |
|
|
As is usually the case with such changes, this one offers advantages and disadvantages. The most significant advantage is:
|
With more options for determining which application should be used to open a file, the Mac OS X Finder is far less likely to tell you it couldn't find an appropriate application to open a file. |
|
|
The most significant disadvantage is:
|
The logic used to determine which application should be used to open a file is much more complex than it used to be. Complexity is a breeding ground for confusion and unexpected behaviors, and while Mac OS X does a pretty good job with all of this, people still report the occasional odd behavior when opening files in Mac OS X. |
|
|
The reliance on extensions has also resulted in a couple of other behaviors:
1 |
The Finder is now more particular when file names are edited. Thus users of Mac OS X are asked to confirm changes to file name extensions, whereas prior to Mac OS X no such confirmations were required. |
2 |
Mac OS 10.1 introduced the ability to hide extensions. We discourage extension hiding as it can lead to confusion in some situations. |
|
For example, a folder could contain files "Homework.txt" and "Homework.tiff". If extensions are hidden, they both appear in the Finder to be named "Homework". |
|
Because only claimed extensions are hidden, in the previous example, a third file in the same folder could be "Homework.note to me" and the "extension" would not be hidden because it is not a valid extensions. |
|
Be aware that even with extension hiding turned off there are occasions when the Finder will hide an extension without telling you. |
|
|
File Buddy always uses the full file system name when displaying file names. Thus you may on occasion notice an extension on a file in File Buddy which does not appear in the Finder. This is the intended behavior. |
Related Topics
|