Jump to content

Gecko (software)

From Wikipedia, the free encyclopedia
Gecko
Developer(s)Mozilla Foundation,Mozilla Corporation,Adobe Systems,and other contributors
Stable release
125 / 4 November 2022;20 months ago(4 November 2022)
Repository
Written inC++,JavaScript,Rust
TypeBrowser engine
LicenseMPL 2.0[1][2]
Websitedeveloper.mozilla.org/en-US/docs/Glossary/Gecko

Gecko(stylized as ɢecko) is abrowser enginedeveloped byMozilla.It is used in theFirefoxbrowser, theThunderbirdemail client,and many other projects.

Gecko is designed to supportopenInternet standards,and is used by different applications to displayweb pagesand, in some cases, an application'suser interfaceitself (by renderingXUL). Gecko offers a rich programmingAPIthat makes it suitable for a wide variety of roles in Internet-enabled applications, such asweb browsers,content presentation, andclient/server.[3]

Gecko is written inC++andJavaScript,[4][5]and, since 2016, additionally inRust.[6][7]It isfree and open-source softwaresubject to the terms of theMozilla Public Licenseversion 2.[8]Mozilla officially supports its use onAndroid,[4]Linux,macOS,andWindows.[9]

History[edit]

Development of the layout engine now known as Gecko began atNetscapein 1997, following the company's purchase ofDigitalStyle.The existing Netscape rendering engine, originally written forNetscape Navigator1.0 and upgraded through the years, was slow, did not comply well with W3C standards, had limited support fordynamic HTMLand 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 asRaptor,the name had to be changed toNGLayout(next generation layout) due totrademarkproblems. Netscape later rebranded NGLayout asGecko.WhileMozilla Organization(the forerunner of theMozilla Foundation) initially continued to use the NGLayout name (Gecko was a Netscape trademark),[10]eventually the Gecko branding won out.[citation needed]

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.[11]It also meant that most of the work done forNetscape Communicator 5.0(including development on theMarinerimprovements 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).[citation needed]

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 inCompuServe7.0 and AOL for Mac OS X (these products had previously embedded Internet Explorer). However, with the exception of a fewbetas,Gecko was never used in the mainMicrosoft WindowsAOL client.[citation needed]

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 theMozilla Corporation,employees of companies that contribute to the Mozilla project, and volunteers.[citation needed]

In October 2016, Mozilla announcedQuantum,an ongoing project encompassing severalsoftware developmentefforts to "build the next-generation web engine forFirefoxusers ". It included numerous improvements to Gecko, taken from the experimentalServoproject.[12][13]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 theCSSandGPUrendering components. Additional components will be merged from Servo to Gecko incrementally in future versions.[12]

In September 2018, Mozilla announced GeckoView, the foundation of Mozilla's next generation of mobile products based on a software library that makes Gecko reusable for Android, encompassing newer software development efforts to "decouple the engine itself from its user interface, and made it easy to embed in other applications". Firefox Focus 7.0, shipped in the same month,[14]is the initial version introduced GeckoView, with increased performance in median page loading.[15][16]Firefox Reality was also built with GeckoView.[15]In June 2019, Mozilla announced Firefox Preview as an ongoing project that focuses on building an Android web browser with GeckoView.[17]Firefox for Android 79, also known as "Firefox Daylight", first shipping in August 2020, is the first stable release of that with major components powered by GeckoView engine.[18]

Standards support[edit]

From the outset, Gecko was designed to support open Internet standards. Some of the standards Gecko supports include:

Gecko also supportsSVG.[20]

Legacy IE non-standard support[edit]

In order to supportweb pagesdesigned for legacy versions of Netscape and Internet Explorer, Gecko supportsDOCTYPEswitching. Documents with a modern DOCTYPE are rendered in standards compliance mode, which follows theW3Cstandards strictly. Documents that have no DOCTYPE or an older DOCTYPE are rendered inquirks mode,which emulates some of the non-standard oddities ofNetscape Communicator4.x; however, some of the 4.x features (such aslayers) are not supported.

Gecko also has limited support for some non-standard Internet Explorer features, such as themarquee elementand thedocument.allproperty (though pages explicitly testing fordocument.allwill be told it is not supported).[21]

Usage[edit]

Gecko is primarily used inweb browsers,the earliest beingNetscape 6andMozilla Suite(later renamedSeaMonkey). It is also used in other Mozilla web browser derivatives such asFirefoxandFirefox for mobileand the implementation of theInternet Explorer-clone that is part ofWine.[22]Mozilla also uses it in theirThunderbird email-client.

Other web browsers using Gecko includeGNU IceCat,[23]Waterfox,K-Meleon,Lunascape,Portable Firefox,Conkeror,Classilla,TenFourFox.

Gecko is also used bySugarfor theOLPC XO-1computer,[24]and is used as a complete implementation of theXUL(XMLUser Interface Language). Gecko currently defines the XUL specification.[needs update]Gecko is also used by theKaiOSmobile operating system, which is based on the discontinuedFirefox OS.[25]

Past users[edit]

Products that formerly used Gecko includePale Moon(now usingGoanna), Epiphany (now known asGNOME Weband usingWebKitGTK), andGNOME DevHelp(now usingWebKitGTK).

Discontinued products that used Gecko includeSwiftfox,Flock,Galeon,Camino,Minimo,Beonex Communicator,Kazehakase,Songbird,Sunbird (calendar),MicroB,Nightingale,Instantbird,andPicasafor Linux.[26]

Proprietary dependency[edit]

On Windows and other platforms, Gecko depends on proprietary compilers.[27]Thus,FOSSdistributions ofLinuxcannot include the Gecko package used in the Windows compatibility layerWine.[28]

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,[29]to reflect the fact that it is no longer a separate component.[30]

Bloat[edit]

In the Netscape era, a combination of poor technical and management decisions resulted in Geckosoftware bloat.[11][31][32]Thus in 2001Applechose to forkKHTML,not Gecko, to create theWebKitenginefor itsSafaribrowser.[31][32]However, by 2008 Mozilla had addressed some of the bloat problems, resulting in significant performance improvements for Gecko.[33]

Quantum[edit]

Quantumis aMozillaproject encompassing severalsoftware developmentefforts to "build the next-generation web engine forFirefoxusers ". It includes numerous improvements to Gecko, largely incorporated from the experimentalServoproject. Quantum also includes refinements to the user interface and interactions.[12][13]

Firefox 57, released in November 2017, is the initial version with a Servo component enabled. Mozilla dubs this and several planned future releases "Firefox Quantum".[34][35]

Background[edit]

In 2012, Mozilla began the experimentalServo project,which is an engine designed from scratch with the goals of improvingconcurrency and parallelismwhile also reducingmemory safetyvulnerabilities. Servo is written in theRust programming language,also created by Mozilla, which is designed to generatecompiledcode with better memory safety, concurrency, and parallelism than compiled C++ code.[5]

As of April 2016, Servo needed at least several years of development to become a full-featured browser engine,[36]hence the decision to start the Quantum project to bring stable portions of Servo into Firefox. Mozilla laid off all Servo developers in August 2020.[37]

Components[edit]

The Quantum project is composed of several sub-projects.[12]

  • CSS:Servo's parallelstyle sheetsystem integrated into Gecko. Benchmarks suggest that performance scales linearly with number ofCPUcores.[38]This was released in Firefox 57.[35]
  • Render:Servo'srenderingarchitecture, called WebRender, integrated into Gecko. WebRender replaces theimmediate modedrawing model with aretained modemodel that is more easily accelerated by theGPUby taking advantage of CSS/DOM's similarity to ascene graph.Worst-case scenario rendering in testing exceeds 60 frames per second.[39]Mozilla began enabling the new renderer for select hardware/OS combinations in Firefox 67.[40]
  • Compositor:Gecko's existingcompositormoved 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.[41]
  • DOM:Loosely inspired by Servo's Constellation architecture[42]andOpera'sPrestoengine,[43]Quantum DOM uses cooperatively scheduled threads within theDOMto increase responsiveness without increasing the number of processes and, thus, memory usage. The core of this shipped in Firefox 57.[44]
  • Flow:An umbrella for user visible performance improvements driven by a team that works across Gecko components. Focused on real user performance improvements on majorwebapps,primarily G Suite (now calledGoogle Workspace) andFacebook.[45]This work completed and shipped for Firefox 57.[46]
  • Photon:AUIrefresh of the entire application, with a strong focus on improving UI performance. Treated as a sister project to Quantum Flow.[47]This was released in Firefox 57.[34]
  • Network:Improve the performance ofNecko,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.[48]This feature was released in Firefox 59.[49]

Azure[edit]

TheMozilla Azureproject is a stateless low-level graphics abstraction API used inFirefox.[50]The project has several objectives including more accurate Direct2D compatibility, optimized state interoperability, and improved control over performance characteristics and bugs. Azure will provide 2D hardware acceleration on top of 3D graphics backends. Firefox began using Azure instead ofCairoin 2012.[51][52]It is written inC++and used byServo.[53]The Azure name is an ode to the early Netscape founderJames H. Clarkand his earlier work atSilicon Graphicswhere workstations were often named after colors.[54]

References[edit]

  1. ^"Mozilla Foundation End-User Licensing Agreements".Mozilla.
  2. ^"Mozilla Licensing Policies".mozilla.org.Retrieved2013-03-26.
  3. ^"Embedding Mozilla".Mozilla.org. 2012-10-25.Retrieved2012-10-31.
  4. ^ab"Simple Firefox for Android build".Archived fromthe originalon 2019-09-29.Retrieved2017-05-03.Gecko is implemented using C++ and JavaScript.
  5. ^abBergstrom, Lars; et al. (May 2016)."Engineering the Servo Web Browser Engine using Rust"(PDF).Proceedings of the International Conference on Software Engineering.Archived(PDF)from the original on 2016-05-29.
  6. ^"Google Groups".groups.google.
  7. ^Yegulalp, Serdar (February 3, 2017)."Mozilla binds Firefox's fate to the Rust language".InfoWorld.
  8. ^"MPL 2 Upgrade".Retrieved2012-08-18.
  9. ^"Gecko FAQ".MDN Web Docs.Archived fromthe originalon 2019-10-08.Retrieved2017-05-03.
  10. ^"nglayout project: identity crisis".Mozilla.org. Archived fromthe originalon 2011-06-29.Retrieved2012-10-31.
  11. ^abJorge O. Castro (2004-06-15)."Ars Technica sits down with Scott Collins from Mozilla.org".Ars Technica.Retrieved2017-02-16.
  12. ^abcd"Quantum".Mozilla Wiki.Retrieved2017-04-20.
  13. ^abCimpanu, Catalin."Mozilla Announces Quantum, a New Browser Engine for Firefox".softpedia.Retrieved2016-11-07.
  14. ^"Firefox Focus 7.0 enters beta, Switches to GeckoView (Gecko Engine)".14 September 2018. Archived fromthe originalon 31 July 2020.Retrieved19 September2019.
  15. ^ab"Firefox Focus with GeckoView".Mozilla Hacks.September 13, 2018.RetrievedSeptember 4,2019.
  16. ^"What's new in Firefox Focus for Android (version 7) | Firefox Focus Help".support.mozilla.org.RetrievedSeptember 4,2019.
  17. ^"GeckoView in 2019".Mozilla Hacks.June 27, 2019.RetrievedSeptember 4,2019.
  18. ^Vesta Zare (August 25, 2020)."Fast, personalized and private by design on all platforms: introducing a new Firefox for Android experience".Mozilla Blog.RetrievedSeptember 22,2020.
  19. ^"Cross Browser Compatibility of ECMAScript 2015 (ES6) in Firefox 102".lambdatest.Retrieved2022-08-21.
  20. ^"Cross Browser Compatibility of SVG (basic support) in Firefox 102".lambdatest.Retrieved2022-08-21.
  21. ^"Mozilla Adds Undetectable document.all Support, Part of New Novell Linux Distribution?".Developer.mozilla.org. 2004-07-23.Retrieved2018-02-07.
  22. ^"IE Uses Gecko Under Wine".Wine Wiki.Retrieved2009-09-14.
  23. ^sdubois (24 June 2010)."Gecko".Free Software Foundation.Retrieved23 May2019.
  24. ^Martens, China (2007-01-03)."One Laptop Per Child readies 'Sugar' interface".IDG News Service. Archived fromthe originalon 2008-01-18.Retrieved2007-12-28.
  25. ^Hill, Paul (2020-03-12)."KaiOS Technologies partners with Mozilla to improve Gecko".Neowin.Retrieved2024-07-12.
  26. ^"Picasa 3.0 for Linux".Archived fromthe originalon 2009-01-07.Retrieved2008-12-28.
  27. ^"Building Firefox for Windows".MDN Web Docs.
  28. ^"Fedora - Wine-Wiki".wiki.jswindle.Archived fromthe originalon June 11, 2012.
  29. ^"Gecko versions and application versions".MDN.Archived fromthe originalon 2020-10-31.Retrieved2013-11-18.
  30. ^"Not much in new Thunderbird 5, but roadmap looks promising".Ars Technica.30 June 2011.Retrieved2018-02-07.
  31. ^abPaul Festa(2003-01-14)."Apple snub stings Mozilla".CNET Networks.Archived fromthe originalon 2012-10-25.Retrieved2017-02-16.
  32. ^abDavid Baron (2003-01-09)."Thursday 2003-01-09".David Baron's weblog.self-published. Archived fromthe originalon 2009-07-28.Retrieved2017-02-16.
  33. ^Ryan Paul (2008-09-09)."Why Mozilla is committed to Gecko as WebKit popularity grows".Retrieved2017-02-16.
  34. ^ab"Firefox 57.0, See All New Features, Updates and Fixes".Mozilla.Retrieved2018-10-30.
  35. ^ab"Introducing the New Firefox: Firefox Quantum – The Mozilla Blog".The Mozilla Blog.Retrieved2018-10-30.
  36. ^"Servo remaining work".GitHub.Retrieved2017-02-17.
  37. ^"Mozilla lays off 250 employees while it refocuses on commercial products".ZDNet.Retrieved2022-06-14.
  38. ^"The Changelog".The Changelog.18 November 2016.Retrieved2017-03-28.
  39. ^"Bay Area Rust Meetup February 2016".Air Mozilla.Retrieved2017-03-28.
  40. ^"Webrender Where".Mozilla Wiki.Retrieved2020-07-14.
  41. ^"Firefox faster and more stable with the first big bytes of Project Quantum, simpler with compact themes and permissions redesign".Mozilla Blog.Retrieved2017-04-27.
  42. ^"Servo Architecture".YouTube.Archivedfrom the original on 2021-12-11.Retrieved2017-03-28.
  43. ^"Mozilla's Quantum Project".Bill McCloskey's Blog.2016-10-27.Retrieved2017-03-28.
  44. ^"Entering the Quantum Era".Mozilla Hacks.2017-11-13.Retrieved2020-07-14.
  45. ^"Quantum Flow".Mozilla Wiki.Retrieved2017-03-28.
  46. ^"Quantum Flow Engineering Newsletter #25".ehsanakhgari.org.2017-09-17.Retrieved2020-07-14.
  47. ^dolske (2017-05-18)."Photon Engineering Newsletter #1".Dolske's blog.Retrieved2017-07-04.
  48. ^"TPE Necko/Projects - MozillaWiki".wiki.mozilla.org.Retrieved2017-07-04.
  49. ^"Firefox 59 Release Notes".mozilla.org.Retrieved2019-01-16.
  50. ^"Platform/GFX/Moz2D - MozillaWiki".
  51. ^Parfeni, Lucian."Firefox Now Uses the Azure Graphics API for Canvas on All Platforms".
  52. ^"Azure Replacing Cairo In Mozilla Firefox - Phoronix".
  53. ^Willis, Nathan (17 June 2015)."Parallel page rendering with Mozilla Servo".LWN.net.Retrieved27 June2015.
  54. ^"Introducing the Azure project - JOEDREW!".Archived fromthe originalon 2016-09-08.Retrieved2019-09-22.

External links[edit]