xul

How to dynamically change shortcut key in Firefox?

I have a firefox extension which can be activated by a shortcut key. I want users to be able to change the key combo dynamically. My XUL looks like this <keyset id="ksMain"> <key id="keyDoMyThing" modifiers="control,shift" key="e" command="cmdDoMyThing"/> </keyset> cmdDoMyThing is a reference to an element in a commandset. When I...

Hover text at mouse created from firefox toolbar add-on

Hi all, I'm creating a firefox add-on, and I have a situation where if someone clicks on a specific item in my toolbarbutton menupopup, I want to display some text to appear beside the mouse for a couple seconds. I don't mean mouseover text, because when they click on the item, the I close the menupopup. I mean something like what's s...

Using Firefox XUL, is is possible to eliminate the listbox border with a style?

I have the following XUL fragment, which works fine, but puts a 1 pixel border around the entire listbox. I've tried a number of CSS styles, but cannot eliminate the border. Any ideas? <listbox> <listhead> <listheader id="adj_lh_1" label = "one"/> <listheader id="adj_lh_2" label = "two"/> </listhead> <listcols> <listcol fle...

Can I have an XUL panel without a shadow in my Firefox extension?

XUL panels in a Firefox extension overlay always come with a shadow for free. How can I remove this shadow? Example code for the shadow effect I don't want: <popupset> <panel id="popuppanel" width="500" noautohide="true"> <vbox> <label value="test"/> <label value=""/> <label value=""/> ...

What lightboxes work inside Firefox extensions?

I want to use a lightbox like Shadowbox or similar inside a Firefox extension. But Shadowbox causes Javascript errors like this: Error: document.write is not a function Source file: chrome://iframe/content/shadowbox/shadowbox.js Line: 1557 Which lightbox supports IFRAMEs and will run correctly inside an extension (ie. added to the ove...

How do you access the message content in the Thunderbird message compose window?

I am trying to write a Thunderbird extension which will let you compose a message but it will process the message text before sending it out. So I need access to the plain text content of the email body. Here is what I have so far, just as some test code in the Extension Developer Javascript console. var composer = document.getElement...

XUL Textbox inside Popup not working

Hi, I am working on creating a Firefox extension. I have added a textbox inside a popup. The popup opens on clicking on a toolbar button. The textbox is appearing but does not let me edit it. I have not given any read only attributes. Here is the code: <popupset id="myPopupSet"> <popup id="trial-popup" noautohide="true" positio...

XPCOM tab based variable.

When user clicks on of the button in toolbar it opens an url in the browser windows. user can process that content on clicking on some other button on the toolbar. However it creates a problem when i have multiple tabs opened and each tab contains different url (so when i send a request to the server through toolbar actions it takes id ...

XUL and document.write()

I'm attempting to create a simple firefox extension and am stumbling on what I'm allowed to do in a XUL window. I'd like to use document.write or get a handle on a textarea to collect data and display it when a button is clicked. Are there any tutorials on how to do this? From what I've been reading, people have suggested opening a ne...

How to set the profile directory for xulrunner apps using a custom relative path?

Is there an easy way to create a cross platform portable Xulrunner application? By "portable" I mean what the guys on http://portableapps.com/ do, but in addition I would like to be able to put on the flash stick whatever platform runtime I need. For example If I want my application to run on Linux, I put the linux build of Xulrunner a...

Mozilla extension: create tab/window with DOM document instead of URI?

I have a web service that requires special headers to be sent in the request. I am able to retrieve expected responseXMLs using an XMLHttpRequest and setRequestHeader(). Now I would like to create a new tab (or window) containing the response document. I would like the default XMLPrettyPrint.xsl file applied to it and when the source is...

Why can't I disable this XUL menuitem?

I'm at my wits end, and it's probably something really simple.. But I've got basically this code: var menuitem = document.getElementById('mymenuitem'); alert(menuitem); alert(varImChecking == null); menuitem.setAttribute('disabled', (varImChecking == null) ? 'true' : 'false'); It should be disabling the 'mymenuitem' menu item, but has...

How to create hidden Firefox Extension?

Is it possible to create Firewox extension that will not shown in Extensions List? And so cannot be deinstalled manually? ...

How do I access a .xul file using a chrome:// URL ?

I'm learning how to make firefox extensions. I have created a directory called findfile, under which I have the directories content/ skin/ and locale/ . There is a findfile.xul file in the content/ directory. The other two are empty I have placed a findfile.manifest file under /home/akshay/.mozilla/firefox/xxxx.dev/chrome/ The content...

barebones minimal example: using XUL to http POST

I am trying to figure out if XUL is a good candidate for GUI forms in intranet apps. It's been difficult to find anyone who actually uses it though. Therefore I thought I'd ask for a hello world style example. Suppose I have a php page that does nothing but display any content sent to it via HTTP POST. (e.g., http://mysite.com/postdump...

How can I change (from JavaScript) the title of a XUL window?

In a xulrunner app, I seem to be unable to set the title from JavaScript. I have tried setting in these two ways: <?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <window id="mywindow" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" onload="go();"> <!-- your code here --> ...

How to achieve flow layout in XUL?

I'm creating a UI using XUL. I have N buttons I would like to add, and all I care about is that they all show on the form, regardless of the form's size. If I add a new button later or remove an existing button, I'd like to just delete the one <button> element rather than having to move things around inside grid or hbox/vbox elements. ...

In XUL, how do I know a browser-tag has finished loading?

I'm developing a firefox extension based on this tutorial which is a FF 2.0 extension (second part of the tutorial is at this url) The main thing that is important is that it uses <iframe id="contentview" src="http://www.ibm.com/developerworks/web" flex="2"/> In the backend code, when clicking the GO button, this happens: contentvie...

How do you force a XUL tree to scroll in code?

I have an app written in XUL which contains a custom tree view that has many items. I've got a button that allows the selected item to be removed but my problem is that whenever this button is pressed, the tree gets scrolled all the way to the top. I have tried to fix this by re-selecting the item at the old index, but unfortunately this...

accessing cookies, hopefully in javascript

I am working on a Firefox add-on that will allow users (all of whom are part of a specific group; this add-on is very limited in audience scope) to see the status of their authentication cookie from the status bar. We all have to authenticate to access work-related sites, but we get no warning when the cookie expires, so this causes anno...