File association

Last updated

In computing, a file association associates a file with an application capable of opening that file. More commonly, a file association associates a class of files (usually determined by their filename extension, such as .txt ) with a corresponding application (such as a text editor).

Contents

Associations and verbs

A single file extension may have several associations for performing various actions, also known as verbs. Some of the common verbs are:

A picture, for example, may be associated with these words so that open opens the picture in an image viewer, edit opens up an image editing program and print sends the picture to a printer.

Implementations

Most operating systems support file associations in some form or the other. For example, opening a file from a file manager usually invokes the open verb in order to open the file with its associated application. The "open" verb invokes the associated application program, which reads the file or document and presents it to the user for viewing, and possibly for editing or other action.

Additional actions such as print are usually accessed via a right-click context menu. A mechanism for modifying associations is also usually present. An example for this is the Open With option in the Windows Shell.

Microsoft Windows

The Microsoft Windows series of operating systems, beginning with Windows 3.x supports file extension-based associations. [1] Associations are stored in registry [2] as sets of verbs for each file extension. Older versions supported open associations stored in WIN.INI. File associations can be displayed and edited using the assoc command and with the help of the ftype command it is possible to create association between file type and application which will open files of this type. [3] [4]

The Windows shell invokes file association actions through COM, drag and drop, command line calls or through Dynamic Data Exchange. Advanced features of Microsoft Windows file associations included manually defining a new file extension with any number of associated actions, a primary default action, showing extensions only for specific file types, customizing the file type icon and description and customizing associated MIME type and their handling (how to handle file types for files downloaded or directly opened from within the Internet Explorer browser). The ability to configure advanced file association functionality, however, was removed in Windows Vista and later operating systems.

Linux

Linux-based GUIs, such as KDE and GNOME, support MIME type-based associations. For example, the MIME type text/plain would be associated with a text editor.

Mac OS

The Classic Mac OS used type codes and creator codes to associate each file with its corresponding application, regardless of file extension. The more recent macOS also supports file extension–based associations.

Application bundles in macOS declare supported file types in their Info.plist file. For each of these specified types, a Uniform Type Identifier is given, along with a list of 'tags' which define how a file or data of this type could be identified. For example, the JPEG type is defined with a UTI of 'public.jpeg', and tagged with the extensions 'jpg' and 'jpeg', the MIME type 'image/jpeg' and the type code 'JPEG'. [5]

The operating system uses this information to generate a list of applications which are able to open each type. Within Finder (software) each file will be identified with a UTI and open with the default application for that type. The user may also select from a list of other applications which support the type.

Using this system, types are also associated with data for which there is no file name or the file extension is missing. This includes pasteboard data and data streaming over a protocol such as HTTP where a MIME type has been given.

See also

Related Research Articles

Multipurpose Internet Mail Extensions (MIME) is an Internet standard that extends the format of email messages to support text in character sets other than ASCII, as well as attachments of audio, video, images, and application programs. Message bodies may consist of multiple parts, and header information may be specified in non-ASCII character sets. Email messages with MIME formatting are typically transmitted with standard protocols, such as the Simple Mail Transfer Protocol (SMTP), the Post Office Protocol (POP), and the Internet Message Access Protocol (IMAP).

Object Linking & Embedding (OLE) is a proprietary technology developed by Microsoft that allows embedding and linking to documents and other objects. For developers, it brought OLE Control Extension (OCX), a way to develop and use custom user interface elements. On a technical level, an OLE object is any object that implements the IOleObject interface, possibly along with a wide range of other interfaces, depending on the object's needs.

A filename extension, file name extension or file extension is a suffix to the name of a computer file. The extension indicates a characteristic of the file contents or its intended use. A filename extension is typically delimited from the rest of the filename with a full stop (period), but in some systems it is separated with spaces.

A text file is a kind of computer file that is structured as a sequence of lines of electronic text. A text file exists stored as data within a computer file system. In operating systems such as CP/M and MS-DOS, where the operating system does not keep track of the file size in bytes, the end of a text file is denoted by placing one or more special characters, known as an end-of-file marker, as padding after the last line in a text file. On modern operating systems such as Microsoft Windows and Unix-like systems, text files do not contain any special EOF character, because file systems on those operating systems keep track of the file size in bytes. Most text files need to have end-of-line delimiters, which are done in a few different ways depending on operating system. Some operating systems with record-orientated file systems may not use new line delimiters and will primarily store text files with lines separated as fixed or variable length records.

Preview (macOS) Image and PDF viewer software by Apple

Preview is the vendor-supplied image viewer and PDF viewer of the macOS operating system. In addition to viewing and printing digital images and Portable Document Format (PDF) files, it can also edit these media types. It employs the Aqua graphical user interface, the Quartz graphics layer, and the ImageIO and Core Image frameworks.

Filename Text string used to uniquely identify a computer file

A filename or file name is a name used to uniquely identify a computer file in a directory structure. Different file systems impose different restrictions on filename lengths and the allowed characters within filenames.

CUPS

CUPS is a modular printing system for Unix-like computer operating systems which allows a computer to act as a print server. A computer running CUPS is a host that can accept print jobs from client computers, process them, and send them to the appropriate printer.

Configuration file

In computing, configuration files are files used to configure the parameters and initial settings for some computer programs. They are used for user applications, server processes and operating system settings.

MHTML, an initialism of "MIME encapsulation of aggregate HTML documents", is a web page archive format used to combine, in a single computer file, the HTML code and its companion resources that are represented by external hyperlinks in the web page's HTML code. The content of an MHTML file is encoded using the same techniques that were first developed for HTML email messages, using the MIME content type multipart/related. MHTML files use a .mhtml or .mht filename extension.

Desktop search

Desktop search tools search within a user's own computer files as opposed to searching the Internet. These tools are designed to find information on the user's PC, including web browser history, e-mail archives, text documents, sound files, images, and video. A variety of desktop search programs are now available; see this list for examples. Most desktop search programs are standalone applications. Desktop search products are software alternatives to the search software included in the operating system, helping users sift through desktop files, emails, attachments, and more.

A double-click is the act of pressing a computer mouse button twice quickly without moving the mouse. Double-clicking allows two different actions to be associated with the same mouse button. It was developed by Bill Atkinson of Apple Computer for their Lisa project. Often, single-clicking selects an object, while a double-click executes the function associated with that object. Following a link in a modern web browser is accomplished with only a single click, requiring the use of a second mouse button, "click and hold" delay, or modifier key to gain access to actions other than following the link. On touchscreens, the double-click is called "double-tap"; it's not used as much as double-click, but typically it functions as a zoom feature.

The Extensible Metadata Platform (XMP) is an ISO standard, originally created by Adobe Systems Inc., for the creation, processing and interchange of standardized and custom metadata for digital documents and data sets.

Long filename (LFN) support is Microsoft's backward compatible extension of the 8.3 filename naming scheme used in DOS. Long filenames can be more descriptive, including longer filename extensions such as .jpeg, .tiff, .html, and .xhtml that are common on other operating systems, rather than specialized shortened names such as .jpg, .tif, .htm, or .xht. The standard has been common with File Allocation Table (FAT) filesystems since its first implementation in Windows NT 3.5 of 1994.

Image file formats are standardized means of organizing and storing digital images. An image file format may store data in an uncompressed format, a compressed format, or a vector format. Image files are composed of digital data in one of these formats so that the data can be rasterized for use on a computer display or printer. Rasterization converts the image data into a grid of pixels. Each pixel has a number of bits to designate its color. Rasterizing an image file for a specific device takes into account the number of bits per pixel that the device is designed to handle.

A camera raw image file contains minimally processed data from the image sensor of either a digital camera, a motion picture film scanner, or other image scanner. Raw files are named so because they are not yet processed and therefore are not ready to be printed or edited with a bitmap graphics editor. Normally, the image is processed by a raw converter in a wide-gamut internal color space where precise adjustments can be made before conversion to a "positive" file format such as TIFF or JPEG for storage, printing, or further manipulation. There are dozens of raw formats in use by different manufacturers of digital image capture equipment.

A media type is a two-part identifier for file formats and format contents transmitted on the Internet. The Internet Assigned Numbers Authority (IANA) is the official authority for the standardization and publication of these classifications. Media types were originally defined in Request for Comments RFC 2045 (MIME) Part One: Format of Internet Message Bodies in November 1996 as a part of MIME specification, for denoting type of email message content and attachments; hence the original name, MIME type. Media types are also used by other internet protocols such as HTTP and document file formats such as HTML, for similar purposes.

A Uniform Type Identifier (UTI) is a text string used on software provided by Apple Inc. to uniquely identify a given class or type of item. Apple provides built-in UTIs to identify common system objects – document or image file types, folders and application bundles, streaming data, clipping data, movie data – and allows third party developers to add their own UTIs for application-specific or proprietary uses. Support for UTIs was added in the Mac OS X 10.4 operating system, integrated into the Spotlight desktop search technology, which uses UTIs to categorize documents. One of the primary design goals of UTIs was to eliminate the ambiguities and problems associated with inferring a file's content from its MIME type, filename extension, or type or creator code.

Sidecar files, also known as buddy files or connected files, are computer files that store data which is not supported by the format of a source file.

A file format is a standard way that information is encoded for storage in a computer file. It specifies how bits are used to encode information in a digital storage medium. File formats may be either proprietary or free and may be either unpublished or open.

High Efficiency Image File Format (HEIF) is a container format for storing individual images and image sequences. The standard covers multimedia files that can also include other media streams, such as timed text, audio and video.

References

  1. "Windows 3.x Features".
  2. HKEY_CLASSES_ROOT Key
  3. Microsoft TechNet Assoc article on assoc
  4. Microsoft TechNet Ftype article on ftype
  5. Mac OS X Reference Library - Uniform Type Identifier Concepts

Further reading

  1. "Implementing a Custom File Format". Microsoft Developer Network Library. Microsoft Corporation. 9 November 2010. Retrieved 5 December 2010.
  2. "File Associations". KDE Documentation. KDE. 11 November 2016. Retrieved 30 May 2020.