|Developer(s)||Mozilla Foundation, Mozilla Corporation, Adobe Systems, and other contributors|
Gecko is designed to support open Internet standards, and is used by different applications to display web pages and, in some cases, an application's user interface itself (by rendering XUL). Gecko offers a rich programming API that makes it suitable for a wide variety of roles in Internet-enabled applications, such as web browsers, content presentation, and client/server.
Development of the layout engine now known as Gecko began at Netscape in 1997, following the company's purchase of DigitalStyle. The existing Netscape rendering engine, originally written for Netscape Navigator 1.0 and upgraded through the years, was slow, did not comply well with W3C standards, had limited support for dynamic HTML and lacked features such as incremental reflow (when the layout engine rearranges elements on the screen as new data is downloaded and added to the page). The new layout engine was developed in parallel with the old, with the intention being to integrate it into Netscape Communicator when it was mature and stable. At least one more major revision of Netscape was expected to be released with the old layout engine before the switch.
After the launch of the Mozilla project in early 1998, the new layout engine code was released under an open-source license. Originally unveiled as Raptor, the name had to be changed to NGLayout (next generation layout) due to trademark problems. Netscape later rebranded NGLayout as Gecko. While Mozilla Organization (the forerunner of the Mozilla Foundation) initially continued to use the NGLayout name (Gecko was a Netscape trademark), eventually the Gecko branding won out.
In October 1998, Netscape announced that its next browser would use Gecko (which was still called NGLayout at the time) rather than the old layout engine, requiring large parts of the application to be rewritten. While this decision was popular with web standards advocates, it was largely unpopular with Netscape developers, who were unhappy with the six months given for the rewrite. It also meant that most of the work done for Netscape Communicator 5.0 (including development on the Mariner improvements to the old layout engine) had to be abandoned. Netscape 6, the first Netscape release to incorporate Gecko, was released in November 2000 (the name Netscape 5 was never used).
As Gecko development continued, other applications and embedders began to make use of it. America Online, by this time Netscape's parent company, eventually adopted it for use in CompuServe 7.0 and AOL for Mac OS X (these products had previously embedded Internet Explorer). However, with the exception of a few betas, Gecko was never used in the main Microsoft Windows AOL client.
On July 15, 2003, AOL laid off the remaining Gecko developers and the Mozilla Foundation (formed on the same day) became the main steward of Gecko development. Today, Gecko is developed by employees of the Mozilla Corporation, employees of companies that contribute to the Mozilla project, and volunteers.
From the outset, Gecko was designed to support open Internet standards. Some of the standards Gecko supports include:
- CSS Level 2.1 (partial support for CSS 3)
- DOM Level 1 and 2 (partial support for DOM 3)
- HTML4 (partial support for HTML5—see Comparison of layout engines (HTML5))
- XForms (via an official extension)
- XHTML 1.0
- XML 1.0
- XSLT and XPath, implemented in TransforMiiX
Gecko also partially supports SVG 1.1. The SVG font, color profile, animation, view, and cursor modules are yet to be implemented and the filter and text modules are only partially implemented. The extensibility module is also implemented but is currently disabled.
In order to support web pages designed for legacy versions of Netscape and Internet Explorer, Gecko supports DOCTYPE switching. Documents with a modern DOCTYPE are rendered in standards compliance mode, which follows the W3C standards strictly. Documents that have no DOCTYPE or an older DOCTYPE are rendered in quirks mode, which emulates some of the non-standard oddities of Netscape Communicator 4.x; however, some of the 4.x features (such as layers) are not supported.
Gecko also has limited support for some non-standard Internet Explorer features, such as the marquee element and the
document.all property (though pages explicitly testing for
document.all will be told it is not supported).
Gecko is primarily used in web browsers, the earliest being Netscape 6 and Mozilla Suite (later renamed SeaMonkey). It is also used in other Mozilla web browser derivatives such as Firefox and Firefox for mobile and the implementation of the Internet Explorer-clone that is part of Wine. Mozilla also uses it in their Thunderbird email-client.
Products that have historically used Gecko include Pale Moon (now currently using Goanna), Songbird, Epiphany (now known as GNOME Web) and GNOME DevHelp both have replaced Gecko with WebKitGTK, Sunbird (calendar), and other web browsers including Swiftfox, Flock, Galeon, Camino, Minimo, Beonex Communicator, Kazehakase, and MicroB.
After Gecko 2.0, the version number was bumped to 5.0 to match Firefox 5, and from then on has been kept in sync with the major version number for both Firefox and Thunderbird, to reflect the fact that it is no longer a separate component.
In the Netscape era, a combination of poor technical and management decisions resulted in Gecko software bloat. Thus in 2001 Apple chose to fork KHTML, not Gecko, to create the WebKit engine for its Safari browser. However, by 2008 Mozilla had addressed some of the bloat problems, resulting in big performance improvements for Gecko.
In October 2016 Mozilla announced Quantum, an ongoing project encompassing several software development efforts to "build the next-generation web engine for Firefox users". It includes numerous improvements to Gecko, taken from the experimental Servo project. Firefox 57, also known as "Firefox Quantum", first shipping in November 2017, is the initial version with major components from the Quantum/Servo projects enabled. These include increased performance in the CSS and GPU rendering components. Additional components will be merged from Servo to Gecko incrementally in future versions.
Quantum is a Mozilla project encompassing several software development efforts to "build the next-generation web engine for Firefox users". It includes numerous improvements to the Gecko, largely incorporated from the experimental Servo project. Quantum also includes refinements to the user interface and interactions.
In 2013, Mozilla began the experimental Servo project, which is an engine designed from scratch with the goals of improving concurrency and parallelism while also reducing memory safety vulnerabilities. An important factor is writing Servo in the Rust programming language, also created by Mozilla, which is designed to generate compiled code with better memory safety, concurrency, and parallelism than compiled C++ code.
As of April 2016, Servo needed at least several years of development to become a full-featured browser engine. Thus the decision to start the Quantum project to bring stable portions of Servo into Firefox.
The Quantum project is composed of several sub-projects.
- Servo's parallel style sheet system integrated into Gecko. Benchmarks suggest that performance scales linearly with number of CPU cores. This was released in Firefox 57.
- Servo's rendering architecture, called WebRender, integrated into Gecko. WebRender replaces the immediate mode drawing model with a retained mode model that is more easily accelerated by the GPU by taking advantage of CSS/DOM's similarity to a scene graph. Worst-case scenario rendering in testing exceeds 60 frames per second.
- Gecko's existing compositor moved to its own process, isolating browser tabs from graphics driver related crashes. Since compositor crashes will not bring down the browser content process, the compositor process can be restarted transparently without losing user data. This was released in Firefox 53.
- Loosely inspired by Servo's Constellation architecture and Opera's Presto engine, Quantum DOM uses cooperatively scheduled threads within the DOM to increase responsiveness without increasing the number of processes and, thus, memory usage.
- An umbrella for user visible performance improvements driven by a team that works across Gecko components. Currently focused on real user performance improvements on major webapps, primarily G Suite and Facebook.
- A UI refresh of the entire application, with a strong focus on improving UI performance. Treated as a sister project to Quantum Flow. This was released in Firefox 57.
- Improve the performance of Necko, Gecko's networking layer, by moving more network activity off the main thread, context dependent prioritization of networking streams, and racing the cache layer with the network. This feature was released in Firefox 59.
- "Mozilla Licensing Policies". mozilla.org. Retrieved 2013-03-26.
- "Embedding Mozilla". Mozilla.org. 2012-10-25. Retrieved 2012-10-31.
- "Simple Firefox for Android build".
- Bergstrom, Lars; et al. (May 2016). "Engineering the Servo Web Browser Engine using Rust" (PDF). Proceedings of the International Conference on Software Engineering.
- "MPL 2 Upgrade". Retrieved 2012-08-18.
- "nglayout project: identity crisis". Mozilla.org. Archived from the original on 2011-06-29. Retrieved 2012-10-31.
- Jorge O. Castro (2004-06-15). "Ars Technica sits down with Scott Collins from Mozilla.org". Ars Technica. Retrieved 2017-02-16.
- "Mozilla CSS support chart". Developer.mozilla.org. 2012-08-04. Retrieved 2012-10-31.
- "ECMAScript 5 support in Mozilla". Developer.mozilla.org. 2013-11-14. Retrieved 2013-12-02.
- "Mozilla SVG Status". Mozilla.org. 2012-08-25. Retrieved 2012-10-31.
- "Mozilla Adds Undetectable document.all Support, Part of New Novell Linux Distribution?". Developer.mozilla.org. 2004-07-23. Retrieved 2018-02-07.
- "IE Uses Gecko Under Wine". Wine Wiki. Retrieved 2009-09-14.
- sdubois (24 June 2010). "Gecko". Free Software Foundation. Retrieved 23 May 2019.
- "Picasa 3.0 for Linux". Google. Archived from the original on 2009-01-07. Retrieved 2008-12-28.
- Martens, China (2007-01-03). "One Laptop Per Child readies 'Sugar' interface". IDG News Service. Archived from the original on 2008-01-18. Retrieved 2007-12-28.
- http://wiki.jswindle.com/index.php/Fedora#Working_Wine Archived June 11, 2012, at the Wayback Machine
- "Gecko versions and application versions". MDN. Retrieved 2013-11-18.
- "Not much in new Thunderbird 5, but roadmap looks promising". Ars Technica. Retrieved 2018-02-07.
- Paul Festa (2003-01-14). "Apple snub stings Mozilla". CNET Networks. Archived from the original on 2012-10-25. Retrieved 2017-02-16.
- David Baron (2003-01-09). "Thursday 2003-01-09". David Baron's weblog. self-published. Archived from the original on 2009-07-28. Retrieved 2017-02-16.
- Ryan Paul (2008-09-09). "Why Mozilla is committed to Gecko as WebKit popularity grows". Retrieved 2017-02-16.
- "Quantum". Mozilla Wiki. Retrieved 2017-04-20.
- Cimpanu, Catalin. "Mozilla Announces Quantum, a New Browser Engine for Firefox". softpedia. Retrieved 2016-11-07.
- Cimpanu, Catalin. "Mozilla Announces Quantum, a New Browser Engine for Firefox". softpedia. Retrieved 2017-02-17.
- "Firefox 57.0, See All New Features, Updates and Fixes". Mozilla. Retrieved 2018-10-30.
- "Introducing the New Firefox: Firefox Quantum – The Mozilla Blog". The Mozilla Blog. Retrieved 2018-10-30.
- "Servo remaining work". GitHub. Retrieved 2017-02-17.
- "The Changelog". The Changelog. Retrieved 2017-03-28.
- "Bay Area Rust Meetup February 2016". Air Mozilla. Retrieved 2017-03-28.
- "Firefox faster and more stable with the first big bytes of Project Quantum, simpler with compact themes and permissions redesign". Mozilla Blog. Retrieved 2017-04-27.
- "Servo Architecture". Youtube. Retrieved 2017-03-28.
- "Mozilla's Quantum Project". Bill McCloskey's Blog. 2016-10-27. Retrieved 2017-03-28.
- "Quantum Flow". Mozilla Wiki. Retrieved 2017-03-28.
- dolske (2017-05-18). "Photon Engineering Newsletter #1". Dolske's blog. Retrieved 2017-07-04.
- "TPE Necko/Projects - MozillaWiki". wiki.mozilla.org. Retrieved 2017-07-04.
- "Firefox 59 Release Notes". www.mozilla.org. Retrieved 2019-01-16.