Search completed in 1.27 seconds.
66 results for "overlays":
Your results are loading. Please wait...
XUL Overlays
Mozilla › Tech › XUL › Overlays
XUL files and XUL overlays Overlays are XUL files used to describe extra content in the UI. Though overlays often define UI elements that have been added as a result of an update or enhancement of some kind, they can be used in many different ways. Overlays provide a general mechanism for: Adding UI for additional components, as described in the example above Overriding small pieces of a XUL file without having to resupply the whole UI Reusing particular pieces of the UI XUL files and overlays work together to describe a single master document. ...
...m for: Adding UI for additional components, as described in the example above Overriding small pieces of a XUL file without having to resupply the whole UI Reusing particular pieces of the UI XUL files and overlays work together to describe a single master document. Though there is no formal restriction on what kind of XUL content is located in "base" XUL files and what kind should be put in overlays, XUL overlays generally define items that are not present in the basic versions of the UI, such as additional components. When plug-ins, browser extensions, or other applications provide new UI elements to the browser, these elements should be defined in overlay files. The installation of a media plug-in, for example, may add new icons and menu items to the interface: In the navigatorOverlay.xul...
...Thus, given the following base: ... <menu id="file-menu"> <menupopup id="menu_FilePopup"> <menuitem name="New"/> <menuitem name="Open"/> <menuitem name="Save"/> <menuitem name="Close"/> </menupopup> </menu> ... And given the following overlay: <?xml version="1.0"?> <overlay id="singleItemEx" ...
...And 13 more matches
Cross Package Overlays - Archive of obsolete content
You specify this by modifying the contents.rdf file for your package. This is useful because the overlay can modify the user interface of another package without changing the other package. ...
...In the examples in the previous section, the overlays were imported by the window. You can also go the other way and have the overlays specify which windows that they apply to. You specify this by modifying the contents.rdf file for your package. This is useful because the overlay can modify the user interface of another package without changing the other package. ...
...You specify this by modifying the contents.rdf file for your package. This is useful because the overlay can modify the user interface of another package without changing the other package. For example, you could add menu items or toolbars to the Mozilla browser window. ...
...And 4 more matches
DOM Inspector internals - Firefox Developer Tools
Some overlays can be described as host-integration overlays, and others as shared structure overlays. Host-integration overlays DOM Inspector is a general-purpose extension, suitable for use with any Mozilla toolkit host application. In order for DOM Inspector to be useful with its host application, though, there should be a way to launch DOM I...
...torOverlay.xul inspector.xml inspector.xul keysetOverlay.xul object.js object.xul popupOverlay.xul sidebar.js sidebar.xul statusbarOverlay.xul tasksOverlay-cz.xul tasksOverlay-ff.xul tasksOverlay-mobile.xul tasksOverlay-sb.xul tasksOverlay-tb.xul tasksOverlay.xul toolboxOverlay.xul utils.js venkmanOverlay.xul ViewerRegistry.js Overlays You will notice that there are a lot of overlays. Some overlays can be described as host-integration overlays, and others as shared structure overlays. Host-integration overlays DOM Inspector is a general-purpose extension, suitable for use with any Mozilla toolkit host application. In order for DOM Inspector to be useful with its host application, though, there should be a way to launch DOM Inspector within it, e.g., by a menu item and an op...
...hough, there should be a way to launch DOM Inspector within it, e.g., by a menu item and an optional keyboard shortcut such as Ctrl+Shift+I (or Cmd+Shift+I). Either the host applications must provide these themselves (usually bundling DOM Inspector with the application, too), or DOM Inspector must explicitly support them by providing its own menu items and keyboard shortcuts with host-integration overlays. ...
...And 8 more matches
Chapter 5: Let's build a Firefox extension - Archive of obsolete content
y haven't been granted "use XPConnect as local file" privileges, as discussed in Chapter 4, they will be able to use XPCOM functions (Figure 1). ...
... really explicit and not a Figure) Cross-package overlays The "overlay" technique introduced in Chapter 3 required the use of the xul-overlay instruction in the XUL document that is the overlay target. It is also possible to coerce an overlay without using the xul-overlay instruction in the XUL document--this is called a "cross-package overlay" (Figure 2). In fact, you need to use cross-package overlays to append buttons or menus to the Firefox browser window. Use the chrome manifest to invoke a cross-package overlay. Normal overlay: Adding the xul-overlay instruction to the target XUL document overlays it with another XUL document Cross-package overlay: Adding a cross manifest permits one XUL file to overlay another without any xul-overlay instruction. Figure 2: Invoking a cross-package overl...
...d in Phase 1 FIXME: Make the table cleaner File name Role install.rdf Called the install manifest, this gives basic information about the extension, and is required in order for the extension to be installed in Firefox.. chrome.manifest This is the chrome manifest described in the earlier section. Registers packages and invokes cross-package overlays. content/overlay.xul XUL file that will be overlaid on the Firefox browser window, adding buttons, menu items, etc. content/clock.xul content/clock.js The XUL to display a clock in the window, and the JavaScript to control its operation (these files will be used in Phase 2). Create install manifest Fill in the install.rdf file as shown in Listing ...
...And 4 more matches
The Joy of XUL - Archive of obsolete content
owers developers with the ability to extend XUL by customizing existing tags and creating new tags of their own. By using XBL, developers can easily build custom user interface widgets such as progress meters, fancy pop-up menus, and even toolbars and search forms. These custom components can then be used in XUL applications by specifying the custom tag and associated attributes. ...
...pers with the ability to extend XUL by customizing existing tags and creating new tags of their own. By using XBL, developers can easily build custom user interface widgets such as progress meters, fancy pop-up menus, and even toolbars and search forms. These custom components can then be used in XUL applications by specifying the custom tag and associated attributes. Overlays Overlays are XUL files used to describe extra content for the UI. They are a general mechanism for adding UI for additional components, overriding small pieces of a XUL file without having to resupply the whole UI, and reusing particular pieces of the UI. Overlays are a powerful mechanism for customizing and extending existing applications because they work in two related but highly different ways. In...
... used to describe extra content for the UI. They are a general mechanism for adding UI for additional components, overriding small pieces of a XUL file without having to resupply the whole UI, and reusing particular pieces of the UI. Overlays are a powerful mechanism for customizing and extending existing applications because they work in two related but highly different ways. In one respect, Overlays are synonymous with "include" files in other languages because an application may specify that an Overlay be included in its definition. But Overlays can also be specified externally, enabling the designer to superimpose them upon an application without changing the original source. In practical terms, this enables developers to maintain one code stream for a given application, then apply cu...
...And 3 more matches
Extensions support in SeaMonkey 2 - Archive of obsolete content
Version>2.0</em:minVersion> <em:maxVersion>2.*</em:maxVersion> </Description> </em:targetApplication> The install.js is not supported any more and should be removed. Differences as compared to other toolkit/-based applications You need to overlay/open different chrome URLs as compared to Firefox. ...
...anager.xul Thunderbird uses mostly the same chrome URLs for overlaying as SeaMonkey. There are exceptions, but these are few and far between. SeaMonkey also uses different IDs for the menu items. ...
...ode that opens the URL history popup just looks for any menupopup, so it goes wrong if you add your own. Ordinary popups are fine of course. The Statusbar In Firefox 3 a new vbox has been added, called "browser-bottombox", which encloses the find bar and status bar at the bottom of the browser window. Although this doesn't affect the appearance of the display, it may affect your extension if it overlays chrome relative to these elements. For example, if you overlay some chrome before the status bar, like this: <vbox id="browser-bottombox"> <something insertbefore="status-bar" /> </vbox> Use the following technique to make your overlay work on both SeaMonkey 2 and Firefox 3: <window id="main-window"> <vbox id="browser-bottombox" insertbefore="status-bar"> <something insertbefore="sta...
...p-info;1"] .getService(Components.interfaces.nsIXULAppInfo); if(appInfo.ID == FIREFOX_ID) { // running under Firefox } else if(appInfo.ID == THUNDERBIRD_ID) { // running under Thunderbird } else if(appInfo.ID == SEAMONKEY_ID) { // running under SeaMonkey } else { // another app } See Using nsIXULAppInfo for more details. In manifest file SeaMonkey uses different overlays than other applications. You can use the application flag to select which overlay should be used with which application: overlay chrome://browser/content/browser.xul chrome://myaddon/content/ffOverlay.xul application={ec8030f7-c20a-464f-9b0e-13a3a9e97384} overlay chrome://messenger/content/mailWindowOverlay.xul chrome://myaddon/content/tbOverlay.xul application={3550f703-e582-4d05-9a08-453d09bdf...
SeaMonkey - making custom toolbar (SM ver. 1.x) - Archive of obsolete content
near the top. Presss the Return or Enter key, or the Evaluate button. The console displays the location of SeaMonkey's chrome directory. Explanation: The chrome directory contains program files that are part of SeaMonkey itself, together with other files that are provided by extensions. Your toolbar button will be an extension. 2. Delete these two files: chrome.rdf overlays.rdf Explanation: SeaMonkey automatically rebuilds these files the next time it starts. When it rebuilds them, it will include your new extension. 3. Edit the file: installed-chrome.txt At the end of the file, add the following line. Copy and paste the line from here, to avoid typing errors: content,install,url,resource:/chrome/custombutton/ Explanation: This l...
... RDF:resource="urn:mozilla:package:custombutton"/> </RDF:Seq> <RDF:Description RDF:about="urn:mozilla:package:custombutton" chrome:displayName="Custom Button" chrome:description="My custom toolbar button" chrome:author="My name" chrome:name="custombutton" chrome:localeVersion="1.8" chrome:skinVersion="1.5" chrome:extension="true"/> <RDF:Seq about="urn:mozilla:overlays"> <!-- browser --> <RDF:li> <RDF:Seq about="chrome://navigator/content/navigator.xul"> <RDF:li>chrome://custombutton/content/button.xul</RDF:li> </RDF:Seq> </RDF:li> <!-- address book --> <RDF:li> <RDF:Seq about="chrome://messenger/content/addressbook/addressbook.xul"> <RDF:li>chrome://custombutton/content/button.xul</RDF:li> </RDF:Seq...
...images are used when the mouse pointer is over the button. Darker images are used when the button is pressed. Testing your new button Restart SeaMonkey. Click the button to test it. You should see the pop-up message. Further development This section describes how you can develop your button further. Uninstalling the button If you ever want to uninstall the button, delete the files chrome.rdf and overlays.rdf again, just as you did in step 2. Remove the line that you added to installed-chrome.txt in step 3. Delete the custombutton directory that you created in step 4. Restart SeaMonkey. Troubleshooting If the button does not appear, or if you find some other problem, check that you have followed all the steps exactly. If necessary, uninstall the button and start again, this time without making any...
...e, button.xul. This is not always satisfactory. If you find that settings for different toolbars interfere with each other, make a separate XUL file for each toolbar by copying button.xul and removing that parts that you do not need. Change contents.rdf, replacing each occurrence of button.xul with the name of one of your new XUL files. After changing contents.rdf, delete the files chrome.rdf and overlays.rdf so that SeaMonkey registers the change the next time it starts. Distributing your button to other users If you want to distribute your button or buttons to other users, you must first make some changes to avoid conflicts when they install your extension. You will need a jar tool or zip tool to package your extension. There are six steps. 1. Choose a unique name for your extension. ...
XUL Structure - Archive of obsolete content
h the same way. In fact, in Mozilla, all document types, whether they are HTML or XUL, or even SVG, are all handled by the same underlying code. This means that the same CSS properties may be used to style both HTML and XUL, and many of the features can be shared between both. However, there are some features that are specific to HTML, such as forms, and others which are specific to XUL, such as overlays. Since XUL and HTML are handled in the same way, you can load both from either your local file system, from a web page, or from an extension or standalone XULRunner application. Content from remote sources (e.g. http://localhost/~username/ ), regardless of whether they are HTML or XUL or another document type, are limited in the type of operations they can perform, for security reasons. For this...
...nstalled onto the user's machine. The extension will hook into the browser using a XUL specific feature called an overlay which allows the XUL from the extension to mesh with the XUL in the browser. To the user, it may seem like the extension has modified the browser, but in reality, the code is all separate, and the extension may be easily uninstalled. Registered packages are not required to use overlays, of course. If they don't, you won't be able to access them via the main browser interface, but you can still access them via the chrome URL, if you know what it is. Standalone XUL applications may include XUL code in a similar way, but, of course, the XUL for the application will be included as part of the installation, instead of having to be installed separately as an extension. However, this...
...her types of XML documents. Since XUL is also XML, the XUL document is a subtype of the more generic XML document. There are subtle differences in functionality. For example, while the form controls on an HTML page are accessible via the document.forms property, this property isn't available for XUL documents, since XUL doesn't have forms in the HTML sense. Likewise, XUL specific features such as overlays and templates are only available in XUL documents. This distinction between documents is important. It is possible to use many XUL features in HTML or XML documents since they aren't document type specific; however other features require the right kind of document. For instance, you can use the XUL layout types in other documents since they don't rely on the XUL document type to function. To su...
...The main window for a content package should have the same name as the package with a .xul extension. In this case, the package name is "browser" so we expect to find browser.xul. Some of the other XUL files describe separate windows. For example, the file pageInfo.xul describes the page info dialog. Many packages will include a contents.rdf file, which describes the package, its author, and the overlays it uses. However, this file is obsolete and has been replaced with a simpler mechanism. This newer method is the manifest file mentioned earlier, and you will find these as files with the .manifest extension in the chrome directory. For instance, browser.manifest describes the browser package. Several subdirectories, such as bookmarks and preferences, describe additional sections of the browser ...
Writing Skinnable XUL and CSS - Archive of obsolete content
nded to be used in the context of another component's skin are also considered derived skin files, since they are implicitly importing information from the other component's skin. These sorts of files are typically used with reusable overlayable widgets (e.g., the sidebar). Your CSS file should never import another skin file if your file is loaded by a XUL overlay. CSS files that are used by XUL overlays should never import the global skin (or any other skin for that matter). They are already derived skins and therefore should not inherit from global. They should instead rely on the context in which they will appear for color, font, and border information. For example, the sidebar should not import the global skin, since it could appear in Messenger and in Navigator (which could have two complete...
...onal toolbar headers or for the menu buttons' borders. Example 2: The Messenger package has a CSS file that describes the appearance of the Messenger button that appears on the taskbar used by all windows. The Messenger CSS file should not attempt to describe the borders or the colors for this button. It should only describe the icon. Because the button is used in the Navigator window (through overlays), the fonts/colors used should not be described by Messenger. This allows the button to blend in as much as possible regardless of where it is used. The importance of this rule cannot be overstated. Derived skin files should not contain any rules for colors, fonts, or borders. Exceptions to this rule must be approved in order to be allowed into the product. Note that in our current designed Mo...
...r use an attribute selector rule for the class attribute. This is inefficient and you should just use the class notation (the dot notation) instead. Writing Skinnable XUL A XUL file that describes a window always imports the master skin file for its package. For example, all XUL files that describe windows in the Navigator package should contain a line explicitly importing navigator.css. XUL overlays, however, should not, since they will be used in the context of other skins. A XUL file NEVER imports skin files from outside its package. It is a flagrant and hideous violation (punishable by a public flogging in front of the Netscape fountain) to load a skin file from XUL that is not found in your package. For example, a Navigator XUL file should never load the global skin or a Sidebar skin. ...
...other packages can be guaranteed. For example, a Navigator XUL file can only load a Sidebar overlay explicitly if the Sidebar UI is always going to be installed with navigator. If it is possible that the sidebar is a separate component that could be installed or uninstalled, then the overlaying should not occur in the XUL file. It should instead take place through the chrome registry. Examples of overlays that should take place using the chrome registry include the security padlock icon and any Messenger UI in the Navigator window. style="..." is prohibited in XUL files without approval Any usages of inline style are extremely dangerous, since they are overriding the included skin, and must be approved before their usage will be allowed. Image chrome URLs should never occur in XUL. Any chrome UR...
Bootstrapped extensions - Archive of obsolete content
Traditional extensions include overlays, wherein the application can load up XUL from the extension's package and automatically apply it on top its own UI. While this makes creating extensions that add to the application's user interface relatively easy, it means that updating, installing, or disabling an extension requires an application restart. Gecko 2.0 (Firefox 4 / Thunderbird 3.3 / SeaMonkey 2.1) introduces bootstrapped extensions. These are special extensions that, instead of using overlays to apply their user interface to the application, programmatically insert themselves into the application. This is done using a special script file that's included in the extension that contains functions the browser calls to command the extension to install, uninstall, start up, and shut down. All th...
...ns You can use a chrome.manifest file in bootstrapped add-ons to: Make your add-on's content available via a chrome:// URL (using the content, locale, and skin instructions in the manifest). Replace existing chrome:// URIs with your content (using the override instruction). Not all chrome.manifest instructions are supported in bootstrapped add-ons, for example you still cannot register XUL Overlays from a bootstrapped add-on. See the chrome.manifest documentation for details. In Firefox 10 and later the chrome.manifest file located in the root of the add-on's XPI (i.e. a sibling of the install.rdf) is loaded automatically. In Firefox 8 and 9 you had to load/unload the manifest manually using nsIComponentManager.addBootstrappedManifestLocation() and nsIComponentManager.removeBootstrappedMan...
...his should be alongside the install.rdf file in the extension's package. Backward compatibility Because older versions of Firefox don't know about the bootstrap property or bootstrap.js file, it's not overly difficult to create an XPI that will work on both as a bootstrappable extension and as a traditional extension. Create your extension as a bootstrappable extension, then add the traditional overlays as well. Newer versions of Firefox will use the bootstrap.js script, ignoring the components and overlays, while older versions will use the overlays. Bootstrap entry points The bootstrap.js script should contain several specific functions, which are called by the browser to manage the extension. The script gets executed in a privileged sandbox, which is cached until the extension is shut down.
How to convert an overlay extension to restartless - Archive of obsolete content
Some of that will have to be replaced and the rest will need to be loaded differently. ...
...y that some users have installed will sometimes delete files. There have been plenty of reports of add-on franken-installs with files of two versions mixed together. This might be due to malware or a bug in Firefox. In any case, I have noticed a significant improvement in reliability by going fully extractionless. Installing and updating a single file is far more idiot-proof. Step 6: No more XUL overlays Ok, now we're getting into some more drastic changes. You won't be able to use your chrome.manifest to load XUL overlays anymore with a restartless add-on. You could look into dynamically loading and unloading your overlay, however dynamically manipulating the DOM of your XUL window is usually the more straightforward route. Figure out what XUL elements you need to create for your add-on to add...
...he loaded string bundle will be stored in "strings" for future accesses. You still need to clear the cache on add-on shutdown, however it will now also load cleanly on add-on updates. The old file should still be cleared. Put it all together That should be all the pieces. Your chrome.manifest will have just chrome and locale (and possibly skin) mappings in it now. No resource mappings or chrome overlays. The new entry point for your add-on is via bootstrap.js:startup() rather than a "load" handler in a XUL overlay. Your localization handling should be unaffected by your transition to a restartless/extractionless add-on so long as you properly clear the chrome cache on add-on shutdown and load your properties files using the method listed above. Your property files and DTD files loaded from chro...
The Essentials of an Extension - Archive of obsolete content
ensions. XUL was inspired by HTML, so you'll see many similarities between the two. However, XUL is also an improvement over HTML, having learned from many of the mistakes made during the evolution of HTML. XUL allows you to create richer and more interactive interfaces than the ones you can create with HTML, or at least XUL makes it easier. XUL files usually define one of two things: windows or overlays. The file you opened before, downloads.xul, has the code that defines the Downloads window. The XUL file included in the Hello World extension is an overlay. An overlay extends an existing window, adding new elements to it or replacing some of the elements in it. The line that we skipped in the chrome.manifest file states that this XUL file is an overlay for the main browser window: overlay ch...
...elements in it. The line that we skipped in the chrome.manifest file states that this XUL file is an overlay for the main browser window: overlay chrome://browser/content/browser.xul chrome://xulschoolhello/content/browserOverlay.xul With this line, Firefox knows that it needs to take the contents of browserOverlay.xul and overlay it on the main browser window, browser.xul. You can declare overlays for any window or dialog in Firefox, but overlaying the main browser window is the most common case by far. Now let's look at the contents of our XUL file. We'll skip the first few lines because they relate to skin and locale, and we'll cover them later. <overlay id="xulschoolhello-browser-overlay" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> The root element in ...
...cing standard that we use to avoid conflicts with Firefox and other extensions, as well as making some development tasks easier. We namespace all ids and style classes in overlay elements because they will be mixed with other elements in the main browser window. If we used generic ids like container or input, they will likely conflict with ids used within Firefox, or with ids from other extension overlays. Using namespaces minimizes compatibility problems with other extensions. We use camel casing for file names, and all lower case with dashes for element ids and CSS style class names, but you're free to use your own system. <script type="application/x-javascript" src="chrome://xulschoolhello/content/browserOverlay.js" /> Just like in HTML, this includes a JavaScript script file. You can...
Index - Archive of obsolete content
host application, there are some Prism-specific issues that you need to handle when creating your extension. Most notably, the Prism application ID and the differences in the user interface (UI). Extensions typically overlay the host application's UI to add toolbar buttons, menus and other features. One of Prism's features is an extreme lack of UI elements, which means that trying to use the same overlays in Firefox and Prism is really not possible. 615 FAQ prism Prism is an application that integrates web applications into the desktop environment. It lets users start web applications from their desktop, start menu, and dock, and it opens those applications in their own window separate from a web browser and without the browser interface (back and forward buttons, location bar...
... containers for toolbar buttons and other user interface objects. The following articles provide details about implementing and working with toolbars. 1687 Creating toolbar buttons (Customize Toolbar Window) Add-ons, Extensions, Firefox 3, Toolbars, XUL This article explains how to add a toolbar button to a Toolkit application (such as Firefox, Thunderbird, or Kompozer) using overlays. Its intended audience is extension developers with a basic knowledge of XUL and CSS. 1688 Custom toolbar button Add-ons, Extensions, SeaMonkey, Toolbars, XUL, thunderbird This page tells you step-by-step how to make a custom toolbar button in Firefox, SeaMonkey 2.0, Thunderbird or Sunbird. (For SeaMonkey 1.x, see the page Custom Toolbar Button:SeaMonkey.) 1689 Cod...
...rial. 1753 Creating a Wizard Tutorials, XUL, XUL_Tutorial Many applications use wizards to help the user through complex tasks. XUL provides a way to create wizards easily. 1754 Creating an Installer Tutorials, XPInstall_API_reference, XUL, XUL_Tutorial This section will describe packaging a XUL application into an installer. 1755 Cross Package Overlays Tutorials, XUL, XUL_Tutorial This section describes how to apply overlays to files that don't import them. 1756 Custom Tree Views Tutorials, XUL, XUL_Tutorial The tree view holds the data to be displayed in the tree. 1757 Document Object Model DOM, Tutorials, XUL, XUL_Tutorial The Document Object Model (DOM) can be used with XUL elements to get ...
Making it into a static overlay - Archive of obsolete content
he chrome registry. Because our extension modifies an existing file in the Mozilla distribution, before we package it up we need to separate the modifications into a different file and add them back in at run time via a dynamic XUL overlay. A XUL overlay is a XUL file containing elements to be inserted into another XUL file when the other XUL file is rendered into an application interface. Static overlays are added to a XUL file via a reference at the top of the file (much like stylesheets and JavaScript scripts). Dynamic overlays are added to a XUL file via a reference in the chrome registry. Overlays provide a way to break up a large XUL file into several different files (one that describes the overall structure of an application window and the others to implement specific portions of the window...
...We'll first make the file into a static overlay, then we'll make it into a dynamic overlay. ...
... <statusbar id="status-bar" class="chromeclass-status" ondragdrop="nsDragAndDrop.drop(event, contentAreaDNDObserver);"> <statusbarpanel id="component-bar"/> <statusbarpanel id="statusbar-display" label="&statusText.label;" flex="1"/> <statusbarpanel class="statusbarpanel-progress"> <progressmeter class="progressmeter-statusbar" id="statusbar-icon" mode="no...
Main Windows
can sometimes appear confusing when you're just beginning to look at it. As such, I've always thought it would be nice to have a list of what xul, js, or other files are that are here, what they do, and where they overlay at different points within the client. Things appear confusing for several reasons: Much of the code is written to be portable, so instead of duplicating it, its been put in overlays that are loaded over many different types of windows. Some of the code was written based off of early Firefox code, but is not exactly the same. You'll sometimes see reimplementations of things that are already in toolkit, written specially for Thunderbird. messenger.xul The base mail window that you see when you first open Thunderbird is messenger.xul: messenger.xul itself doesn't contain a...
...ly the same. You'll sometimes see reimplementations of things that are already in toolkit, written specially for Thunderbird. messenger.xul The base mail window that you see when you first open Thunderbird is messenger.xul: messenger.xul itself doesn't contain a lot. Its main focus is on handling the folderpane, threadpane, and the message preview sections shown above. The rest is loaded from overlays: mailWindowOverlay.xul This is the red sections shown in the interface above (where?), including the toolbars, notification bars, and the status bar, but also includes most of the commands, keysets, and context menus of Thunderbird, along with a whole lot of Javascript. mailOverlay.xul A really small overlay that only adds a few "New message" and "New Card" commands to the menus, along with...
...is the attachment box which can be toggled into a slim or an expanded view baseMenuOverlay.xul Contains the contents of most of the menus (i.e. File, Edit, View, etc). OSX Only: macMenuOverlay.xul A special overlay for OSX that adds a few items to the window menu. messageWindow.xul messageWindow.xul is shown when a message is opened. Its almost exactly the same as messenger.xul in terms of overlays, but just lacks the folder and threadpanes normally shown. Menus, toolbar buttons, and headers are all taken from exactly the same overlays listed above though. mailWindowOverlay.xul This is the red sections shown in the interface above, including the toolbars, notification bars and the status bar.It also includes most of the commands, keysets, and context menus of Thunderbird, along with a ...
SDK and XUL Comparison - Archive of obsolete content
owser to attack by malicious web pages. Although it's possible to write insecure add-ons using the SDK, it's not as easy, and the damage that a compromised add-on can do is usually more limited. Restartlessness Add-ons built with the SDK can be installed without having to restart Firefox. Although you can write traditional add-ons that are restartless, you can't use XUL overlays in them, so most traditional add-ons would have to be substantially rewritten anyway. User Experience Best Practices The UI components available in the SDK are designed to align with the usability guidelines for Firefox, giving your users a better, more consistent experience. Mobile Support Starting in SDK 1.5, we've added experimental support for develop...
... with the usability guidelines for Firefox, giving your users a better, more consistent experience. Mobile Support Starting in SDK 1.5, we've added experimental support for developing add-ons on the new native version of Firefox Mobile. See the tutorial on mobile development. Advantages of XUL-based Add-ons User interface flexibility XUL overlays offer a great deal of options for building a UI and integrating it into the browser. Using only the SDK's supported APIs you have much more limited options for your UI. XPCOM Traditional add-ons have access to a vast amount of Firefox functionality via XPCOM. The SDK's supported APIs expose a relatively small set of this functionality. Low-level APIs and Third-part...
XUL Migration Guide - Archive of obsolete content
t at this point. If your add-on only needs a little help from those techniques, and can accomplish most of what it needs using the supported APIs, then it might still be worth migrating: we'll add more supported APIs in future releases to meet important use cases. User Interface Components XUL-based add-ons typically implement a user interface using a combination of two techniques: XUL overlays and XUL windows. XUL Overlays XUL overlays are used to modify existing windows such as the main browser window. In this way an extension can integrate its user interface into the browser: for example, adding menu items, buttons, and toolbars. Because SDK-based extensions are restartless, they can't use XUL overlays. To add user interface components to the browser, there are a few different opt...
...ly expects you to specify your user interface using HTML, not XUL. However, you can include a chrome.manifest file in your add-on and it will be included in the generated XPI. my-addon/ chrome/ content/ locale/ skin/ chrome.manifest data/ lib/ package.json There are limitations on what you can do in this manifest file: for example, you can't register overlays, resource: URIs, or components. However, you can register a chrome: URI, with a skin and locale, and this means you can include XUL windows in an SDK-based add-on. You can keep the "chrome.manifest" file in your add-on's root directory and create a directory there called "chrome". In that directory you can keep your "content", "locale", and "skin" subdirectories: This allows you to refer to obj...
Adding sidebars - Archive of obsolete content
Sidebars take as much space as the user wants them to, and provide a frame where you can add elaborate data and controls. You're probably familiar with the Bookmarks and History sidebars. If not, you can open either one from the View > Sidebar menu. They also have shortcuts to open or close them using the keyboard. The code required to add a sidebar is very simple, as explained in Creating a Firefox Sidebar. It's even simpler than that. ...
...e references: you can choose an obscure key combination that won't conflict with Firefox, such as Ctrl+Shift+(some letter), but there's no way of knowing if any other extension uses that same combination as well. Shortcut keys can be very valuable for advanced users, but don't rely on them. The XUL page for the sidebar can hold any content you want and it's no different from other XUL windows or overlays. One minor difference is that the XUL sidebar should be defined using the << XUL Reference << root element instead of window or dialog. The load event is fired every time the sidebar is opened, and unload every time it's closed, so you can use those for initialization and clean up . Another, more important difference to take into account is that users can resize the sidebar to their liking, and ...
Index - Archive of obsolete content
Archive › Mozilla › XUL › Index
e containers for toolbar buttons and other user interface objects. The following articles provide details about implementing and working with toolbars. 956 Creating toolbar buttons (Customize Toolbar Window) Add-ons, Extensions, Firefox 3, Toolbars, XUL This article explains how to add a toolbar button to a Toolkit application (such as Firefox, Thunderbird, or Kompozer) using overlays. Its intended audience is extension developers with a basic knowledge of XUL and CSS. 957 Custom toolbar button Add-ons, Extensions, SeaMonkey, Toolbars, XUL, thunderbird This page tells you step-by-step how to make a custom toolbar button in Firefox, SeaMonkey 2.0, Thunderbird or Sunbird. (For SeaMonkey 1.x, see the page Custom Toolbar Button:SeaMonkey.) 958 Code ...
...rial. 1022 Creating a Wizard Tutorials, XUL, XUL_Tutorial Many applications use wizards to help the user through complex tasks. XUL provides a way to create wizards easily. 1023 Creating an Installer Tutorials, XPInstall_API_reference, XUL, XUL_Tutorial This section will describe packaging a XUL application into an installer. 1024 Cross Package Overlays Tutorials, XUL, XUL_Tutorial This section describes how to apply overlays to files that don't import them. 1025 Custom Tree Views Tutorials, XUL, XUL_Tutorial The tree view holds the data to be displayed in the tree. 1026 Document Object Model DOM, Tutorials, XUL, XUL_Tutorial The Document Object Model (DOM) can be used with XUL elements to get ...
Creating toolbar buttons (Customize Toolbar Window) - Archive of obsolete content
This article explains how to add a toolbar button to a Toolkit application (such as Firefox, Thunderbird, or Kompozer) using overlays. Its intended audience is extension developers with a basic knowledge of XUL and CSS. We assume that you're also familiar with the basics of creating Firefox extensions and have the Hello World extension working. Another tutorial, which walks you through the entire process from the beginning, is also available. Creating an overlay The first step is to create an overlay for the document containing the toolbar you wish to enhance. Explaining overlays is beyond the scope of this tutorial -- you can read about them in the XUL Tutorial. To overlay a document, you need to know its URI. You can find a list of URIs for the most commonly overlaid documents at the...
...anet.com references: <toolbarbutton>, <toolbaritem>. How to adjust toolbar button's label position A forum thread about adding an item to the toolbar (instead of just adding it to palette) right after an extension is installed. Note that this is not recommended. There is another page on mdc with information about adding buttons to various windows in SeaMonkey. Includes useful information about overlays for ChatZilla. ...
Manifest Files - Archive of obsolete content
browser.jar!/content/browser/ xpcnativewrappers=yes overlay chrome://global/content/viewSource.xul chrome://browser/content/viewSourceOverlay.xul overlay chrome://global/content/viewPartialSource.xul chrome://browser/content/viewSourceOverlay.xul overlay chrome://browser/content/pageInfo.xul chrome://pippki/content/PageInfoOverlay.xul Two packages are listed here, 'branding' and 'browser'. Three overlays are also specified, which allow content from different packages to combine together. Extensions will make the most use of overlays, since they merge their UI with the browser UI. The file paths for the branding and browser packages use jar URLs as the content is packaged up into an archive. A JAR archive can be created with a ZIP utility. For a JAR file located in the chrome directory, the syntax...
...la-directory>/chrome/chrome.rdf. You should find references to your application ID in there. If not, something is wrong with registration. If it is there, you are probably using the wrong chrome URL when you load the file. Try deleting the <mozilla-directory>/chrome/chrome.rdf file. It will get regenerated. Also delete the entire <mozilla-directory>/chrome/overlayinfo/ directory if you are using overlays. Make sure that the URL in the line you added to installed-chrome.txt ends with a slash and the file itself ends with a blank line. On Windows, file URLs are of the form file:///C:/files/app/, where C is the drive letter. Make sure the contents.rdf file is in the right directory and is well-formed. Open the contents.rdf file in Mozilla to see if it parses as well-formed XML. If not, you will s...
XUL Tutorial - Archive of obsolete content
He has graciously given us permission to use it as part of the MDN. Original Document Information Author: Neil Deakin Copyright Information: (C) 1999-2005 XULPlanet.com ...
...He has graciously given us permission to use it as part of the MDN. Original Document Information Author: Neil Deakin Copyright Information: (C) 1999-2005 XULPlanet.com ...
Building the WebLock UI
o you access it once it's installed? Once it's installed and registered, the WebLock component itself is ready to go: XPCOM finds it and adds it to the list of registered components, and then WebLock observes the XPCOM startup event and initializes itself. But you still have to add your new UI into the browser so it can call the component, and the Mozilla overlay mechanism is the way to do this. Overlays are XUL files that register themselves to be dynamically inserted into the appropriate parts of the browser UI at runtime. webLockOverlay.xul The XUL that defines the new icon is small: it's a little icon that calls a JavaScript function to load the weblock.xul file we defined previously. The icon is actually a separate <statusbarpanel/> element that gets overlaid into the main browser, along w...
...me://weblock/content/weblock.js"/> <statusbar id="status-bar"> <statusbarpanel class="statusbarpanel-iconic" id="weblock-status" insertbefore="offline-status" oncommand="loadWebLock();" status="none"/> </statusbar> </overlay> Note that the root element for this file is not a <window/> but an <overlay/>. In overlays the ordinarily unique id attributes that XUL elements use to distinguish themselves are purposely made redundant with UI in the existing browser with which they should be merged. In this case, the weblock <statusbarpanel/> appears as a child of the <statusbar/> element with id "status-bar". This id is the same one used by the <statusbar/> in navigator.xul, which means that the overlay mechanism w...
/loader - Archive of obsolete content
// panel -> resource:///modules/panel.js '': 'resource:///modules/', // Allow relative URLs and resolve them to add-on root: // ./main -> resource://my-addon/root/main.js './': 'resource://my-addon/root/' } }); The order of keys in paths is irrelevant since they are sorted by keys from longest to shortest to allow overlapping mapping. The example above overlays the base path '' with a different mapping for 'toolkit/' prefixed modules. modules The loader may optionally be provided with a set of module exports. In the SDK we call these "pseudo modules". This feature may be used in a few different ways: To expose an API that doesn't have a JS file with an implementation or is written in an incompatible format such as JSM: let { Loader } = requir...
Extension Theming Guidelines - Archive of obsolete content
ement for your skin package allowing them to provide their own styles for all of your content. Branding Certain items of your extensions style, in particular logos and icons can be kept in the chrome content package such that they are not replaceable by custom themes Stylesheets guidelines Include Stylesheets For every new window that your extension adds and for every window that your extension overlays content into be sure to add a stylesheet from your chrome skin package. While it may be tempting to use the same stylesheet in multiple places try to avoid this so that themes can correctly target the right windows. CSS Selectors When writing stylesheet rules for windows that you are overlaying always try to be specific with the css selector. If you are not then you run a risk of conflicting wit...
Chapter 3: Introduction to XUL—How to build a more intuitive UI - Archive of obsolete content
18. <tabbox> <tabs> <tab label="tab1"/> <tab label="tab2" selected="true"/> </tabs> <tabpanels> <tabpanel> <checkbox label="check1"/> </tabpanel> <tabpanel orient="vertical"> <checkbox label="check2"/> <checkbox label="check3"/> </tabpanel> </tabpanels> </tabbox> Listing 22: Tabs in use Figure 18: Output from listing 22 Other XUL functions Overlays One of XUL's distinctive features is overlays. These give you the ability to combine multiple XUL documents and process them as a single XUL document. In Firefox, this is used to modularize functions and implement extensions. By inserting an xul-overlay processing instruction between the XML declaration and the opening tag of the root element, the XUL document specified by the xul-overlay will ...
Adding Events and Commands - Archive of obsolete content
window.addEventListener( "load", function() { XulSchoolChrome.BrowserOverlay.init(); }, false); You can do something similar with the onunload event, to do any cleanup you may need. ...
Adding menus and submenus - Archive of obsolete content
You should avoid having deep menus or too many options, since they are confusing for most users. ...
Appendix D: Loading Scripts - Archive of obsolete content
ia script tags run in partially loaded documents. Problems can ensue if the script immediately attempts to access DOM nodes. This is easily resolved by deferring the work to a dynamically added onload hander. (A standalone XUL window can use an onload attribute.) Example The following overlay will load the script "overlay.js" from the same directory as the overlay file into the window which it overlays. The script will be read with the UTF-8 encoding, based on the encoding of the overlay, and will execute as JavaScript version 1.8, based on the version specified in the script tag. <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE overlay> <overlay id="script-overlay" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> <script type="application/javascript;versi...
JavaScript Object Management - Archive of obsolete content
need to be defined in the overlay because they are already defined globally in the browser.js file in Firefox. We only need to define them when we're making windows of our own, or when we're working with code outside of the chrome (or porting your code to SeaMonkey, which doesn't have those constants declared in the main window). Include the Cc and Ci constants in all XUL windows that are not overlays, all JSM files, and all XPCOM components (see further ahead). Do this even if you don't need them now. It's better to just make a habit out of it. This is a point that is worth highlighting: modules work outside of the window scope. Unlike scripts in the chrome, modules don't have access to objects such as window, document, or other global functions, such as openUILink. These are all UI compon...
Setting Up a Development Environment - Archive of obsolete content
re out what the nodes correspond to in the Firefox UI. Install the Firebug extension. Open the Firebug window and go to an AJAX-heavy page such as Gmail or Facebook. Open and enable the Net tab. Try to identify what is going on with some of the requests being sent. Now that you know how to quickly monitor your project and test changes, we'll learn how to add new UI elements to Firefox, through overlays and new windows. << PreviousNext >> This tutorial was kindly donated to Mozilla by Appcoast. ...
User Notifications and Alerts - Archive of obsolete content
t works on Firefox 3 on Ubuntu Linux, but we haven't tested all distributions and Firefox versions. Because of the inconsistent support and temporary nature of these alerts, we don't recommend using this service to show information the user needs to know and can't get in any other way. Custom alerts Creating custom solutions for alerting the user is not complicated, given the advantages of XUL overlays and CSS positioning. However, these solutions are prone to be buggy and have accessibility issues. You should use the 2 alternatives mentioned above whenever possible. If none of those fit your needs then this is an acceptable solution. An easy way to display alerts is to include a hidden box in your overlay, which you can fill with any content you need before removing the hidden attribute so th...
Overlay extensions - Archive of obsolete content
Prior to Firefox 4, and the Gecko 2 engine that powers it, this was the only way to develop extensions. This methodology has largely been superseded by restartless extensions, and the Add-on SDK, which is built on top of them. The privileged JavaScript APIs described here can still be used in these newer types of add-ons. ...
Setting up an extension development environment - Archive of obsolete content
fs can now be found at https://github.com/Noitidart/DevPrefs. maxVersion needs to be set in install.rdf javascript.options.showInConsole = true. Logs errors in chrome files to the Error Console. nglayout.debug.disable_xul_cache = true. Disables the XUL cache so that changes to windows and dialogs do not require a restart. This assumes you're using directories rather than JARs. Changes to XUL overlays will still require reloading of the document overlaid. browser.dom.window.dump.enabled = true. Enables the use of the dump() statement to print to the standard console. See window.dump for more info. You can use nsIConsoleService instead of dump() from a privileged script. javascript.options.strict = true. Enables strict JavaScript warnings in the Error Console. Note that since many people have...
Add-ons - Archive of obsolete content
xuldev website (we want to host source code on MDC, not on xuldev), and to Japanese things (like some specific locales, which have been translated to French since non-latin characters are not well supported). Hotfix Extension This document has been moved to the Add-ons wiki. How to convert an overlay extension to restartless First off, what kind of add-on are we talking about here? Well, XUL overlays and windows, JSM files, chrome & resource mappings with localization, default preferences, but no XPCOM components of your own. Some of that will have to be replaced and the rest will need to be loaded differently. Inline options Firefox 7 supports a new syntax for defining extensions' preferences for both bootstrapped and traditional extensions. The user interface for the preferences defined w...
Creating a status bar extension - Archive of obsolete content
lets you add new content to an existing document. In this case, we want to augment the UI of the Firefox browser, so we specify the URI of the Firefox main window's XUL file, "chrome://browser/content/browser.xul", as the interface to overlay onto, and the URI of our own XUL file, "chrome://status-bar-sample-1/content/status-bar-sample-1.xul", as the interface to overlay onto the browser. See XUL Overlays for details on how overlays work. You can also find more details about format of chrome manifests in the Chrome Manifest section. The XUL overlay The XUL overlay file contains the XUL description of the user interface we want to add to Firefox. Our overlay file, status-bar-sample-1.xul, looks like this: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE overlay > <overlay id="status-bar-sample-...
Creating a Firefox sidebar extension - Archive of obsolete content
This is an separate XUL file that specifies the location of menu items. The sidebar here is added to the View | Sidebar menu. The overlay file is listed in Example 4. Example 4. chrome/content/firefoxOverlay.xul <?xml version="1.0"?> <!DOCTYPE overlay SYSTEM "chrome://emptysidebar/locale/emptysidebar.dtd"> <overlay id="emptySidebarOverlay" xmlns="http://www.mozil...
Enabling the behavior - updating the status periodically - Archive of obsolete content
With this code in place, restarting Mozilla should cause the Tinderbox status panel to display the current tinderbox state. To confirm this state, go to Tinderbox and verify that the panel displays the current worst state of active tinderbox clients. << PreviousNext >> ...
Finding the file to modify - Archive of obsolete content
based User Interface Language (and is pronounced like "Zool"), is an XML-based language specifically designed for describing application interfaces. It contains elements for all common UI widgets (menus, buttons, toolbars, etc.) and many sophisticated ones (trees, browsers, color pickers). Each window and dialog box in Mozilla is defined by a single XUL file (in some cases other XUL files called overlays contribute portions of another window's structure). To add a tinderbox status icon to Mozilla, we need to find the XUL file that defines the structure of the browser window. The best way to find a XUL file for a window is to use the DOM Inspector. The DOM Inspector is a tool bundled with Mozilla that allows you to examine the DOM of web pages and XUL windows. To access it, go to the "Tools" menu...
Making it into a dynamic overlay and packaging it up for distribution - Archive of obsolete content
li resource="urn:mozilla:package:tinderstatus"/> </RDF:Seq> <RDF:Description about="urn:mozilla:package:tinderstatus" chrome:displayName="Mozilla Tinderstatus Extension" chrome:author="Myk Melez" chrome:name="tinderstatus" chrome:extension="true" chrome:description="Displays tinderbox status for the Mozilla codebase."> </RDF:Description> <RDF:Seq about="urn:mozilla:overlays"> <RDF:li resource="chrome://navigator/content/navigator.xul"/> </RDF:Seq> <RDF:Seq about="chrome://navigator/content/navigator.xul"> <RDF:li>chrome://tinderstatus/content/tinderstatusOverlay.xul</RDF:li> </RDF:Seq> </RDF:RDF> install.js, on the other hand, goes into the tinderstatus-installer directory: initInstall( "Mozilla Tinderstatus Extension", "/mozdev/tinderstatus", ...
Creating a Mozilla Extension - Archive of obsolete content
webtool for tracking source code status, to get the status of the code. Completing this tutorial will give you a basic understanding of how Mozilla's user interface (UI) is constructed, how to find the source code for the UI you want to extend, how to make an installation of Mozilla modifiable, how to use Mozilla's network library to load and parse web pages in JavaScript, and how to use dynamic overlays to package a Mozilla extension for installation by others. Contents Prerequisites Tinderbox Making a Mozilla installation modifiable Finding the file to modify Finding the code to modify Adding the structure Specifying the appearance Enabling the behavior - retrieving tinderbox status Enabling the behavior - updating the status bar panel Enabling the behavior - updating the status pe...
Extensions - Archive of obsolete content
host application, there are some Prism-specific issues that you need to handle when creating your extension. Most notably, the Prism application ID and the differences in the user interface (UI). Extensions typically overlay the host application's UI to add toolbar buttons, menus and other features. One of Prism's features is an extreme lack of UI elements, which means that trying to use the same overlays in Firefox and Prism is really not possible. The Basics In order to install an extension in Prism, you need to follow the guidelines for building a Mozilla-based extension. To support Prism specifically, you'll need to add Prism to the list of target applications in the extension's install.rdf file. The code snippet will look something like this: <em:targetApplication> <!- Prism -> <Descripti...
Extensions - Archive of obsolete content
Menus. For example, to add an item to the end of the Tools menu, use the following: <menupopup id="menu_ToolsPopup"> <menuitem label="Thesaurus"/> </menupopup> Note that other extensions may be adding their own items into the same menus. Because of this, the new item might not appear at the end of the menu but before a menuitem added by another extension, depending on the order in which the overlays are applied. As you cannot predict this order, you should not rely on any menuitems being in particular positions in the presence of other extensions. Modifying the context menu An extension may wish to modify the context menu associated with the browser area. Normally, this menu displays menu items specific to what was context clicked or focused. For instance, opening a context menu for a link...
Special per-platform menu considerations - Archive of obsolete content
in the Tools menu on other platforms. When moved to the application menu, the label and shortcut keys are overridden by platform conventions. However, regardless of the platform, the command event will be fired on the menu item when it is activated by the user. Notes for Firefox extension developers On the Mac, some elements, once moved to the Application menu, are no longer accessible from XUL overlays or from JavaScript injected into browser.xul. For example, using document.getElementById() for the Quit menu item returns the hidden item that still sits in the File menu. To change these items in Firefox, overlay hiddenWindow.xul instead. ...
Toolbars - Archive of obsolete content
Documentation XUL School: Adding Toolbars and Toolbar Buttons A helpful tutorial to creating toolbars and toolbar buttons. Toolbar customization events A look at the events that are sent during toolbar customization; you can use these to be kept aware of changes to toolbars. Creating toolbar buttons How to use overlays to add toolbar buttons to Mozilla applications. Custom toolbar button Another example of how to create a toolbar button, complete with a sample extension you can download and try. Code snippets: Toolbar Code snippets that are helpful when working with toolbars. Community View Mozilla extension dev...
More Wizards - Archive of obsolete content
as you switch pages. Thus, the Back button will be disabled on the first page so you don't have to set it yourself. Another useful property of the wizard is currentPage, which holds a reference to the currently displayed wizardpage. You can also modify the current page by changing this property. If you do change it, the various page change events will still be fired. Next, we'll see how to use overlays to handle common content. << PreviousNext >> ...
XUL Changes for Firefox 1.5 - Archive of obsolete content
o-based behaviour should be changed. <stringbundle> The <stringbundle> element has a strings property which may be used to retrieve an enumeration of all of the strings in the bundle. Draggable tabs The tabbrowser now allows the user to rearrange tabs by dragging them. <tabbox> The <tabbox> element now supports a selectedIndex attribute to specify the tab to be selected by default. Loading overlays dynamically XUL now supports loading overlays dynamically with the document.loadOverlay function. Original Document Information Author(s): Neil Deakin ...
prefwindow - Archive of obsolete content
the user choices, without waiting for the dialog to close with OK. The second preference is browser.preferences.animateFadeIn, again a boolean preference. This one can be safely omitted in XULrunner-based applications but you can override the default behavior (true for Mac OS X and false for other platforms) setting it. For animateFadeIn to work properly, contents of prefpanes should be put into overlays. Note for Mac OS X: a common way of opening modal windows on Mac OS X that are not attached as a sheet to the main window is to use nsIWindowWatcher.openWindow() with a null parentWindow. This does not work with prefwindows, breaking the general behavior of the window and in particular the list of prefpanes. Prefer the classical window.openDialog() with the following window features: "chrome,ti...
toolbarpalette - Archive of obsolete content
lbar items. It is not displayed, but is used by the toolbar customization dialog to display the list of items. The children of the toolbarpalette should be the complete list of toolbarbuttons and toolbaritems that can be added to the toolbar. Do not add the various spacing items, as those are added automatically. You can add your own custom buttons to the Firefox browser by using an overlay that overlays the toolbarpalette with the idBrowserToolbarPalette. Examples <toolbarpalette id="BrowserToolbarPalette"> <toolbarbutton id="toolbarpalette-button" class="toolbarbutton-class" label="&mylabel;" tooltiptext="&mytiptext;" oncommand="somefunction()"/> </toolbarpalette> Attributes Inherited from XUL element align, alloweve...
XUL - Archive of obsolete content
ble XUL controls. The Joy of XUL Describes the key features and components of XUL. Menus and Popups Guide A guide on using menus and popup panels. Template Guide A detailed guide on XUL templates, which is a means of generating content from a datasource. Drag and Drop How to perform drag and drop operations. Overlays Overlays are used to describe extra content for the UI. They provide a powerful mechanism for extending and customizing existing XUL applications. XUL Periodic Table This collection of XUL demos used to be available as a web page, but can no longer be viewed in Firefox since support for Remote XUL was disabled. There is a XULRunner app...
XULRunner Hall of Fame - Archive of obsolete content
ons, many of which use XULRunner. XULRunner 5+ based applications These applications use XULRunner 5 or greater. AZARDI Free Win/Mac/Linux ePub 2/ePub 3 desktop reader using HTML5 and latest CSS features of Gecko for interactive e-books. Version updates match the rapid release cycle. Now available with XULRunner 30 with I18N support. MathML support is significant. Includes SMIL audio overlays and IDPF Fixed Layout. celtx All-in-one media pre-production software. Source ChatZilla A standalone version of the ChatZilla IRC client. Conkeror A highly programmable web browser with a leopard-oriented design inspired by Emacs. Source Evergreen - Staff Client Evergreen is an open source library system. Source iEditWeb A client/server based content manage...
Updating an extension to support multiple Mozilla applications - Archive of obsolete content
With these simple tweaks, this extension will work in all three of these applications, and works exactly the same way in them all. ...
Window.importDialog() - Archive of obsolete content
So be careful. Specification This is not part of any specification. ...
Chrome registration
skin A skin package is registered with the line: skin packagename skinname uri/to/files/ [flags] This will register a skin package when resolving the URI chrome://packagename/skin/... . The skinname is an opaque string identifying an installed skin. If more than one skin is registered for a package, the chrome registry will select the best-fit skin using the user's preferences. style Style overlays (custom CSS which will be applied to a chrome page) are registered with the following syntax: style chrome://URI-to-style chrome://stylesheet-URI [flags] Note: Only stylesheets at chrome URIs can be applied in this way. override In some cases an extension or embedder may wish to override a chrome file provided by the application or XULRunner. In order to allow for this, the chrome registrati...
Interface Compatibility
Jetpack SDK and APIs are not yet complete. The stable version 1.0 of the Jetpack SDK is planned for later in 2010. Documented APIs which are shipped as part of the Jetpack SDK are designed to work in future versions of Firefox. Achieving this compatibility may require rebuilding the extension with a new version of the Jetpack SDK. JavaScript/XUL Interfaces Traditional extensions written using XUL overlays and XPCOM have access to the full power of the Mozilla platform. With the power, however, comes the understanding that the Mozilla platform is constantly changing and many APIs may change in future versions of Firefox. In micro/maintenance releases, there should be no incompatible changes to interfaces, except as a last resort when a security fix leaves no other option. This includes not only X...
about:memory
fier. You can look in about:support to see which add-on a particular identifier belongs to. For example, 59c81df5-4b7a-477b-912d-4e0fdf64e5f2 is Chatzilla. All JavaScript memory usage for an add-on is measured separately and shown in this sub-tree. For add-ons that use separate windows, such as Chatzilla, the memory usage of those windows will show up in this sub-tree. For add-ons that use XUL overlays, such as AdBlock Plus, the memory usage of those overlays will not show up in this sub-tree; it will instead be in the non-add-on sub-trees and won't be identifiable as being caused by the add-on. Other Measurements This section contains multiple trees, includes many that cross-cut the measurements in the "explicit" tree. For example, in the "explicit" tree all DOM and layout measurements are ...
Leak And Bloat Tests
run the following command: make mailbloat This will run the tests and produce some result files. See Debugging Memory Leaks for more information on what to do with this data. TODO: add more information on processing output. ...
Web Replay
"Debugger integration", child objects besides scripts and script sources become invalid when the debugger resumes execution, and must be reconstructed each time the replaying process pauses. Inspecting a replaying process Access to JS objects in the replaying process is currently only done through the JS Debugger interface -- Debugger.Object, Debugger.Frame.eval, and so forth. This interface overlays a separate implementation from the C++ Debugger, implemented in devtools/server/actors/replay/debugger.js. This communicates with the replaying process via JSON and is fairly easy to extend for new features (such as web console support). Appendix: Impacts on Gecko development Web Replay is designed to minimize the places where other parts of Gecko need to know about it or interact with it. Th...
Toolkit API
: specific information about how to package themes Multiple-item Extension Packaging: specific information about multiple-item extension XPIs XUL Application Packaging: specific information about how to package XULRunner applications Chrome Registration Printing in XUL Apps See also The following developer pages contain examples and discussions of particular topics: XUL XUL overlays Developing extensions XULRunner Developing themes DOM RDF Storage ...
Index
ed, our extension will look like this: 76 Building a Thunderbird extension 3: install manifest Extensions, thunderbird The install.rdf file is an XML file that provides general information about the extension. 77 Building a Thunderbird extension 4: chrome manifest Extensions, thunderbird The file called chrome.manifest tells Thunderbird what packages and overlays are provided by the extension. Open the file called chrome.manifest that you created and add this code: 78 Building a Thunderbird extension 5: XUL Extensions, thunderbird Thunderbird's user interface is written in XUL and JavaScript. XUL is an XML grammar that provides user interface widgets like buttons, menus, toolbars, trees etc. We add widgets by inserting new XUL DOM ele...
Building a Thunderbird extension 1: introduction
t for newer information. This tutorial will introduce you to the components of a Thunderbird extension and will show you how to build your own. ...
Building a Thunderbird extension 5: XUL
i.ja can be easily browsed by copying the file to a different location and renaming it to omni.zip. If you have trouble with one zip manager (like 7zip) try another (like WinRAR). In messenger.xul we find the status bar, which looks something like this.: <statusbar id="status-bar" ...> ... <statusbarpanel>s ... </statusbar> <statusbar id="status-bar"> is a "merge point" for a XUL overlay. XUL Overlays are a way of attaching other UI widgets to a XUL document at run time. A XUL Overlay is a .xul file that specifies XUL fragments to insert at specific merge points within a "master" document. These fragments can specify widgets to be inserted, removed or modified. In this example you are adding a line to the indented statusbar. Therefore it becomes an item owned by the id called "status-bar". Th...
Add Option to Context Menu
This can be reached by adding these lines to the chrome.manifest file: overlay chrome://messenger/content/mailWindowOverlay.xul chrome://myaddon/content/tbOverlay-tb2.xul appversion<3.0 overlay chrome://messenger/content/mailWindowOverlay.xul chrome://myaddon/content/tbOverlay-tb3.xul appversion=>3.0 Than we need two overlay XUL files with content from examples above. Note: I...
Element.getClientRects() - Web APIs
iv p, ol, table { border: 1px solid blue; } span, li, th, td { border: 1px solid green; } JavaScript The JavaScript code draws the client rects for all HTML elements that have CSS class withClientRectsOverlay assigned. function addClientRectsOverlay(elt) { /* Absolutely position a div over each client rect so that its border width is the same as the rectangle's width. Note: the overlays will be out of place if the user resizes or zooms. */ var rects = elt.getClientRects(); for (var i = 0; i != rects.length; i++) { var rect = rects[i]; var tableRectDiv = document.createElement('div'); tableRectDiv.style.position = 'absolute'; tableRectDiv.style.border = '1px solid red'; var scrollTop = document.documentElement.scrollTop || document.body.scrollTop; var ...
Web Video Text Tracks Format (WebVTT) - Web APIs
WebVTT is a text based format, which must be encoded using UTF-8. Where you can use spaces you can also use tabs. There is also a small API available to represent and manage these tracks and the data needed to perform the playback of the text at the correct times. WebVTT files The MIME type of WebVTT is text/vtt. ...
Styling Columns - CSS: Cascading Style Sheets
rule. Rules are only drawn between columns and not on the outer edges. Rules should also only be drawn between columns which have content. In this next example I have created a 5px dotted rule with a color of rebeccapurple, using the longhand values. Note that the rule itself does not take up any space: a wide rule will not push the columns apart to make space for the rule. Instead, the rule overlays the gap. In this next example we have a very wide rule of 40px and a 10px gap. The rule displays under the content of the columns. In order to make space on both sides of the rule, the gap would need to be increased to be larger than 40px. Summary This details all the current ways in which column boxes can be styled. In the next guide we will take a look at making elements inside a container...