HTML renderer

from Wikipedia, the free encyclopedia
Distribution of various HTML renderers between 1994 and 2009.

An HTML renderer , often called a browser engine , is a program for visualizing Hypertext Markup Language and Scalable Vector Graphics . "Visualization" here means the implementation of the image synthesis .

HTML was originally a (structural) description of text, a type of rich text with hyperlink functionality, called " IIRC Hypertext" by the inventor of the World Wide Web , Tim Berners-Lee . Although there are HTML attributes that directly describe the appearance of the element (such as the font size), these are classified as obsolete in XHTML and newer standards and are only supported for reasons of compatibility.

This reflects that HTML is not intended to dictate how a document should be displayed. This makes HTML so flexible that it can B. in a projector presentation, on a computer monitor, a PDA or a black and white LCD can be displayed. All these display devices have different options for the visual design of the content. Since HTML does not define such a design, the display program can interpret the HTML for a specific display device and design the visual layout more or less freely.

The HTML renderer assigns a visual representation of the text to this rather semantic-structural definition.

This is done in almost all browsers using Cascading Style Sheets (CSS). The style sheets contain a list of selectors (conditions on the substructure of the HTML document that must be met in order for the rules to be applied) and rules (attributes that are applied to the visual representation associated with the corresponding substructure). By default , the browser delivers a standard stylesheet that formats most of the elements. CSS is very flexible. It is possible to exchange this set of rules completely per user or per document. This means that there are almost no limits to the display options.

An HTML renderer is part of a web browser that assigns a visual representation to a more semantically oriented document structure. A layout engine interprets the layout model that was defined by CSS and fills this layout with the text that has been semantically enriched by HTML.

functionality

Parsing

The HTML document is read in and its elements are structured. This process is called parsing . Almost every browser uses its own renderer for this. The standards for HTML documents are set and defined by the World Wide Web Consortium , among others . Different standards exist, but the syntax of the elements remains largely the same. The developer should use the so-called doctype to specify which standard is used. If the specified standard is not fully adhered to, the HTML document is not valid, the browser cannot interpret the elements correctly and incorrect displays can occur.

Generation of the Document Object Model

If the document was successfully read in, a so-called Document Object Model is created. This hierarchical structure contains information about the order and sub-elements (called children). The Document Object Model is still relevant after output, as client-side scripting languages ​​such as JavaScript can access it in order to manipulate it.

Reflow

The calculation of SGML structures (such as HTML ) is referred to as reflow. In this process, the basic geometry of the objects to be formatted is calculated - such as the height or width of an element. The objects to be formatted are called frames and are not to be confused with the frames that enable one HTML page to be loaded into another.

List of renderers

Graphically

Text based

Rendering of audio data

There is also rendering of audio data from HTML through a CSS sub-specification that is used to navigate a synthetic voice through CSS attributes when reading hypertext. However, rendering of audio data is not implemented in popular web browsers. Audio data can only be rendered in special application programs ( screen readers ) for blind or severely visually impaired people.

Individual evidence

  1. Disapproved HTML 4 elements ( memento of the original from June 2, 2017 in the Internet Archive ) Info: The archive link was inserted automatically and has not yet been checked. Please check the original and archive link according to the instructions and then remove this notice.  @1@ 2Template: Webachiv / IABot / webdesign.about.com
  2. Standard stylesheet of an older Firefox version
  3. ^ Chris Waterson: Notes on HTML Reflow. (No longer available online.) Mozilla Foundation, archived from the original on July 3, 2010 ; Retrieved July 15, 2008 (English). Info: The archive link was inserted automatically and has not yet been checked. Please check the original and archive link according to the instructions and then remove this notice. @1@ 2Template: Webachiv / IABot / www.mozilla.org
  4. Luca Caracciolo: Opera relies on Webkit: What does that mean for the further development of HTML? In: t3n magazine . February 14, 2013, accessed June 28, 2013 .
  5. ^ Upgrading to the new Microsoft Edge. January 15, 2020, accessed January 22, 2020 (American English).