Tampilkan postingan dengan label Artikel Photoshop. Tampilkan semua postingan
Tampilkan postingan dengan label Artikel Photoshop. Tampilkan semua postingan

Minggu, 24 Januari 2010

Computer File

Computer file

A computer file is a block of arbitrary information, or resource for storing information, which is available to a computer program and is usually based on some kind of durable storage. A file is durable in the sense that it remains available for programs to use after the current program has finished. Computer files can be considered as the modern counterpart of paper documents which traditionally were kept in offices' and libraries' files, which are the source of the term.

File contents

Many modern operating system consider files as a collection of bytes. At a higher level, where the content of the file is being considered, these binary digits may represent integer values or text characters, or anything else. It is up to the program using the file to understand the meaning and internal layout of information in the file and present it to a user as more meaningful information (like text, images, sounds).

At any instant in time, a file might have a size, normally expressed in bytes, that indicates how much storage is associated with the file. In most modern operating systems the size can be any whole number up to a system limit. However, the general definition of a file does not require that its instant size has any real meaning, unless the data within the file happens to correspond to data within a pool of persistent storage.

For example, the file to which the link /bin/ls points in a typical Unix-like system probably has a defined size that seldom changed. Compare this with /dev/null. This is a file, but its size may be open to question.

Information in a computer file can consist of smaller packets of information (often called records or lines) that are individually different but share some trait in common. For example, a payroll file might contain information concerning all the employees in a company and their payroll details; each record in the payroll file concerns just one employee, and all the records have the common trait of being related to payroll—this is very similar to placing all payroll information into a specific filing cabinet in an office that does not have a computer. A text file may contain lines of text, corresponding to printed lines on a piece of paper. Alternatively, a file may contain an arbitrary binary image (a BLOB) or it may contain an executable.

The way information is grouped into a file is entirely up to the person designing the file. This has led to a plethora of more or less standardized file structures for all imaginable purposes, from the simplest to the most complex. Most computer files are used by computer programs. These programs create, modify and delete files for their own use on an as-needed basis. The programmers who create the programs decide what files are needed, how they are to be used and (often) their names.

In some cases, computer programs manipulate files that are made visible to the computer user. For example, in a word-processing program, the user manipulates document files that she names herself. The content of the document file is arranged in a way that the word-processing program understands, but the user chooses the name and location of the file, and she provides the bulk of the information (such as words and text) that will be stored in the file.

Many applications pack all their data files into a single file, using internal markers to discern the different types of information contained within. The data files used by games such as Doom and Quake are examples of this.

Files on a computer can be created, moved, modified, grown, shrunk and deleted. In most cases, computer programs that are executed on the computer handle these operations, but the user of a computer can also manipulate files if necessary. For instance, Microsoft Word files are normally created and modified by the Microsoft Word program in response to user commands, but the user can also move, rename, or delete these files directly by using a file manager program such as Windows Explorer (on Windows computers).

In Unix-like systems, user-space processes do not normally deal with files at all; the operating system provides a level of abstraction which means that almost all interaction with files from user-space is through hard links. Hard links allow a name to be associated with a file (or they can be anonymous - and therefore temporary); files do not have names in the OS. For example, a user-space program cannot delete a file; it can delete a link to a file (for example, using the shell commands rm or mv or, in the anonymous case, simply by exiting), and if the kernel determines that there are no more existing links to the file, it may then delete the file. In fact, it really is only the kernel that deals with files, but it serves to handle all user-space interaction with (virtual) files in a manner that is transparent to the user-space programs.

Semantics

Although the way programs manipulate files varies according to the operating system and file system involved, the following operations are typical:

  • Creating a file with a given name
  • Setting attributes that control operations on the file
  • Opening a file to use its contents
  • Reading or updating the contents
  • Committing updated contents to durable storage
  • Closing the file, thereby losing access until it is opened again

Identifying and organizing files

Files and folders arranged in a hierarchyEnlarge picture
Files and folders arranged in a hierarchy

In modern computer systems, files are typically accessed using names (filenames). In some operating systems, the name is associated with the file itself. In others, the file is anonymous, and is pointed to by links that have names. In the latter case, a user can identify the name of the link with the file itself, but this is a false analogue, especially where there exists more than one link to the same file.

Files (or links to files) can be located in directories. However, more generally, a directory can contain either a list of files or a list of links to files. Within this definition, it is of paramount importance that the term "file" includes directories. This permits the existence of directory hierarchies, i.e., directories containing subdirectories. A name that refers to a file within a directory must be unique. In other words, there must be no identical names within a directory. However, in some operating systems, a name may include a specification of type that means a directory can contain an identical name for more than one type of object such as a directory and a file.

In environments in which a file is named, a file's name and the path to the file's directory must uniquely identify it among all other files in the computer system—no two files can have the same name and path. Where a file is anonymous, named references to it will exist within a namespace. In most cases, any name within the namespace will refer to exactly zero or one file. However, any file may be represented within any namespace by zero, one or more names.

Any string of characters may or may not be a well-formed name for a file or a link depending upon the context of application. Whether or not a name is well-formed depends on the type of computer system being used. Early computers permitted only a few letters or digits in the name of a file, but modern computers allow long names (some up to 255) containing almost any combination of unicode letters or unicode digits, making it easier to understand the purpose of a file at a glance. Some computer systems allow file names to contain spaces; others do not. Case-sensitivity of file names is determined by the file system. Unix file systems are usually case sensitive and allow user-level applications to create files whose names differ only in the case of characters. Microsoft Windows supports multiple file systems, each with different policies regarding case-sensitivity. The common FAT file system can have multiple files whose names differ only in case if the user uses a disk editor to edit the file names in the directory entries. User applications, however, will usually not allow the user to create multiple files with the same name but differing in case.

Most computers organize files into hierarchies using folders, directories, or catalogs. (The concept is the same irrespective of the terminology used.) Each folder can contain an arbitrary number of files, and it can also contain other folders. These other folders are referred to as subfolders. Subfolders can contain still more files and folders and so on, thus building a tree-like structure in which one "master folder" (or "root folder" — the name varies from one operating system to another) can contain any number of levels of other folders and files. Folders can be named just as files can (except for the root folder, which often does not have a name). The use of folders makes it easier to organize files in a logical way.

When a computer allows the use of folders, each file and folder has not only a name of its own, but also a path, which identifies the folder or folders in which a file or folder resides. In the path, some sort of special character—such as a slash—is used to separate the file and folder names. For example, in the illustration shown in this article, the path /Payroll/Salaries/Managers uniquely identifies a file called Managers in a folder called Salaries, which in turn is contained in a file called Payroll. The folder and file names are separated by slashes in this example; the topmost or root folder has no name, and so the path begins with a slash (if the root folder had a name, it would precede this first slash).

Many (but not all) computer systems use extensions in file names to help identify what they contain, also known as the file type. On Windows computers, extensions consist of a dot (period) at the end of a file name, followed by a few letters to identify the type of file. An extension of .txt identifies a text file; a .doc extension identifies any type of document or documentation, commonly in the Microsoft Word file format; and so on. Even when extensions are used in a computer system, the degree to which the computer system recognizes and heeds them can vary; in some systems, they are required, while in other systems, they are completely ignored if they are present.

Protecting files

Many modern computer systems provide methods for protecting files against accidental and deliberate damage. Computers that allow for multiple users implement file permissions to control who may or may not modify, delete, or create files and folders. A given user may be granted only permission to modify a file or folder, but not to delete it; or a user may be given permission to create files or folders, but not to delete them. Permissions may also be used to allow only certain users to see the contents of a file or folder. Permissions protect against unauthorized tampering or destruction of information in files, and keep private information confidential by preventing unauthorized users from seeing certain files.

Another protection mechanism implemented in many computers is a read-only flag. When this flag is turned on for a file (which can be accomplished by a computer program or by a human user), the file can be examined, but it cannot be modified. This flag is useful for critical information that must not be modified or erased, such as special files that are used only by internal parts of the computer system. Some systems also include a hidden flag to make certain files invisible; this flag is used by the computer system to hide essential system files that users should not alter.

Storing files

The discussion above describes a file as a concept presented to a user or a high-level operating system. However, any file that has any useful purpose, outside of a thought experiment, must have some physical manifestation. That is, a file (an abstract concept) in a real computer system must have a real physical analogue if it is to exist at all.

In physical terms, most computer files are stored on some type of data storage device. For example, there is a hard disk, from which most operating systems run and on which most store their files. Hard discs are the most ubiquitous form of non-volatile storage at the start of the 21st century. Where files contain only temporary information, they may be stored in RAM.

In Unix-like operating systems, many files have no direct association with a physical storage device: /dev/null is a prime example, as are just about all files under /dev, /proc and /sys. These can be accessed as files in user space. They are really virtual files that exist, in reality, as objects within the operating system kernel.

Computer files may be stored on magnetic tape. Files can also be stored on other media in some cases, such as writeable compact discs, Digital Versatile Discs, Zip drives, USB flash drives, etc.

Backing up files

When computer files contain information that is extremely important, a back-up process is used to protect against disasters that might destroy the files. Backing up files simply means making copies of the files in a separate location so that they can be restored if something happens to the computer, or if they are deleted accidentally.

There are many ways to back up files. Most computer systems provide utility programs to assist in the back-up process, which can become very time-consuming if there are many files to safeguard. Files are often copied to removable media such as writable CDs or cartridge tapes. Copying files to another hard disk in the same computer protects against failure of one disk, but if it is necessary to protect against failure or destruction of the entire computer, then copies of the files must be made on other media that can be taken away from the computer and stored in a safe, distant location.

The Grandfather-Father-Son method automatically makes three back ups, the grandfather file is the oldest copy of the file and the son is the current copy.

File systems and file managers

The way a computer organizes, names, stores and manipulates files is globally referred to as its file system. Most computers have at least one file system. Some computers allow the use of several different file systems. For instance, on newer MS Windows computers, the older FAT-type file systems of MS-DOS and old versions of Windows are supported, in addition to the NTFS file system that is the normal file system for recent versions of Windows. Each system has its own advantages and disadvantages. Standard FAT allow only eight-character file names (plus a three-character extension) with no spaces, for example, whereas NTFS allows much longer names that can contain spaces. You can call a file Payroll records in NTFS, but in FAT you would be restricted to something like payroll.dat (unless you were using VFAT, a FAT extension allowing long file names).

File manager programs are utility programs that allow you to manipulate files directly. They allow you to move, create, delete and rename files and folders, although they do not actually allow you to read the contents of a file or store information in it. Every computer system provides at least one file-manager program for its native file system. Under Windows, the most commonly used file manager program is Windows Explorer.

History

A punched card fileEnlarge picture
A punched card file
The twin disk files of an IBM 305 systemEnlarge picture
The twin disk files of an IBM 305 system

The word "file" appears in the context of computer storage as early as 1952, referring to information stored on punched cards.[1] In early usage people regarded the underlying hardware (rather than the contents) as a file. For example, the IBM 350 disk drives were called "disk files."[2] Systems like the 1962 Compatible Time-Sharing System featured file systems, which gave the appearance of several "files" on one storage device, leading to the modern usage of the term. File names in CTSS had two parts, a user-readable "primary name" and a "secondary name" indicating the file type.[3][4] This convention remains in use by several operating systems today, including Microsoft Windows. Although the current term "register file" shows the early concept of files, it has largely disappeared.

Notes

  1. ^ Robert S. Casey, et al. Punched Cards: Their Applications to Science and Industry, 1952. ISBN.
  2. ^ Martin H. Weik. Ballistic Research Laboratories Report #1115. March 1961. pp. 314-331.
  3. ^ Fernando J. Corbató et al. "An Experimental Time-Sharing System." May 3, 1962.
  4. ^ Jerome H. Saltzer CTSS Technical Notes. Project MIT-LCS-TR016

Read More..

Filling Cabinet

Filing cabinet

A tall metal filing cabinet for work or home use.Enlarge picture
A tall metal filing cabinet for work or home use.

A filing cabinet (or file cabinet in the United States) is a piece of office equipment that is useful for temporary and permanent storage. It is usually used for the storage of paper in a file folder. The two most common forms of filing cabinets are lateral files and vertical files.

A vertical file has drawers that extend from the short side (typically 15 inches)of the cabinet. A lateral file has drawers that extend from the long side (various lengths) of the cabinet. These are also called side filers in Great Britain.

Horizontal file

Henry Brown, an African American inventor, patented a "receptacle for storing and preserving papers" on November 2, 1886. This was a fire and accident safe container made of forged metal, which could be sealed with a lock and key. It was special in that it kept the papers separated.

Vertical file

A wooden Filing Cabinet with drawer openEnlarge picture
A wooden Filing Cabinet with drawer open

The vertical filing cabinet (vertical file cabinet in the United States) more or less as in use today was invented by Edwin G. Seibels in 1898.[1] He was working in his father's insurance office and realized that the then current system of folding papers into envelopes and storing them in pigeon holes could be improved if the folding was dispensed with. The documents could then be stored in large envelopes (hangfiles) vertically, in drawers.

The use of filing cabinets was greatly expanded as a result of the commercial distribution of Xerography machines starting in 1950. This event enabled office workers to "have their own copy" of printed materials. Another influence is the expansion of government regulations that require businesses to create and keep forms and other documents. Some prognosticators have suggested the future of the filing cabinet is in doubt as electronic filing systems proliferate and become lower in cost. Nevertheless, most businesses are still purchasing computer systems with printing capabilities. Unless this trend is reversed, filing of paper is still a viable practice.

In the US, these come in two sizes: for letter-size paper and legal-size paper. Most modern commercially-oriented vertical filing cabinets in the US are manufactured in two, three, four, and five drawer versions in depths of 25, 26 1/2, and 28 inches. The drawers are typically supported on a three-member suspension system that allows the drawer to be fully extended for complete access.

The four drawer vertical file, letter width, is the version purchased by most businesses. The two drawer file is sold mostly for use alongside a desk. The five drawer file is mostly purchased by Federal, State, and Local governments (in a 28 inch deep version) as it typically provides the lowest cost per filing inch. Three drawer files, the least popular version, have the advantage of being at "countertop" height so end users can easily retrieve files and use the top of the cabinet as a work area to examine file contents.

The drawers of most vertical filing cabinets are engineered to accept hanging file folders as these have come to dominate the way most users store information. Some files still have a "follower block" in each drawer. This is a device that adjusts the apparent depth of the drawer interior so that files are kept upright in the drawer. These are the legacy of a time when most filing was done with manila folders rather than hanging files.

For home offices or lighter use applications, vertical files are manufactured in 18 inch deep versions. These typically have two-member suspensions and the drawers do not fully extend.

Lateral file

Lateral files are typically 20 inches deep and manufactured in 30, 36, and 42 inch widths and 2, 3, 4, and 5 drawer versions. The 30 inch wide, 2 drawer version is popular for use inside cubicle workstations as it is engineered to fit under or alongside the cubicle work surfaces. Logic for the use of 3, 4, and 5 drawer files is similar to that of vertical files. Unlike vertical files, most lateral files allow for side-to-side or front-to-back filing.

For letter size files arranged front-to-back, the 30 and 42 wide files are the most effective as the maximum amount of filing per cabinet is enabled. A 36 inch wide file, with letter width filing front-to-back has no more capacity than a corresponding 30 inch wide file.

Some users prefer side to side filing, as they can search index tabs from a seated position. All width lateral files can accommodate this configuration, though the capacity of the file is somewhat diminished.

An advantage for lateral files is that access and view of all files can be easier than with a vertical file because the drawers do not extend as far.

Filing outside the US

Foreign firms offer filing cabinets that permit A4 paper to be used in addition to letter-size. Double file cabinets whose drawers each can accommodate two racks for folders side by side.

Many European companies engineer filing systems that accommodate hanging folders only; there are no drawer bottoms. In the US, most file drawers still have bottoms in the drawers so materials of any sort can be stored.

UK file cabinets are slightly different from US in the width of the rails which support the suspension files, the US ones being narrower; the UK sizes are known as A4, foolscap and A3.

Read More..

File Folder

File folder

Folder files as stationeryEnlarge picture
Folder files as stationery
PGrand paper board file folder

A file folder (US usage) or folder (British and Australian usage) is a kind of folder that holds loose papers together for organization and protection. File folders usually consist of a sheet of heavy paper stock or other thin, but stiff, material which is folded in half, and are used to keep paper documents. They are often used in conjunction with a filing cabinet for storage. File folders can easily be purchased at office supply stores. In the UK, one of the oldest and best known filing companies is Railex. File folders are usually labeled based on what's inside of them. Folders can be labeled directly on the tab with a pen or pencil. Others write on adhesive labels that are placed on the tabs. There are also electronic labelmakers that can be used to make the labels.

File folders can be made from plastic or paper. When paper is used, it is preferable that it is made from paper pulp with long cellulose fibre, such as kraft paper or manila paper.

Terminology

File or folder are other terms used for file folders, but file folders is a common name for the item in the United States. Manila folders are likely the most common, but file folders come in many different forms. In the United States, letter and legal sizes are common.

The exact way to refer to this kind of folder is somewhat unclear. There does not appear to be an internationally standard term. The term file folder seems to be one that dominates North American language, but does not seem as common in other countries. As stated, some refer to file folders simply as folders, but in North America this is confusing because folder can refer to several different things. Others use the term manila folders, but this is confusing because not all file folders are made of Manila hemp This type of folder is sometimes incorrectly called a "vanilla folder".

Another commonly used folder type is the hanging folder (also known by the trade name Pendaflex) which has hooks on all four corners that slide over a rail. Normally, hanging folders are used to file one or more Manila folders, and it is not a common practice to put loose sheets directly into hanging folders. When some documents need to be retrieved, the corresponding Manila folder(s) are removed from the hanging folder. The hanging folder itself is left in its place on the rails.

Occasionally, the term for the item changes based on its context. Some may refer to file folders as files when they are being utilized for storage. For example, one might say, "Would you get me the file on the Paterson case?" Or someone might say, "That information is with the files on the insurance claims." File folder or just folder seems to be how many refer to the item when it is being purchased or not containing any paper yet. For instance, someone might say, "Would you give me an empty folder from the box? I need to make a file on the Thompson estate." Or someone might say, "When you run to the store would you get me some legal size file folders?"

The terms are even more distorted in their digital counterparts. In computing, the word "folder" (or, in some cases, "file folder") is often used as a synonym for "directory", while the word "file" is universally used for actual data items on a disk (sometimes called "documents," especially on the Apple Macintosh).

Tabbed file folders

Tab style/cut

File folders can have tabs. Tabs are often helpful when many files are being stored together and there needs to be an easy way to differentiate them. The tabs can be on the top of the folders (common in business offices) or on the end/side (common in medical offices). Tab sizes vary and are designated based on the size of each tab in proportion to the total length of the folder. They can be:

Examples of different tab styles for file folders.
  • Straight cut. There is one long tab.
  • 1/3 cut. There are three tab positions, each is approximately 1/3 of the total length of the folder. Essentially, tabs are cut to be in the left, center, or right positions.
  • 1/5 cut. Similar to the 1/3 cut, except there are five tab positions, each being 1/5 of the total length of the folder.
  • 2/5 cut. There are only two tab positions, the right and the right of center (ROC) positions. ROC is kind of like a left position, but doesn't extend to the end of the folder because the tabs are only 2/5 of the total length.
  • 1/2 cut. There are two tab positions, left and right.

Tab positions

Because tabs can be cut in different positions, the position of the tab can be referred to as well. For instance, for the 1/3 cut style, folders with tabs in the farthest right position are considered to have a tab in position number three.

Read More..

Link

File

File has several meanings:

  • File folder used to organize documents
  • Filing cabinet
  • Computer file
  • File (tool)
  • A nail file
  • Filing (legal)
  • Filing (manufacturing process)
  • File (formation) Military term for a single column of men one in front of the other. See also Rank (formation)
  • File (chess)
  • file URI scheme
  • file (Unix), a utility used to determine file types.
  • The File menu
  • filé powder, a culinary ingredient used in Cajun and Creole cooking
  • File sharing
  • an Irish poet, see fili
  • FILE - Electronic Language International Festival is an Art & Technology festival held yearly in São Paulo, Brazil.
Rank (formation)

A Rank is a line of military personnel, drawn up in line abreast (i.e. standing side by side).

Commonly, troops called to 'On the right, fall in!' do so by forming in line abreast, determining their initial position in relation
..... Click the link for more information.

This article is copied from an article on Wikipedia® - the free encyclopedia created and edited by online user community. The text was not checked or edited by anyone on our staff. Although the vast majority of the Wikipedia® encyclopedia articles provide accurate and timely information please do not assume the accuracy of any particular article. This article is distributed under the terms of GNU Free Documentation License.

Read More..

HTML

HTML

HTML (HyperText Markup Language)
File name extension .html, .htm
Internet media type text/html
Type code TEXT
Uniform Type Identifier public.html
Developed by World Wide Web Consortium
Type of format Markup language
Extended from SGML
Extended to XHTML

HTML, an initialism of HyperText Markup Language, is the predominant markup language for web pages. It provides a means to describe the structure of text-based information in a document — by denoting certain text as links, headings, paragraphs, lists, and so on — and to supplement that text with interactive forms, embedded images, and other objects. HTML is written in the form of tags, surrounded by angle brackets. HTML can also describe, to some degree, the appearance and semantics of a document, and can include embedded scripting language code (such as JavaScript) which can affect the behavior of Web browsers and other HTML processors.

HTML is also often used to refer to content of the MIME type text/html or even more broadly as a generic term for HTML whether in its XML-descended form (such as XHTML 1.0 and later) or its form descended directly from SGML (such as HTML 4.01 and earlier).

By convention, HTML format data files use a file extension .html or .htm.

History of HTML

Origins

In 1980, physicist Tim Berners-Lee, who was an independent contractor at CERN, proposed and prototyped ENQUIRE, a system for CERN researchers to use and share documents. In 1989, Berners-Lee and CERN data systems engineer Robert Cailliau each submitted separate proposals for an Internet-based hypertext system providing similar functionality. The following year, they collaborated on a joint proposal, the WorldWideWeb (W3) project,[1] which was accepted by CERN.

First specifications

The first publicly available description of HTML was a document called HTML Tags, first mentioned on the Internet by Berners-Lee in late 1991.[2][3] It describes 22 elements comprising the initial, relatively simple design of HTML. Thirteen of these elements still exist in HTML 4.[4]

Berners-Lee considered HTML to be, at the time, an application of SGML, but it was not formally defined as such until the mid-1993 publication, by the IETF, of the first proposal for an HTML specification: Berners-Lee and Dan Connolly's "Hypertext Markup Language (HTML)" Internet-Draft, which included an SGML Document Type Definition to define the grammar.[5] The draft expired after six months, but was notable for its acknowledgment of the NCSA Mosaic browser's custom tag for embedding in-line images, reflecting the IETF's philosophy of basing standards on successful prototypes.[6] Similarly, Dave Raggett's competing Internet-Draft, "HTML+ (Hypertext Markup Format)", from late 1993, suggested standardizing already-implemented features like tables and fill-out forms.[7]

After the HTML and HTML+ drafts expired in early 1994, the IETF created an HTML Working Group, which in 1995 completed "HTML 2.0", the first HTML specification intended to be treated as a standard against which future implementations should be based.[6] Published as Request for Comments 1996, HTML 2.0 included ideas from the HTML and HTML+ drafts.[8] There was no "HTML 1.0"; the 2.0 designation was intended to distinguish the new edition from previous drafts.[9]

Further development under the auspices of the IETF was stalled by competing interests. Since 1996, the HTML specifications have been maintained, with input from commercial software vendors, by the World Wide Web Consortium (W3C).[7] However, in 2000, HTML also became an international standard (ISO/IEC 15445:2000). The last HTML specification published by the W3C is the HTML 4.01 Recommendation, published in late 1999. Its issues and errors were last acknowledged by errata published in 2001.

Version history of the standard

HTML
  • Character encodings
  • Dynamic HTML
  • Font family
  • HTML editor
  • HTML element
  • HTML scripting
  • Layout engine
  • Quirks mode
  • Style sheets
  • Unicode and HTML
  • W3C
  • Web colors
  • XHTML
  • Comparison of
    • web browsers
    • layout engines for
      • HTML
      • HTML 5
      • Non-standard HTML
      • XHTML

HTML versions

July, 1993: Hypertext Markup Language, was published at IETF working draft (that is, not yet a standard).

November, 1995: HTML 2.0 published as IETF Request for Comments:

  • RFC 1866,
  • supplemented by RFC 1867 (form-based file upload) that same month,
  • RFC 1942 (tables) in May 1996,
  • RFC 1980 (client-side image maps) in August 1996, and
  • RFC 2070 (internationalization) in January 1997;

Ultimately, all were declared obsolete/historic by RFC 2854 in June 2000.

An HTML 3.0 standard was proposed to the IETF by Dave Raggett and the newly formed W3C in April 1995. It proposed many of the capabilities that were in Raggett's HTML+ proposal, such as support for tables, text flow around figures, and the display of complex mathematical elements.[10] Even though it was designed to be compatible with HTML 2.0, it was too complex at the time to be implemented. Browser vendors opted to support only parts of the proposal, but implemented other markup constructs that they wanted to be incorporated into the standard.[11] When the draft expired in September 1995, work in this direction was discontinued due to lack of browser support. HTML 3.1 was never officially proposed, and the next standard proposal was HTML 3.2 (code-named "Wilbur"), which dropped the majority of the new features in HTML 3.0 and instead adopted many browser-specific element types and attributes that had been created for the Netscape and Mosaic Web browsers.[12]

January 14, 1997: HTML 3.2, published as a W3C Recommendation.

HTML 3.2 was never submitted to the IETF, whose HTML Working Group closed in September 1996;[13] it was instead published as one of the W3C's first "Recommendations" in early 1997. Mathematical support as proposed by HTML 3.0 finally came about years later with a different standard, MathML.

December 18, 1997: HTML 4.0, published as a W3C Recommendation. It offers three "flavors":

  • Strict, in which deprecated elements are forbidden,
  • Transitional, in which deprecated elements are allowed,
  • Frameset, in which mostly only frame related elements are allowed;

HTML 4.0 (initially code-named "Cougar")[12] likewise adopted many browser-specific element types and attributes, but at the same time began to try to "clean up" the standard by marking some of them as deprecated, and suggesting they not be used. Minor editorial revisions to the HTML 4.0 specification were published in 1998 without incrementing the version number and further minor revisions as HTML 4.01.

April 24, 1998: HTML 4.0 was reissued with minor edits without incrementing the version number.

December 24, 1999: HTML 4.01, published as a W3C Recommendation. It offers the same three flavors as HTML 4.0, and its last errata were published May 12, 2001.

HTML 4.01 and ISO/IEC 15445:2000 are the most recent and final versions of HTML.

May 15, 2000: ISO/IEC 15445:2000 ("ISO HTML", based on HTML 4.01 Strict), published as an ISO/IEC international standard.

January 22, 2008: HTML 5, published as a Working Draft by W3C.

XHTML versions


XHTML is a separate language that began as a reformulation of HTML 4.01 using XML 1.0. It continues to be developed:

  • XHTML 1.0, published January 26, 2000 as a W3C Recommendation, later revised and republished August 1, 2002. It offers the same three flavors as HTML 4.0 and 4.01, reformulated in XML, with minor restrictions.
  • XHTML 1.1, published May 31, 2001 as a W3C Recommendation. It is based on XHTML 1.0 Strict, but includes minor changes, can be customized, and is reformulated using modules from Modularization of XHTML, which was published April 10, 2001 as a W3C Recommendation.
  • XHTML 2.0 is still a W3C Working Draft. XHTML 2.0 is incompatible with XHTML 1.x and, therefore, would be more accurate to characterize as an XHTML-inspired new language than an update to XHTML 1.x.
  • XHTML 5, which is an update to XHTML 1.x, is being defined alongside HTML 5 in the HTML 5 draft.

HTML markup

HTML markup consists of several key components, including elements (and their attributes), character-based data types, and character references and entity references. Another important component is the document type declaration. HTML Hello World:

   </span></span>Hello HTML<span class="sc2"><span class="kw2">   Hello World!   

Elements

See HTML elements for more detailed descriptions.

Elements are the basic structure for HTML markup. Elements have two basic properties: attributes and content. Each attribute and each element's content has certain restrictions that must be followed for an HTML document to be considered valid. An element usually has a start tag (e.g. ) and an end tag (e.g. ). The element's attributes are contained in the start tag and content is located between the tags (e.g. Content). Some elements, such as
, do not have any content and must not have a closing tag. Listed below are several types of markup elements used in HTML.

Structural markup describes the purpose of text. For example,

Golf

establishes "Golf" as a second-level heading, which would be rendered in a browser in a manner similar to the "HTML markup" title at the start of this section. Structural markup does not denote any specific rendering, but most Web browsers have standardized on how elements should be formatted. Text may be further styled with Cascading Style Sheets (CSS).

Presentational markup describes the appearance of the text, regardless of its function. For example boldface indicates that visual output devices should render "boldface" in bold text, but gives no indication what devices which are unable to do this (such as aural devices that read the text aloud) should do. In the case of both bold and italic, there are elements which usually have an equivalent visual rendering but are more semantic in nature, namely strong emphasis and emphasis respectively. It is easier to see how an aural user agent should interpret the latter two elements. However, they are not equivalent to their presentational counterparts: it would be undesirable for a screen-reader to emphasize the name of a book, for instance, but on a screen such a name would be italicized. Most presentational markup elements have become deprecated under the HTML 4.0 specification, in favor of CSS based style design.

Hypertext markup links parts of the document to other documents. HTML up through version XHTML 1.1 requires the use of an anchor element to create a hyperlink in the flow of text: Wikipedia. However, the href attribute must also be set to a valid URL so for example the HTML code, Wikipedia, will render the word "Wikipedia" as a hyperlink.To link on an image, the anchor tag use the following syntax:

Attributes

Most of the attributes of an element are name-value pairs, separated by "=", and written within the start tag of an element, after the element's name. The value may be enclosed in single or double quotes, although values consisting of certain characters can be left unquoted in HTML (but not XHTML).[14][15] Leaving attribute values unquoted is considered unsafe.[16] In contrast with name-value pair attributes, there are some attributes that affect the element simply by their presence in the start tag of the element[17] (like the ismap attribute for the img element[18]).

Most elements can take any of several common attributes:

  • The id attribute provides a document-wide unique identifier for an element. This can be used by stylesheets to provide presentational properties, by browsers to focus attention on the specific element, or by scripts to alter the contents or presentation of an element.
  • The class attribute provides a way of classifying similar elements for presentation purposes. For example, an HTML document might use the designation class="notation" to indicate that all elements with this class value are subordinate to the main text of the document. Such elements might be gathered together and presented as footnotes on a page instead of appearing in the place where they occur in the HTML source.
  • An author may use the style non-attributal codes presentational properties to a particular element. It is considered better practice to use an element’s son- id page and select the element with a stylesheet, though sometimes this can be too cumbersome for a simple ad hoc application of styled properties.
  • The title attribute is used to attach subtextual explanation to an element. In most browsers this attribute is displayed as what is often referred to as a tooltip.

The generic inline element span can be used to demonstrate these various attributes:

  id="anId" class="aClass" style="color:blue;" title="Hypertext Markup Language">HTML 

This example displays as HTML; in most browsers, pointing the cursor at the abbreviation should display the title text "Hypertext Markup Language."

Most elements also take the language-related attributes lang and dir.

Character and entity references

As of version 4.0, HTML defines a set of 252 character entity references and a set of 1,114,050 numeric character references, both of which allow individual characters to be written via simple markup, rather than literally. A literal character and its markup counterpart are considered equivalent and are rendered identically.

The ability to "escape" characters in this way allows for the characters < and & (when written as < and &, respectively) to be interpreted as character data, rather than markup. For example, a literal < normally indicates the start of a tag, and & normally indicates the start of a character entity reference or numeric character reference; writing it as & or & or & allows & to be included in the content of elements or the values of attributes. The double-quote character ("), when used to quote an attribute value, must also be escaped as " or " or " when it appears within the attribute value itself. The single-quote character ('), when used to quote an attribute value, must also be escaped as ' or ' (should NOT be escaped as ' except in XHTML documents) when it appears within the attribute value itself. However, since document authors often overlook the need to escape these characters, browsers tend to be very forgiving, treating them as markup only when subsequent text appears to confirm that intent.

Escaping also allows for characters that are not easily typed or that aren't even available in the document's character encoding to be represented within the element and attribute content. For example, the acute-accented e (é), a character typically found only on Western European keyboards, can be written in any HTML document as the entity reference é or as the numeric references é or é. The characters comprising those references (that is, the &, the ;, the letters in eacute, and so on) are available on all keyboards and are supported in all character encodings, whereas the literal é is not.

Data types

HTML defines several data types for element content, such as script data and stylesheet data, and a plethora of types for attribute values, including IDs, names, URIs, numbers, units of length, languages, media descriptors, colors, character encodings, dates and times, and so on. All of these data types are specializations of character data.

The Document Type Declaration

In order to enable Document Type Definition (DTD)-based validation with SGML tools and in order to avoid the quirks mode in browsers, HTML documents can start with a Document Type Declaration (informally, a "DOCTYPE"). The DTD to which the DOCTYPE refers contains machine-readable grammar specifying the permitted and prohibited content for a document conforming to such a DTD. Browsers do not necessarily read the DTD, however. The most popular graphical browsers use DOCTYPE declarations (or the lack thereof) and other data at the beginning of sources to determine which rendering mode to use.

For example:

This declaration references the Strict DTD of HTML 4.01, which does not have presentational elements like , leaving formatting to Cascading Style Sheets and the span and div tags. SGML-based validators read the DTD in order to properly parse the document and to perform validation. In modern browsers, the HTML 4.01 Strict doctype activates standards layout mode for CSS as opposed to quirks mode.

In addition, HTML 4.01 provides Transitional and Frameset DTDs. The Transitional DTD was intended to gradually phase in the changes made in the Strict DTD, while the Frameset DTD was intended for those documents which contained frames.

Semantic HTML

There is no official specification called "Semantic HTML", though the strict flavors of HTML discussed below are a push in that direction. Rather, semantic HTML refers to an objective and a practice to create documents with HTML that contain only the author's intended meaning, without any reference to how this meaning is presented or conveyed. A classic example is the distinction between the emphasis element () and the italics element (). Often the emphasis element is displayed in italics, so the presentation is typically the same. However, emphasizing something is different from listing the title of a book, for example, which may also be displayed in italics. In purely semantic HTML, a book title would use a different element than emphasized text uses (for example a ), because they are meaningfully different things.

The goal of semantic HTML requires two things of authors:

  1. To avoid the use of presentational markup (elements, attributes, and other entities).
  2. To use available markup to differentiate the meanings of phrases and structure in the document. So for example, the book title from above would need to have its own element and class specified, such as The Grapes of Wrath. Here, the element is used because it most closely matches the meaning of this phrase in the text. However, the element is not specific enough to this task, since we mean to cite specifically a book title as opposed to a newspaper article or an academic journal.

Semantic HTML also requires complementary specifications and software compliance with these specifications. Primarily, the development and proliferation of CSS has led to increasing support for semantic HTML, because CSS provides designers with a rich language to alter the presentation of semantic-only documents. With the development of CSS, the need to include presentational properties in a document has virtually disappeared. With the advent and refinement of CSS and the increasing support for it in Web browsers, subsequent editions of HTML increasingly stress only using markup that suggests the semantic structure and phrasing of the document, like headings, paragraphs, quotes, and lists, instead of using markup which is written for visual purposes only, like , (bold), and (italics). Some of these elements are not permitted in certain varieties of HTML, like HTML 4.01 Strict. CSS provides a way to separate document semantics from the content's presentation, by keeping everything relevant to presentation defined in a CSS file. See separation of style and content.

Semantic HTML offers many advantages. First, it ensures consistency in style across elements that have the same meaning. Every heading, every quotation, every similar element receives the same presentation properties.

Second, semantic HTML frees authors from the need to concern themselves with presentation details. When writing the number two, for example, should it be written out in words ("two"), or should it be written as a numeral (2)? A semantic markup might enter something like 2 and leave presentation details to the stylesheet designers. Similarly, an author might wonder where to break out quotations into separate indented blocks of text: with purely semantic HTML, such details would be left up to stylesheet designers. Authors would simply indicate quotations when they occur in the text, and not concern themselves with presentation.

A third advantage is device independence and repurposing of documents. A semantic HTML document can be paired with any number of stylesheets to provide output to computer screens (through Web browsers), high-resolution printers, handheld devices, aural browsers or braille devices for those with visual impairments, and so on. To accomplish this, nothing needs to be changed in a well-coded semantic HTML document. Readily available stylesheets make this a simple matter of pairing a semantic HTML document with the appropriate stylesheets. (Of course, the stylesheet's selectors need to match the appropriate properties in the HTML document.)

Some aspects of authoring documents make separating semantics from style (in other words, meaning from presentation) difficult. Some elements are hybrids, using presentation in their very meaning. For example, a table displays content in a tabular form. Often such content conveys the meaning only when presented in this way. Repurposing a table for an aural device typically involves somehow presenting the table as an inherently visual element in an audible form. On the other hand, we frequently present lyrical songs—something inherently meant for audible presentation—and instead present them in textual form on a Web page. For these types of elements, the meaning is not so easily separated from their presentation. However, for a great many of the elements used and meanings conveyed in HTML, the translation is relatively smooth.

Delivery of HTML

HTML documents can be delivered by the same means as any other computer file; however, they are most often delivered in one of two forms: over HTTP servers and through e-mail.

Publishing HTML with HTTP

The World Wide Web is composed primarily of HTML documents transmitted from a Web server to a Web browser using the Hypertext Transfer Protocol (HTTP). However, HTTP can be used to serve images, sound, and other content in addition to HTML. To allow the Web browser to know how to handle the document it received, an indication of the file format of the document must be transmitted along with the document. This vital metadata includes the MIME type (text/html for HTML 4.01 and earlier, application/xhtml+xml for XHTML 1.0 and later) and the character encoding (see Character encodings in HTML).

In modern browsers, the MIME type that is sent with the HTML document affects how the document is interpreted. A document sent with an XHTML MIME type, or served as application/xhtml+xml, is expected to be well-formed XML, and a syntax error causes the browser to fail to render the document. The same document sent with an HTML MIME type, or served as text/html, might be displayed successfully, since Web browsers are more lenient with HTML. However, XHTML parsed in this way is not considered either proper XHTML or HTML, but so-called tag soup.

If the MIME type is not recognized as HTML, the Web browser should not attempt to render the document as HTML, even if the document is prefaced with a correct Document Type Declaration. Nevertheless, some Web browsers do examine the contents or URL of the document and attempt to infer the file type, despite this being forbidden by the HTTP 1.1 specification.

HTML e-mail


Most graphical e-mail clients allow the use of a subset of HTML (often ill-defined) to provide formatting and semantic markup capabilities not available with plain text, like emphasized text, block quotations for replies, and diagrams or mathematical formulas that could not easily be described otherwise. Many of these clients include both a GUI editor for composing HTML e-mail messages and a rendering engine for displaying received HTML messages. Use of HTML in e-mail is controversial because of compatibility issues, because it can be used in phishing/privacy attacks, because it can confuse spam filters, and because the message size is larger than plain text.

Naming conventions

The most common filename extension for files containing HTML is .html. A common abbreviation of this is .htm; it originates from older operating systems and file systems, such as the DOS versions from the 80s and early 90s and FAT, which limit file extensions to three letters. Both forms are widely supported by browsers.

Current flavors of HTML

Since its inception, HTML and its associated protocols gained acceptance relatively quickly. However, no clear standards existed in the early years of the language. Though its creators originally conceived of HTML as a semantic language devoid of presentation details, practical uses pushed many presentational elements and attributes into the language, driven largely by the various browser vendors. The latest standards surrounding HTML reflect efforts to overcome the sometimes chaotic development of the language and to create a rational foundation for building both meaningful and well-presented documents. To return HTML to its role as a semantic language, the W3C has developed style languages such as CSS and XSL to shoulder the burden of presentation. In conjunction, the HTML specification has slowly reined in the presentational elements.

There are two axes differentiating various flavors of HTML as currently specified: SGML-based HTML versus XML-based HTML (referred to as XHTML) on the one axis, and strict versus transitional (loose) versus frameset on the other axis.

Traditional versus XML-based HTML

One difference in the latest HTML specifications lies in the distinction between the SGML-based specification and the XML-based specification. The XML-based specification is usually called XHTML to distinguish it clearly from the more traditional definition; however, the root element name continues to be 'html' even in the XHTML-specified HTML. The W3C intended XHTML 1.0 to be identical to HTML 4.01 except where limitations of XML over the more complex SGML require workarounds. Because XHTML and HTML are closely related, they are sometimes documented in parallel. In such circumstances, some authors conflate the two names as (X)HTML or X(HTML).[19]

Like HTML 4.01, XHTML 1.0 has three sub-specifications: strict, loose, and frameset.

Aside from the different opening declarations for a document, the differences between an HTML 4.01 and XHTML 1.0 document—in each of the corresponding DTDs—are largely syntactic. The underlying syntax of HTML allows many shortcuts that XHTML does not, such as elements with optional opening or closing tags, and even EMPTY elements which must not have an end tag. By contrast, XHTML requires all elements to have an opening tag or a closing tag. XHTML, however, also introduces a new shortcut: an XHTML tag may be opened and closed within the same tag, by including a slash before the end of the tag like this:
. The introduction of this shorthand, which is not used in the SGML declaration for HTML 4.01, may confuse earlier software unfamiliar with this new convention.

To understand the subtle differences between HTML and XHTML, consider the transformation of a valid and well-formed XHTML 1.0 document that adheres to Appendix C (see below) into a valid HTML 4.01 document. To make this translation requires the following steps:

  1. The language for an element should be specified with a lang attribute rather than the XHTML xml:lang attribute. XHTML uses XML's built in language-defining functionality attribute.
  2. Remove the XML namespace (xmlns=URI). HTML has no facilities for namespaces.
  3. Change the document type declaration from XHTML 1.0 to HTML 4.01. (see DTD section for further explanation).
  4. If present, remove the XML declaration. (Typically this is: ).
  5. Ensure that the document’s MIME type is set to text/html. For both HTML and XHTML, this comes from the HTTP Content-Type header sent by the server.
  6. Change the XML empty-element syntax to an HTML style empty element (
    to
    ).

Those are the main changes necessary to translate a document from XHTML 1.0 to HTML 4.01. To translate from HTML to XHTML would also require the addition of any omitted opening or closing tags. Whether coding in HTML or XHTML it may just be best to always include the optional tags within an HTML document rather than remembering which tags can be omitted.

A well-formed XHTML document adheres to all the syntax requirements of XML. A valid document adheres to the content specification for XHTML, which describes the document structure.

The W3C recommends several conventions to ensure an easy migration between HTML and XHTML (see HTML Compatibility Guidelines). The following steps can be applied to XHTML 1.0 documents only:

  • Include both xml:lang and lang attributes on any elements assigning language.
  • Use the empty-element syntax only for elements specified as empty in HTML.
  • Include an extra space in empty-element tags: for example
    instead of
    .
  • Include explicit close tags for elements that permit content but are left empty (for example,
    , not
    ).
  • Omit the XML declaration.

By carefully following the W3C’s compatibility guidelines, a user agent should be able to interpret the document equally as HTML or XHTML. For documents that are XHTML 1.0 and have been made compatible in this way, the W3C permits them to be served either as HTML (with a text/html MIME type), or as XHTML (with an application/xhtml+xml or application/xml MIME type). When delivered as XHTML, browsers should use an XML parser, which adheres strictly to the XML specifications for parsing the document's contents.

Transitional versus Strict

The latest SGML-based specification HTML 4.01 and the earliest XHTML version include three sub-specifications: Strict, Transitional (once called Loose), and Frameset. The Strict variant represents the standard proper, whereas the Transitional and Frameset variants were developed to assist in the transition from earlier versions of HTML (including HTML 3.2). The Transitional and Frameset variants allow for presentational markup whereas the Strict variant encourages the use of style sheets through its omission of most presentational markup.

The primary differences which make the Transitional variant more permissive than the Strict variant (the differences as the same in HTML 4 and XHTML 1.0) are:

  • A looser content model
    • Inline elements and plain text (#PCDATA) are allowed directly in: body, blockquote, form, noscript and noframes
  • Presentation related elements
    • underline (u)
    • strike-through (s and strike)
    • center
    • font
    • basefont
  • Presentation related attributes
    • background and bgcolor attributes for body element.
    • align attribute on div, form, paragraph (p), and heading (h1...h6) elements
    • align, noshade, size, and width attributes on hr element
    • align, border, vspace, and hspace attributes on img and object elements
    • align attribute on legend and caption elements
    • align and bgcolor on table element
    • nowrap, bgcolor, width, height on td and th elements
    • bgcolor attribute on tr element
    • clear attribute on br element
    • compact attribute on dl, dir and menu elements
    • type, compact, and start attributes on ol and ul elements
    • type and value attributes on li element
    • width attribute on pre element
  • Additional elements in Transitional specification
    • menu list (no substitute, though unordered list is recommended; may return in XHTML 2.0 specification)
    • dir list (no substitute, though unordered list is recommended)
    • isindex (element requires server-side support and is typically added to documents server-side)
    • applet (deprecated in favor of object element)
  • The language attribute on script element (presumably redundant with type attribute, though this is maintained for legacy reasons).
  • Frame related entities
    • frameset element (used in place of body for frameset DTD)
    • frame element
    • iframe
    • noframes
    • target attribute on anchor, client-side image-map (imagemap), link, form, and base elements

Frameset versus transitional

In addition to the above transitional differences, the frameset specifications (whether XHTML 1.0 or HTML 4.01) specifies a different content model:

   </span></span><span class="sc2"><span class="kw2">         </span></span> <span class="sc2"><span class="kw2"><body></span></span><span class="sc2"><span class="kw2"></body></span></span> <span class="sc2"><span class="kw2">   

Summary of flavors

As this list demonstrates, the loose flavors of the specification are maintained for legacy support. However, contrary to popular misconceptions, the move to XHTML does not imply a removal of this legacy support. Rather the X in XML stands for extensible and the W3C is modularizing the entire specification and opening it up to independent extensions. The primary achievement in the move from XHTML 1.0 to XHTML 1.1 is the modularization of the entire specification. The strict version of HTML is deployed in XHTML 1.1 through a set of modular extensions to the base XHTML 1.1 specification. Likewise someone looking for the loose (transitional) or frameset specifications will find similar extended XHTML 1.1 support (much of it is contained in the legacy or frame modules). The modularization also allows for separate features to develop on their own timetable. So for example XHTML 1.1 will allow quicker migration to emerging XML standards such as MathML (a presentational and semantic math language based on XML) and XForms — a new highly advanced web-form technology to replace the existing HTML forms.

In summary, the HTML 4.01 specification primarily reined in all the various HTML implementations into a single clear written specification based on SGML. XHTML 1.0, ported this specification, as is, to the new XML defined specification. Next, XHTML 1.1 takes advantage of the extensible nature of XML and modularizes the whole specification. XHTML 2.0 will be the first step in adding new features to the specification in a standards-body-based approach.

Hypertext features not in HTML

HTML lacks some of the features found in earlier hypertext systems, such as typed links, transclusion, source tracking, fat links, and more.[20] Even some hypertext features that were in early versions of HTML have been ignored by most popular web browsers until recently, such as the link element and in-browser Web page editing.

Sometimes Web services or browser manufacturers remedy these shortcomings. For instance, wikis and content management systems allow surfers to edit the Web pages they visit.

Read More..

Color

Color

Color is an important part of human expression.Enlarge picture
Color is an important part of human expression.

Color or colour[1] is the visual perceptual property corresponding in humans to the categories called red, yellow, blue, black, etc. Color derives from the spectrum of light (distribution of light energy versus wavelength) interacting in the eye with the spectral sensitivities of the light receptors. Color categories and physical specifications of color are also associated with objects, materials, light sources, etc., based on their physical properties such as light absorption, reflection, or emission spectra.

Typically, only features of the composition of light that are detectable by humans (wavelength spectrum from 400 nm to 700 nm, roughly) are included, thereby objectively relating the psychological phenomenon of color to its physical specification. Because perception of color stems from the varying sensitivity of different types of cone cells in the retina to different parts of the spectrum, colors may be defined and quantified by the degree to which they stimulate these cells. These physical or physiological quantifications of color, however, do not fully explain the psychophysical perception of color appearance.

The science of color is sometimes called chromatics. It includes the perception of color by the human eye and brain, the origin of color in materials, color theory in art, and the physics of electromagnetic radiation in the visible range (that is, what we commonly refer to simply as Light).

Colorful reflections upon waterEnlarge picture
Colorful reflections upon water

Physics of color

Continuous optical spectrum (designed for monitors with gamma 1.5).Enlarge picture
Continuous optical spectrum (designed for monitors with gamma 1.5).
The colors of the visible light spectrum[2]
color wavelength interval frequency interval
red ~ 630–700 nm ~ 480–430 THz
orange ~ 590–630 nm ~ 510–480 THz
yellow ~ 560–590 nm ~ 540–510 THz
green ~ 490–560 nm ~ 610–540 THz
blue ~ 450–490 nm ~ 670–610 THz
violet ~ 400–450 nm ~ 750–670 THz
Color, wavelength, frequency and energy of light
Color \lambda \,\!/nm \nu \,\!/1014 Hz \nu_b \,\!/104 cm−1 E \,\!/eV E \,\!/kJ mol−1
Infrared >1000 <3.00 <1.00 <1.24 <120
Red 700 4.28 1.43 1.77 171
Orange 620 4.84 1.61 2.00 193
Yellow 580 5.17 1.72 2.14 206
Green 530 5.66 1.89 2.34 226
Blue 470 6.38 2.13 2.64 254
Violet 420 7.14 2.38 2.95 285
Near ultraviolet 300 10.0 3.33 4.15 400
Far ultraviolet <200 >15.0 >5.00 >6.20 >598

Electromagnetic radiation is characterized by its wavelength (or frequency) and its intensity. When the wavelength is within the visible spectrum (the range of wavelengths humans can perceive, approximately from 380 nm to 740 nm), it is known as "visible light".

Most light sources emit light at many different wavelengths; a source's spectrum is a distribution giving its intensity at each wavelength. Although the spectrum of light arriving at the eye from a given direction determines the color sensation in that direction, there are many more possible spectral combinations than color sensations. In fact, one may formally define a color as a class of spectra that give rise to the same color sensation, although such classes would vary widely among different species, and to a lesser extent among individuals within the same species. In each such class the members are called metamers of the color in question.

Spectral colors

The familiar colors of the rainbow in the spectrum – named using the Latin word for appearance or apparition by Isaac Newton in 1671 – include all those colors that can be produced by visible light of a single wavelength only, the pure spectral or monochromatic colors. The table at right shows approximate frequencies (in terahertz) and wavelengths (in nanometers) for various pure spectral colors. The wavelengths are measured in vacuum (see refraction).

The color table should not be interpreted as a definitive list – the pure spectral colors form a continuous spectrum, and how it is divided into distinct colors is a matter of culture, taste, and language. A common list identifies six main bands: red, orange, yellow, green, blue, and violet. Newton's conception included a seventh color, indigo, between blue and violet – but most people do not distinguish it, and most color scientists do not recognize it as a separate color; it is sometimes designated as wavelengths of 420–440 nm.

The intensity of a spectral color may alter its perception considerably; for example, a low-intensity orange-yellow is brown, and a low-intensity yellow-green is olive-green.

As discussed in the section on color vision, a light source need not actually be of one single wavelength to be perceived as a pure spectral color.

For discussion of non-spectral colors, see below.

Color of objects

The upper disk and the lower disk have exactly the same objective color, and are in identical gray surrounds; based on context differences, humans perceive the squares as having different reflectances, and may interpret the colors as different color categories; see same color illusion.Enlarge picture
The upper disk and the lower disk have exactly the same objective color, and are in identical gray surrounds; based on context differences, humans perceive the squares as having different reflectances, and may interpret the colors as different color categories; see same color illusion.

The color of an object depends on both the physics of the object in its environment and the characteristics of the perceiving eye and brain. Physically, objects can be said to have the color of the light leaving their surfaces, which normally depends on the spectrum of that light and of the incident illumination, as well as potentially on the angles of illumination and viewing. Some objects not only reflect light, but also transmit light or emit light themselves (see below), which contribute to the color also. And a viewer's perception of the object's color depends not only on the spectrum of the light leaving its surface, but also on a host of contextual cues, so that the color tends to be perceived as relatively constant: that is, relatively independent of the lighting spectrum, viewing angle, etc. This effect is known as color constancy.

Some generalizations of the physics can be drawn, neglecting perceptual effects for now:

  • Light arriving at an opaque surface is either reflected "specularly" (that is, in the manner of a mirror), scattered (that is, reflected with diffuse scattering), or absorbed – or some combination of these.
  • Opaque objects that do not reflect specularly (which tend to have rough surfaces) have their color determined by which wavelengths of light they scatter more and which they scatter less (with the light that is not scattered being absorbed). If objects scatter all wavelengths, they appear white. If they absorb all wavelengths, they appear black.
  • Opaque objects that specularly reflect light of different wavelengths with different efficiencies look like mirrors tinted with colors determined by those differences. An object that reflects some fraction of impinging light and absorbs the rest may look black but also be faintly reflective; examples are black objects coated with layers of enamel or lacquer.
  • Objects that transmit light are either translucent (scattering the transmitted light) or transparent (not scattering the transmitted light). If they also absorb (or reflect) light of varying wavelengths differentially, they appear tinted with a color determined by the nature of that absorption (or that reflectance).
  • Objects may emit light that they generate themselves, rather than merely reflecting or transmitting light. They may do so because of their elevated temperature (they are then said to be incandescent), as a result of certain chemical reactions (a phenomenon called chemoluminescence), or for other reasons (see the articles Phosphorescence and List of light sources).
  • Objects may absorb light and then as a consequence emit light that has different properties. They are then called fluorescent (if light is emitted only while light is absorbed) or phosphorescent (if light is emitted even after light ceases to be absorbed; this term is also sometimes loosely applied to light emitted due to chemical reactions).

For further treatment of the color of objects, see structural color, below.

To summarize, the color of an object is a complex result of its surface properties, its transmission properties, and its emission properties, all of which factors contribute to the mix of wavelengths in the light leaving the surface of the object. The perceived color is then further conditioned by the nature of the ambient illumination, and by the color properties of other objects nearby, via the effect known as color constancy and via other characteristics of the perceiving eye and brain.

Color perception

Normalized typical human cone cell responses (S, M, and L types) to monochromatic spectral stimuliEnlarge picture
Normalized typical human cone cell responses (S, M, and L types) to monochromatic spectral stimuli

Development of theories of color vision

Main article: Color theory

Although Aristotle and other ancient scientists had already written on the nature of light and color vision, it was not until Newton that light was identified as the source of the color sensation. In 1810, Goethe published his comprehensive Theory of Colors. In 1801 Thomas Young proposed his trichromatic theory, based on the observation that any color could be matched with a combination of three lights. This theory was later refined by James Clerk Maxwell and Hermann von Helmholtz. As Helmholtz puts it, "the principles of Newton's law of mixture were experimentally confirmed by Maxwell in 1856. Young's theory of color sensations, like so much else that this marvellous investigator achieved in advance of his time, remained unnoticed until Maxwell directed attention to it."[3]

At the same time as Helmholtz, Ewald Hering developed the opponent process theory of color, noting that color blindness and afterimages typically come in opponent pairs (red-green, blue-yellow, and black-white). Ultimately these two theories were synthesized in 1957 by Hurvich and Jameson, who showed that retinal processing corresponds to the trichromatic theory, while processing at the level of the lateral geniculate nucleus corresponds to the opponent theory.[4]

In 1931, an international group of experts known as the Commission Internationale d'Eclairage (CIE) developed a mathematical color model, which mapped out the space of observable colors and assigned a set of three numbers to each.

Color in the eye


The ability of the human eye to distinguish colors is based upon the varying sensitivity of different cells in the retina to light of different wavelengths. The retina contains three types of color receptor cells, or cones. One type, relatively distinct from the other two, is most responsive to light that we perceive as violet, with wavelengths around 420 nm. (Cones of this type are sometimes called short-wavelength cones, S cones, or, misleadingly, blue cones.) The other two types are closely related genetically and chemically. One of them (sometimes called long-wavelength cones, L cones, or, misleadingly, red cones) is most sensitive to light we perceive as yellowish-green, with wavelengths around 564 nm; the other type (sometimes called middle-wavelength cones, M cones, or, misleadingly, green cones) is most sensitive to light perceived as green, with wavelengths around 534 nm.

Light, no matter how complex its composition of wavelengths, is reduced to three color components by the eye. For each location in the visual field, the three types of cones yield three signals based on the extent to which each is stimulated. These values are sometimes called tristimulus values.

The response curve as a function of wavelength for each type of cone is illustrated above. Because the curves overlap, some tristimulus values do not occur for any incoming light combination. For example, it is not possible to stimulate only the mid-wavelength/"green" cones; the other cones will inevitably be stimulated to some degree at the same time. The set of all possible tristimulus values determines the human color space. It has been estimated that humans can distinguish roughly 10 million different colors.[5]

The other type of light-sensitive cell in the eye, the rod, has a different response curve. In normal situations, when light is bright enough to strongly stimulate the cones, rods play virtually no role in vision at all.[6] On the other hand, in dim light, the cones are understimulated leaving only the signal from the rods, resulting in a colorless response. (Furthermore, the rods are barely sensitive to light in the "red" range.) In certain conditions of intermediate illumination, the rod response and a weak cone response can together result in color discriminations not accounted for by cone responses alone.

Color in the brain


The visual dorsal stream (green) and ventral stream (purple) are shown. The ventral stream is responsible for color perception.Enlarge picture
The visual dorsal stream (green) and ventral stream (purple) are shown. The ventral stream is responsible for color perception.

While the mechanisms of color vision at the level of the retina are well-described in terms of tristimulus values (see above), color processing after that point is organized differently. A dominant theory of color vision proposes that color information is transmitted out of the eye by three opponent processes, or opponent channels, each constructed from the raw output of the cones: a red-green channel, a blue-yellow channel and a black-white "luminance" channel. This theory has been supported by neurobiology, and accounts for the structure of our subjective color experience. Specifically, it explains why we cannot perceive a "reddish green" or "yellowish blue," and it predicts the color wheel: it is the collection of colors for which at least one of the two color channels measures a value at one of its extremes.

The exact nature of color perception beyond the processing already described, and indeed the status of color as a feature of the perceived world or rather as a feature of our perception of the world, is a matter of complex and continuing philosophical dispute (see qualia).

Nonstandard color perception

Color deficiency


If one or more types of a person's color-sensing cones are missing or less responsive than normal to incoming light, that person can distinguish fewer colors and is said to be color deficient or color blind (though this latter term can be misleading; almost all color deficient individuals can distinguish at least some colors). Some kinds of color deficiency are caused by anomalies in the number or nature of cones in the retina. Others (like central or cortical achromatopsia) are caused by neural anomalies in those parts of the brain where visual processing takes place.

Tetrachromacy


While most humans are trichromatic (having three types of color receptors), many animals, known as tetrachromats, have four types. These include some species of spiders, most marsupials, birds, reptiles, and many species of fish. Other species are sensitive to only two axes of color or do not perceive color at all; these are called dichromats and monochromats respectively. A distinction is made between retinal tetrachromacy (having four pigments in cone cells in the retina, compared to three in trichromats) and functional tetrachromacy (having the ability to make enhanced color discriminations based on that retinal difference). As many as half of all women, but only a small percentage of men, are retinal tetrachromats.[7] The phenomenon arises when an individual receives two slightly different copies of the gene for either the medium- or long-wavelength cones, which are carried on the x-chromosome, accounting for the differences between genders.[7] For some of these retinal tetrachromats, color discriminations are enhanced, making them functional tetrachromats.[7]

Synesthesia

In certain forms of synesthesia, perceiving letters and numbers (grapheme–color synesthesia) or hearing musical sounds (music–color synesthesia) will lead to the unusual additional experiences of seeing colors. Behavioral and functional neuroimaging experiments have demonstrated that these color experiences lead to changes in behavioral tasks and lead to increased activation of brain regions involved in color perception, thus demonstrating their reality, and similarity to real color percepts, albeit evoked through a non-standard route.

Afterimages

After exposure to strong light in their sensitivity range, photoreceptors of a given type become desensitized. For a few seconds after the light ceases, they will continue to signal less strongly than they otherwise would. Colors observed during that period will appear to lack the color component detected by the desensitized photoreceptors. This effect is responsible for the phenomenon of afterimages, in which the eye may continue to see a bright figure after looking away from it, but in a complementary color.

Afterimage effects have also been utilized by artists, including Vincent van Gogh.

Color constancy


There is an interesting phenomenon which occurs when an artist uses a limited color palette: the eye tends to compensate by seeing any grey or neutral color as the color which is missing from the color wheel. E.g., in a limited palette consisting of red, yellow, black and white, a mixture of yellow and black will appear as a variety of green, a mixture of red and black will appear as a variety of purple, and pure grey will appear bluish.

The trichromatric theory discussed above is strictly true only if the whole scene seen by the eye is of one and the same color, which of course is unrealistic. In reality, the brain compares the various colors in a scene, in order to eliminate the effects of the illumination. If a scene is illuminated with one light, and then with another, as long as the difference between the light sources stays within a reasonable range, the colors of the scene will nevertheless appear constant to us. This was studied by Edwin Land in the 1970s and led to his retinex theory of color constancy.

Color naming


Colors vary in several different ways, including hue (red vs. orange vs. blue), saturation, brightness, and gloss. Some color words are derived from the name of an object of that color, such as "orange" or "salmon", while others are abstract, like "red".

Different cultures have different terms for colors, and may also assign some color names to slightly different parts of the spectrum: for instance, the Chinese character 青 (rendered as qīng in Mandarin and ao in Japanese) has a meaning that covers both blue and green; blue and green are traditionally considered shades of "青."

In the 1969 study Basic Color Terms: Their Universality and Evolution, Brent Berlin and Paul Kay describe a pattern in naming "basic" colors (like "red" but not "red-orange" or "dark red" or "blood red", which are "shades" of red). All languages that have two "basic" color names distinguish dark/cool colors from bright/warm colors. The next colors to be distinguished are usually red and then blue or green. All languages with six "basic" colors include black, white, red, green, blue and yellow. The pattern holds up to a set of twelve: black, grey, white, pink, red, orange, yellow, green, blue, purple, brown, and azure (distinct from blue in Russian and Italian but not English).

Associations

Individual colors have a variety of cultural associations such as national colors (in general described in individual color articles and color symbolism). The field of color psychology attempts to identify the effects of color on human emotion and activity. Chromotherapy is a form of alternative medicine attributed to various Eastern traditions.

Health effects

When the color spectrum of artificial lighting is mismatched to that of sunlight, material health effects may arise including increased incidence of headache. This phenomenon is often coupled with adverse effects of over-illumination, since many of the same interior spaces that have color mismatch also have higher light intensity than desirable for the task being conducted in that space.

Measurement and reproduction of color

Relation to spectral colors

The CIE 1931 color space chromaticity diagram. The outer curved boundary is the spectral (or monochromatic) locus, with wavelengths shown in nanometers. Note that the colors depicted depend on the color space of the device on which you are viewing the image, and therefore may not be a strictly accurate representation of the color at a particular position, and especially not for monochromatic colors.Enlarge picture
The CIE 1931 color space chromaticity diagram. The outer curved boundary is the spectral (or monochromatic) locus, with wavelengths shown in nanometers. Note that the colors depicted depend on the color space of the device on which you are viewing the image, and therefore may not be a strictly accurate representation of the color at a particular position, and especially not for monochromatic colors.

Most light sources are mixtures of various wavelengths of light. However, many such sources can still have a spectral color insofar as the eye cannot distinguish them from monochromatic sources. For example, most computer displays reproduce the spectral color orange as a combination of red and green light; it appears orange because the red and green are mixed in the right proportions to allow the eye's red and green cones to respond the way they do to orange.

A useful concept in understanding the perceived color of a non-monochromatic light source is the dominant wavelength, which identifies the single wavelength of light which produces a sensation most similar to the light source. Dominant wavelength is roughly akin to hue.

Of course, there are many color perceptions that by definition cannot be pure spectral colors due to desaturation or because they are purples (mixtures of red and violet light, from opposite ends of the spectrum). Some examples of necessarily non-spectral colors are the achromatic colors (black, gray and white) and colors such as pink, tan, and magenta.

Two different light spectra which have the same effect on the three color receptors in the human eye will be perceived as the same color. This is exemplified by the white light that is emitted by fluorescent lamps, which typically has a spectrum consisting of a few narrow bands, while daylight has a continuous spectrum. The human eye cannot tell the difference between such light spectra just by looking into the light source, although reflected colors from objects can look different. (This is often exploited e.g. to make fruit or tomatoes look more brightly red in shops.)

Similarly, most human color perceptions can be generated by a mixture of three colors called primaries. This is used to reproduce color scenes in photography, printing, television and other media. There are a number of methods or color spaces for specifying a color in terms of three particular primary colors. Each method has its advantages and disadvantages depending on the particular application.

No mixture of colors, though, can produce a fully pure color perceived as completely identical to a spectral color, although one can get very close for the longer wavelengths, where the chromaticity diagram above has a nearly straight edge. For example, mixing green light (530 nm) and blue light (460 nm) produces cyan light that is slightly desaturated, because response of the red color receptor would be greater to the green and blue light in the mixture than it would be to a pure cyan light at 485 nm that has the same intensity as the mixture of blue and green.

Because of this, and because the primaries in color printing systems generally are not pure themselves, the colors reproduced are never perfectly saturated colors, and so spectral colors cannot be matched exactly. However, natural scenes rarely contain fully saturated colors, thus such scenes can usually be approximated well by these systems. The range of colors that can be reproduced with a given color reproduction system is called the gamut. The CIE chromaticity diagram can be used to describe the gamut.

Another problem with color reproduction systems is connected with the acquisition devices, like cameras or scanners. The characteristics of the color sensors in the devices are often very far from the characteristics of the receptors in the human eye. In effect, acquisition of colors that have some special, often very "jagged," spectra caused for example by unusual lighting of the photographed scene can be relatively poor.

Species that have color receptors different from humans, e.g. birds that may have four receptors, can differentiate some colors that look the same to a human. In such cases, a color reproduction system 'tuned' to a human with normal color vision may give very inaccurate results for the other observers.

The next problem is different color response of different devices. For color information stored and transferred in a digital form, color management technique based on ICC profiles attached to color data and to devices with different color response helps to avoid deformations of the reproduced colors. The technique works only for colors in gamut of the particular devices, e.g. it can still happen that your monitor is not able to show you real color of your goldfish even if your camera can receive and store the color information properly and vice versa.

Pigments and reflective media


Pigments are chemicals that selectively absorb and reflect different spectra of light. When a surface is painted with a pigment, light hitting the surface is reflected, minus some wavelengths. This subtraction of wavelengths produces the appearance of different colors. Most paints are a blend of several chemical pigments, intended to produce a reflection of a given color.

Pigment manufacturers assume the source light will be white, or of roughly equal intensity across the spectrum. If the light is not a pure white source (as in the case of nearly all forms of artificial lighting), the resulting spectrum will appear a slightly different color. Red paint, viewed under blue light, may appear black. Red paint is red because it reflects only the red components of the spectrum. Blue light, containing none of these, will create no reflection from red paint, creating the appearance of black.

Structural color

Structural colors are colors caused by interference effects rather than by pigments. Color effects are produced when a material is scored with fine parallel lines, formed of a thin layer or of two or more parallel thin layers, or otherwise composed of microstructures on the scale of the color's wavelength. If the microstructures are spaced randomly, light of shorter wavelengths will be scattered preferentially to produce Tyndall effect colors: the blue of the sky, the luster of opals, and the blue of human irises. If the microstructures are aligned in arrays, for example the array of pits in a CD, they behave as a diffraction grating: the grating reflects different wavelengths in different directions due to interference phenomena, separating mixed "white" light into light of different wavelengths. If the structure is one or more thin layers then it will reflect some wavelengths and transmit others, depending on the layers' thickness.

Structural color is responsible for the blues and greens of the feathers of many birds (the blue jay, for example), as well as certain butterfly wings and beetle shells. Variations in the pattern's spacing often give rise to an iridescent effect, as seen in peacock feathers, soap bubbles, films of oil, and mother of pearl, because the reflected color depends upon the viewing angle. Peter Vukusic has carried out research in butterfly wings and beetle shells using electron micrography, and has since helped develop a range of "photonic" cosmetics using structural color.[8]

Structural color is studied in the field of thin-film optics. A layman's term that describes particularly the most ordered or the most changeable structural colors is iridescence.

Additional terms

  • Hue: the color's direction from white, for example in a color wheel or chromaticity diagram.
  • Colorfulness, chroma, or saturation: how "intense" or "concentrated" a color is; also known as chroma or purity.
  • Value, brightness, or lightness: how light or dark a color is.
  • Tint: a color made lighter by adding white.
  • Shade: a color made darker by adding black.

Read More..