New features for extension developers in Firefox 1.5
SVG support
SVG is W3C specification providing resolution-independent scalable vector graphics, along with a DOM. Firefox 1.5 supports a subset of SVG 1.1. For more information, see SVG in DevMo.
Canvas Support
<canvas>
is a scriptable bitmap drawing surface. It
is suitable for many uses, such as drawing dynamic graphs and game graphics. For more information, see
Drawing Graphics with Canvas or the Canvas tutorial.
Hidden referrer column for history
Extensions can now access the referrer information for pages stored in the browser history. This feature can be used to provide alternate history views and other useful functionality. For example, my How'd I Get Here? extension uses this feature.
API for prioritizing HTTP connections
The Mozilla networking library now supports the prioritization of connections to a specific server. (See nsISupportsPriority.)
API for configuring proxies
It is now possible for extensions to easily override the proxy configuration without affecting user-visible preferences. (See nsIProtocolProxyService, nsIProtocolProxyFilter, and nsIProtocolProxyCallback.)
API for managing user and UA stylesheets
Extensions can now register stylesheet URIs as additional user and UA
stylesheets. This means extensions no longer have to try to edit
userContent.css
to add styling (say for XBL binding
attachment) to web pages. This makes it easier to implement extensions like
Flashblock. For details on using
this API, see
Using
the Stylesheet Service.
Site-specific user style sheet rules
Firefox now supports site-specific user style sheet rules. While advanced users can edit userContent.css to use this feature directly, an extension could also take advantage of this feature using the API for managing user style sheets above.
Dynamic Overlays
Loading of XUL overlays after the document has been displayed is now supported. (See nsIDOMXULDocument.)
Translucent Windows (Windows/Linux)
On Windows and Linux, XUL windows with a transparent background are now supported. This allows whatever is below the window to shine through the window background.
New Preferences Bindings
These new bindings make it easier to create preferences windows for extensions. The new preferences windows support instant-apply behavior, which is enabled by default on Mac and Linux.
API for implementing new command-line switches
An extensible API has been introduced so that extensions can easily handle complex command-line flags. (See nsICommandLine and nsICommandLineHandler.)
XTF Support
The eXtensible Tag Framework allows adding support for new namespaces using XPCOM components to Mozilla (written in JavaScript or C++). For example, the Mozilla XForms Project uses XTF to add support for the XForms namespace. See the XTF Home Page.
Cryptographic hash API
Extensions now have access to several cryptographic hash functions, including MD5, SHA-1, and several flavors of SHA-2. (See nsICryptoHash.)
Rich list box
<xul:richlistbox> is a new widget that Firefox's Download Manager and Extension/Theme manager now use. For more information, see XULPlanet: richlistbox or DevMo: richlistbox.
Access to nsIEditor of textboxes
Firefox now has a supported method for getting the nsIEditor of textboxes and textareas, making it easier to implement features such as spell checking for web forms. For more information, see bug 303727 or nsIDOMNSEditableElement.
Access to nsIPipe
See bug 300423 or nsIPipe.
Other improvements
This post emphasizes new features since Firefox 1.0.7 over things that have changed since Firefox 1.0.7, but here are a few important things that have changed:
- Improvements to evalInSandbox make it easier for extensions like Greasemonkey to inject scripts into web pages safely.
- Improvements to designMode (WYSIWYG HTML editing) make it more suitable for use in extensions.
- Extensions can now include search plugins, plugin DLLs, and platform-specific XPCOM components.
- Extensions can now add to the user-agent string in a safe way.
- There are now extra ways to install and uninstall extensions, especially Firefox extensions that are shipped with Windows programs.
- New JavaScript language features allow extension developers (and web developers who only target Firefox) to manipulate arrays and XML concisely.
- There have been many changes in XUL, especially to the XUL tree widget.
- Extensions written using JavaScript now use XPCNativeWrappers by default, making it easier to write extensions that manipulate web content without introducing security holes.
- Extensions can now specify that they are compatible only with specific versions of Firefox (e.g. Firefox 1.5.0.2). Most extensions that work with Firefox 1.5 should set their maxVersion as 1.5.0.*, indicating that they will work with future security releases (unless some of those releases contain API changes, which is unlikely and will cause them to be numbered e.g. Firefox 1.5.1). See this page for more information.
Parts of this post were taken from this page, which was based on a wiki page, which was based on an early version of my changelog for Deer Park Alpha 1. It might be merged with this wiki page in the future.
November 4th, 2005 at 7:08 am
Mozilla-säätiö on julkistanut Firefoxin laajennusten tekokilpailun (kilpailun sivu). Ajatuksena on saada uusia ihmisiä kiinnostumaan laajennusten koodaamisesta ja kohtapuolin julkaistavan Firefox 1.5:n uusista ominaisuuksista […]
November 6th, 2005 at 5:29 am
Site-specific user style sheet rules – is very important and useful function of Firefox 1.5. That’s why I like Firefox :)
November 8th, 2005 at 9:59 am
[…] Just found a cool set of bookmarklets from Jesse Ruderman. They let you easily add a seek bar to Flash animations. While looking around I see he’s also got a handy summary of new features in Firefox 1.5 for extension developers. Good stuff. […]
November 8th, 2005 at 4:23 pm
[…] New features for extension developers in Firefox 1.5 […]
November 9th, 2005 at 9:50 am
that’s great news.
November 10th, 2005 at 3:19 am
Some great extensions are always welcome.
December 1st, 2005 at 7:06 am
It’s so hard to believe that this is not an image!