Search completed in 0.91 seconds.
163 results for "vb":
Your results are loading. Please wait...
VBArray.toArray - Archive of obsolete content
non-standard. do not use! ...
... non-standard. do not use! ...
... non-standard. do not use! ...
...And 11 more matches
VBArray.dimensions - Archive of obsolete content
the second part is javascript code that determines the number of dimensions in the safe array and the upper bound of each dimension. both of these parts go into the <head> section of an html page. ...
...the second part is javascript code that determines the number of dimensions in the safe array and the upper bound of each dimension. both of these parts go into the <head> section of an html page. ...
...the second part is javascript code that determines the number of dimensions in the safe array and the upper bound of each dimension. both of these parts go into the <head> section of an html page. ...
...And 10 more matches
VBArray - Archive of obsolete content
the indices of each dimension can be different. ...
...the indices of each dimension can be different. ...
...the indices of each dimension can be different. ...
...And 10 more matches
nsINavBookmarkObserver
toolkit/components/places/nsinavbookmarksservice.idlscriptable this interface is an observer for bookmark changes. 1.0 66 introduced gecko 1.8 inherits from: nsisupports last changed in gecko 21.0 (firefox 21.0 / thunderbird 21.0 / seamonkey 2.18) method overview void onbeforeitemremoved(in long long aitemid, in unsigned short aitemtype, in long long aparentid, in acstring aguid, in acstring aparentguid); obsolete since gecko 21.0 void onbeginupdatebatch(); void onendupdatebatch(); void onfolderadded(in print64 folder, in print64 parent, in print32 index); obsolete since gecko 1.9 void onfolderchanged(in print64 folder, in acstring property); obsolete since gecko 1.9 void onfoldermoved(in print64 f...
...is about to be removed. it is called before the actual removal takes place. void onbeforeitemremoved( in long long aitemid, in unsigned short aitemtype, in long long aparentid, in acstring aguid, in acstring aparentguid ); parameters aitemid the id of the bookmark that will be removed. aitemtype the type of the item that is about to be removed; this is one of the nsinavbookmarksservice.type constants. aparentid the id of the folder containing the item. aguid the unique id associated with the item. aparentguid the unique id associated with the item's parent. onbeginupdatebatch() this method notifies this observer that a batch transaction has started. other notifications will be sent during the batch change, but the observer is guarantee...
...short aitemtype, in nsiuri auri, in autf8string atitle, in prtime adateadded, in acstring aguid, in acstring aparentguid ); parameters aitemid the id of the item that was added. aparentid the id of the folder to which the item was added. aindex the item's index in the folder. aitemtype the type of the item that was added. this should be one of the nsinavbookmarksservice.type constants. auri the uri of the item that was added when aitemtype is type_bookmark, null otherwise. atitle the title of the added item. adateadded the stored date added value, in microseconds from the epoch. aguid the unique id associated with the item. aparentguid the unique id associated with the item's parent. onitemchanged() th...
...And 9 more matches
VBArray.getItem - Archive of obsolete content
the second part is javascript code that iterates the visual basic safe array and prints out the contents of each element. ...
...the second part is javascript code that iterates the visual basic safe array and prints out the contents of each element. ...
...the second part is javascript code that iterates the visual basic safe array and prints out the contents of each element. ...
...And 8 more matches
VBArray.lbound - Archive of obsolete content
non-standard. do not use! this object is a microsoft extension and is only supported in internet explorer. the vbarray.lbound method returns the lowest index value used in the specified dimension of a vbarray. syntax safearray.lbound(dimension) remarks if the vbarray is empty, the lbound method returns undefined. if dimension is greater than the number of dimensions in the vbarray, or is negative, the method generates a "subscript out of range" error. parameters safearray a vbarray object. dimension optional optional. the dimension of the vbarray for which the lower bound index is wanted. if omitted, lbound behaves as if a 1 was passed. example the following example consists of three parts. the first part is vbscript code to create a visual basic safe array. the second part i...
... the vbarray for which the lower bound index is wanted. if omitted, lbound behaves as if a 1 was passed. example the following example consists of three parts. the first part is vbscript code to create a visual basic safe array. the second part is javascript code that determines the number of dimensions in the safe array and the lower bound of each dimension. since the safe array is created in vbscript rather than visual basic, the lower bound will always be zero. both of these parts go into the <head> section of an html page. the third part is the javascript code that goes in the <body> section to run the other two parts. ...
... code that determines the number of dimensions in the safe array and the lower bound of each dimension. since the safe array is created in vbscript rather than visual basic, the lower bound will always be zero. both of these parts go into the <head> section of an html page. the third part is the javascript code that goes in the <body> section to run the other two parts. ...
...And 8 more matches
VBArray.ubound - Archive of obsolete content
non-standard. do not use! this object is a microsoft extension and is only supported in internet explorer. the vbarray.ubound method returns the highest index value used in the specified dimension of the vbarray. syntax safearray.ubound(dimension) parameters safearray a vbarray object. dimension optional the dimension of the vbarray for which the higher bound index is wanted. if omitted, ubound behaves as if a 1 was passed. remarks if the vbarray is empty, the ubound method returns undefined. if dim is greater than the number of dimensions in the vbarray, or is negative, the method generates a "subscript out of range" error. example the following example consists of three parts. the first part is vbscript code to create a visual basic safe array. the second part is javascrip...
...e parts. the first part is vbscript code to create a visual basic safe array. the second part is javascript code that determines the number of dimensions in the safe array and the upper bound of each dimension. both of these parts go into the <head> section of an html page. the third part is the javascript code that goes in the <body> section to run the other two parts. ...
...ript code to create a visual basic safe array. the second part is javascript code that determines the number of dimensions in the safe array and the upper bound of each dimension. both of these parts go into the <head> section of an html page. the third part is the javascript code that goes in the <body> section to run the other two parts. ...
...And 7 more matches
nsINavBookmarksService
toolkit/components/places/nsinavbookmarksservice.idlscriptable the bookmarksservice interface provides methods for managing bookmarked history items. bookmarks consist of a set of user-customizable folders. a uri in history can be contained in one or more such folders. 1.0 67 introduced gecko 1.8 inherits from: nsisupports last changed in gecko 14.0 (firefox 14.0 / thunderbird 14.0 / seamonkey 2.11) implemented by: @mozilla.org/browser/nav-bookmarks-service;1. ...
...marked history items. bookmarks consist of a set of user-customizable folders. a uri in history can be contained in one or more such folders. 1.0 67 introduced gecko 1.8 inherits from: nsisupports last changed in gecko 14.0 (firefox 14.0 / thunderbird 14.0 / seamonkey 2.11) implemented by: @mozilla.org/browser/nav-bookmarks-service;1. ...
...0 67 introduced gecko 1.8 inherits from: nsisupports last changed in gecko 14.0 (firefox 14.0 / thunderbird 14.0 / seamonkey 2.11) implemented by: @mozilla.org/browser/nav-bookmarks-service;1. ...
...And 7 more matches
vbox - Archive of obsolete content
Archive › Mozilla › XUL › vbox
« xul reference home [ examples | attributes | properties | methods | related ] a container element which can contain any number of child elements. this is equivalent to the box element, except it defaults to vertical orientation. more information is available in the xul tutorial. ...
...ence home [ examples | attributes | properties | methods | related ] a container element which can contain any number of child elements. this is equivalent to the box element, except it defaults to vertical orientation. more information is available in the xul tutorial. ...
Bookmarks - Archive of obsolete content
null, // postdata bookmarksservice.getbookmarkstoolbarfolder(), // bookmark folder 0); // index in the folder firefox 3 firefox 3 provides a reworked set of api for working with history and bookmarks. the documentation for the new api is available at places. the places bookmarks service, provided by the nsinavbookmarksservice interface, provides methods for creating, deleting, and manipulating bookmarks and bookmark folders. this article offers examples for how to perform common bookmark management tasks using the bookmarks service. initiating the bookmarks service as is the case with nearly all interfaces, before you can use the bookmarks service, you need to get access to it: var bmsvc = components...
...his article offers examples for how to perform common bookmark management tasks using the bookmarks service. initiating the bookmarks service as is the case with nearly all interfaces, before you can use the bookmarks service, you need to get access to it: var bmsvc = components.classes["@mozilla.org/browser/nav-bookmarks-service;1"] .getservice(components.interfaces.nsinavbookmarksservice); creating a bookmark folder creating a new bookmark folder is done using the nsinavbookmarksservice.createfolder() method. for example, to create a new folder in the bookmarks menu: var menufolder = bmsvc.bookmarksmenufolder; // bookmarks menu folder var newfolderid = bmsvc.createfolder(menufolder, "folder name here", bmsvc.default_index); this code locates the bookmarks men...
...bookmarks menu's folder, then creates a new folder named "folder name here" in it. specifying default_index as the index at which to insert the new folder places it at the end of the list. you can easily change this code to insert the new folder into the bookmarks toolbar by changing bookmarksmenufolder to another folder attribute. creating a new bookmark to create a new bookmark, use the nsinavbookmarksservice.insertbookmark() method. the uri for the bookmark needs to be specified using an nsiuri object. var ios = components.classes["@mozilla.org/network/io-service;1"] .getservice(components.interfaces.nsiioservice); var uri = ios.newuri("http://google.com/", null, null); var newbkmkid = bmsvc.insertbookmark(newfolderid, uri, bmsvc.default_index, ""); this example ...
...And 11 more matches
Manipulating bookmarks using Places
the places bookmarks service, provided by the nsinavbookmarksservice interface, provides methods for creating, deleting, and manipulating bookmarks and bookmark folders. this article offers examples for how to perform common bookmark management tasks using the bookmarks service. initiating the bookmarks service as is the case with nearly all interfaces, before you can use the bookmarks service, you need to get access to it: var bmsvc = components.classes["@mozilla.org/browser/nav-bookmarks-service;1"] .getservice(components.interfaces.nsinavbookmarksservice); creating a bookmark folder creating a new bookmark folder is done using the nsinavbookmarksservice.createfolder() method. for example, to create a new folder in the bookmarks menu: var menufolder...
...bookmarks menu's folder, then creates a new folder named "folder name here" in it. specifying default_index as the index at which to insert the new folder places it at the end of the list. you can easily change this code to insert the new folder into the bookmarks toolbar by changing bookmarksmenufolder to another folder attribute. creating a new bookmark to create a new bookmark, use the nsinavbookmarksservice.insertbookmark() method. the uri for the bookmark needs to be specified using an nsiuri object. var ios = components.classes["@mozilla.org/network/io-service;1"] .getservice(components.interfaces.nsiioservice); var uri = ios.newuri("http://google.com/", null, null); var newbkmkid = bmsvc.insertbookmark(newfolderid, uri, bmsvc.default_index, ""); this example ...
... var ios = components.classes["@mozilla.org/network/io-service;1"] ...
...And 10 more matches
Using Recursive Templates - Archive of obsolete content
<person name="cleopatra"/> <person name="laura secord"/> </group> </people> we could display this data in a flat list by using the right query: <query expr="group/person/"> or, we could display one level for the two groups, and use another level for each person. <groupbox type="menu" datasources="people.xml" ref="*" querytype="xml"> <template> <query expr="*"/> <action> <vbox uri="?" class="indent"> <label value="?name"/> </vbox> </action> </template> </groupbox> in this simplified example, the xpath expression just gets the list of child elements of the reference node. for the outermost iteration, a vbox is created with a child label. since the initial reference node is the root of the xml source document, the results are two elements, one for ...
...esult for each person in the xml source. the content of the action body is again generated for each result, but instead of being inserted inside the outermost groupbox, this new content is inserted inside the content generated from the previous iteration. the content is always inserted directly inside the element with the uri attribute. the result is output like the following: <groupbox> ... ...
...r each result, but instead of being inserted inside the outermost groupbox, this new content is inserted inside the content generated from the previous iteration. the content is always inserted directly inside the element with the uri attribute. the result is output like the following: <groupbox> ... ...
...And 8 more matches
Places Developer Guide
uri metadata first introduced in firefox 3. it encompasses history, bookmarks, tags, favicons, and annotations. there are two models of identity in the system: uris, and unique integer identifiers for items in the bookmark system. some of the apis are uri-centric, some use item ids. the api signature and context usually make clear which is required. ...
...two models of identity in the system: uris, and unique integer identifiers for items in the bookmark system. some of the apis are uri-centric, some use item ids. the api signature and context usually make clear which is required. bookmarks the toolkit bookmarks service is nsinavbookmarksservice: var bookmarks = cc["@mozilla.org/browser/nav-bookmarks-service;1"] .getservice(ci.nsinavbookmarksservice); this service provides methods for adding, editing and deleting items in the bookmarks collection. ...
...ks service is nsinavbookmarksservice: var bookmarks = cc["@mozilla.org/browser/nav-bookmarks-service;1"] .getservice(ci.nsinavbookmarksservice); this service provides methods for adding, editing and deleting items in the bookmarks collection. types in the bookmark system there are the four types of items in the bookmarks system, and their identifiers in the idl: bookmark: nsinavbookmarksservice.type_bookmark folder: nsinavbookmarksservice.type_folder separator: nsinavbookmarksservice.type_separator dynamic container: nsinavbookmarksservice.type_dynamic_container identifying items in the bookmark system items in the bookmarks collection are identified by an id unique to the user's profile. most of the apis provided by the bookmarks service use an item's id to identi...
...And 8 more matches
Special Condition Tests - Archive of obsolete content
of content at the top level and different content at the recurisive level. for example, the bookmarks toolbar in a web browser might display buttons at the first level, but menus and submenus for content below that. templates have a means of allowing a rule to match only if the generated content would be inserted inside an element with a particular tag name. for instance, if the container was a <vbox>, a rule could be created that would only match a <vbox> element. this is useful for recursive templates, since the inner iterations may use different content. it's most useful to distinguish between the outer and inner levels during template generation. for the bookmarks toolbar, the outer content is inserted into an <hbox>, but at lower levels, the content will be inserted into a <menu> in ca...
...nserted into an <hbox>, but at lower levels, the content will be inserted into a <menu> in case you aren't clear, the tag that must match for the outer iteration is the root element, the one with the datasources attribute on it. for inner iterations, it will be the element with the uri attribute from the previous iteration. ...
...lear, the tag that must match for the outer iteration is the root element, the one with the datasources attribute on it. for inner iterations, it will be the element with the uri attribute from the previous iteration. here is a previous example, rewritten to use the parent matching syntax: <vbox datasources="people.xml" ref="*" querytype="xml"> <template> <query expr="*"/> <rule parent="vbox"> <action> <groupbox uri="?"> <caption label="?name"/> </groupbox> </action> </rule> <rule> <action> <label uri="?" value="?name"/> </action> </rule> </template> </vbox> previously, an assign element was used to assign the tagname of the result to a variable, which was then compared in a rule condition. the code above acco...
...And 7 more matches
Web audio codec guide - Web media technologies
g audio for specific use cases, including everything from high quality surround sound to low-fidelity audio for speech-only use. as a patent-encumbered format, aac support is somewhat less predictable. for example, firefox only supports aac if support is provided by the operating system or an external library. ...
... support for alac. otherwise, flac is likely a better choice, if you must use a lossless codec. keep in mind, however, that lossless codecs require substantially more bandwidth and storage capacity, and may not be a good choice outside very specific use cases. ...
...apacity, amr can be a great choice. however, if you need high-fidelity reproduction of human speech—or even low-quality music reproduction—you need to choose another format. ...
...And 7 more matches
The Box Model - Archive of obsolete content
lines up its elements horizontally and a vertical box orients its elements vertically. you can think of a box as one row or one column from an html table. various attributes placed on the child elements in addition to some css style properties control the exact position and size of the children. box elements the basic syntax of a box is as follows: <hbox> <!-- horizontal elements --> </hbox> <vbox> <!-- vertical elements --> </vbox> the hbox element is used to create a horizontally oriented box. each element placed in the hbox will be placed horizontally in a row. the vbox element is used to create a vertically oriented box. added elements will be placed underneath each other in a column. there is also a generic box element which defaults to horizontal orientation, meaning that it is ...
...ed underneath each other in a column. there is also a generic box element which defaults to horizontal orientation, meaning that it is equivalent to the hbox. however, you can use the orient attribute to control the orientation of the box. you can set this attribute to the value horizontal to create a horizontal box and vertical to create a vertical box. thus, the two lines below are equivalent: <vbox></vbox> <box orient="vertical"></box> the following example shows how to place three buttons vertically. example 1 : source view <vbox> <button id="yes" label="yes"/> <button id="no" label="no"/> <button id="maybe" label="maybe"/> </vbox> the three buttons here are oriented vertically as was indicated by the box. to change the buttons so that they are oriented horizontally, all you...
...login prompt example you can add as many elements as you want inside a box, including other boxes. in the case of a horizontal box, each additional element will be placed to the right of the previous one. ...
...And 5 more matches
splitter - Archive of obsolete content
ragged, the sibling elements of the splitter are resized. if a grippy is placed inside the splitter, one sibling element of the splitter is collapsed when the grippy is clicked. more information is available in the xul tutorial. attributes collapse, resizeafter, resizebefore, state, substate style classes tree-splitter examples <!-- this bar has some styling associated with it. the vbox is used to hold the .png image that a user clicks on to resize the search bar.--> <splitter tooltiptext="resize the search box" oncommand="alert('the splitter was dragged')"> <vbox id="example_vbox" /> </splitter> attributes collapse type: one of the values below determines which side of the splitter is collapsed when its grippy is clicked. if this attribute is not specified, ...
...ildren/> </tree> splitter resizing and overflow the degree to which a splitter will resize a box, and what happens during the resize and after the limit is reached, depends on the height (or width) specified for the box as an attribute or in css, the min-height (or min-width), the intrinsic height of the box contents, and the presence or absence of a collapse attribute on the splitter. ...
...> </tree> splitter resizing and overflow the degree to which a splitter will resize a box, and what happens during the resize and after the limit is reached, depends on the height (or width) specified for the box as an attribute or in css, the min-height (or min-width), the intrinsic height of the box contents, and the presence or absence of a collapse attribute on the splitter. ...
...And 5 more matches
Chapter 3: Introduction to XUL—How to build a more intuitive UI - Archive of obsolete content
s, window background color, etc, match the currently selected theme in firefox. we can also read in a stylesheet that we had set up ourselves. the xul box model in principle, xul lays out all ui components using combinations of two kinds of boxes: horizontal and vertical. ...
...izontal and vertical. as shown in listing 3, elements can be laid out horizontally using the hbox (horizontal box) element or vertically using the vbox (vertical box) element. when this file is opened in firefox, it is displayed as shown in figure 1. ...
...t horizontally using the hbox (horizontal box) element or vertically using the vbox (vertical box) element. when this file is opened in firefox, it is displayed as shown in figure 1. ...
...And 4 more matches
Index - Archive of obsolete content
sively. after generating a result's content, the builder starts again using a new parent and starting point. naturally, the parent will be the new result's content, rather than the outer containing element, and the starting point will be the endpoint of the previous iteration. for the top level generation the parent insertion point is the element with the datasources attribute, in this example a <vbox>. for nested results, the insertion point is the generated element. here is the content that was generated after one iteration: 1668 result generation xul, xul_template_guide in this section, we'll look at generating template output using rdf datasources. first, however, some background. 1669 rule compilation xul, xul_template_guide a xul template is ma...
...nt. this element is optional and you may just use any other container in place of it. 1917 tabpanels xul elements, xul reference a container to hold the set of pages in a tabbox. the tabpanels element should be placed in a tabbox although it does not have to be a direct child. the children of the tabpanels element become the panels of the tabbox. in most cases you would use a vbox, but they can be any element, although some people like to use tabpanel elements. by clicking the first tab, the first panel will be displayed. by clicking the second tab, the second panel will be displayed and so on. there should be the same number of panels as there are tabs. panels should never be hidden; hiding the tab suffices to make the panel inaccessible. 1918 tabs xul el...
...ree. 1944 triple xul elements, xul reference a triple can be included inside a rule's conditions element. it is used to check for an assertion within a graph. if such an assertion exists, the rule may match, assuming that all the conditions match. if the assertion does not exist, the rule will not match. both the subject and object attributes may be variables. 1945 vbox xul elements, xul reference a container element which can contain any number of child elements. this is equivalent to the box element, except it defaults to vertical orientation. 1946 where xul elements, xul reference indicate a condition that must match for a template result to be used. if the condition is true, the corresponding action body is generated; otherwi...
...And 4 more matches
Rich-Text Editing in Mozilla - Developer guides
ldzl9vj1dusy14wyodhpwibbsvfy6o7ioxw5qbms+wubcztca0ccs4kddqjdtltmrl1o3yitha7opcsd/f4pfvrvdv8pv5xv///////////////////yh5baekab8alaaaaaawabyaaav84ceozgmeakqubmteyzk547qobcfwtm/jgshq4rhmloxfiehqqsawr+z4iayaj0kegtfolizlwre4ocqwrxototaihmcz0tvgmbqkzhayyfewev14eq8iflhnehmfdqkaiskqci2pdc4qbg+oajc0ewadncogo6anqkkoiqa7" /> <img class="intlink" title="print" onclick="printdoc();" src="data:image/png;base64,ivborw0kggoaaaansuheugaaabyaaaawcayaaadetgw7aaaabgdbtueaalgpc/xhbqaaaazis0deap8a/wd/ol2nkwaaaalwsflzaaalewaacxmbajqcgaaaaad0su1fb9oebxczfmgboiwaaaaidevydenvbw1lbnqa9sywvwaaaufjrefuomvtlutsjfeux//n3nn0ydpbh1abrpt4lfqtqkc3jrkkneisiiribbehjjpklivo4m1rrmkkjqirmjruqudkpt71qpipirkpaqdf55tv5vvuszjqtjolseukd3xu/3dpzusc/22wtu2wrn+jg5so/ocdh8ycmjdflehmlkjkvk7kuyn+ufza/rtth76zavocdptrxzqtni3mrwupc+6cktlxz/sddp2...
...a9sywvwaaaufjrefuomvtlutsjfeux//n3nn0ydpbh1abrpt4lfqtqkc3jrkkneisiiribbehjjpklivo4m1rrmkkjqirmjruqudkpt71qpipirkpaqdf55tv5vvuszjqtjolseukd3xu/3dpzusc/22wtu2wrn+jg5so/ocdh8ycmjdflehmlkjkvk7kuyn+ufza/rtth76zavocdptrxzqtni3mrwupc+6cktlxz/sddp2uu9uxlmyxz6qm8v4tz8lhf1h+zdqxt7s8olmxtbf4e8qafhjj3kbp2mzkkthpitjp9vh6ihia+whtasx5brpwuemgdondf/2a4m7ukds1jw662+xkqtkeuoqjktojm2h53yfl15psj04zc94wdtibr26fxlc2mzrvbccebz2kirfd414tkmlezbvgt33+qcohgha81swysew0r1uzfnylmtpx80pngqq91lwvk2jgvgnfvzg6ycyrat16gftw5kkkfo1eqltfh5q2ett0biwf+aitq4fdbk+imyo1oxvgf03wafjqvbckvdffryetxqiffygazths0zwagd7fg5tnnyntp8/fzvgwjofmgg7gox0sakkgqgdmgkbi0njgmeimpgdk5+wacewed0ywblhguz4hw5oduekrblt7dtgdegxacsiznx8zpmwh7k4rkpjcuhdxcul6mdsmmbxdlwch2+xozsgbnzsncee4euyv4pwcpswypw0uhdybkswu1nyjendreqtkjwn2+zvttc1vmstb/mvev/weyslasslimcohobjxw...
...vbckvdffryetxqiffygazths0zwagd7fg5tnnyntp8/fzvgwjofmgg7gox0sakkgqgdmgkbi0njgmeimpgdk5+wacewed0ywblhguz4hw5oduekrblt7dtgdegxacsiznx8zpmwh7k4rkpjcuhdxcul6mdsmmbxdlwch2+xozsgbnzsncee4euyv4pwcpswypw0uhdybkswu1nyjendreqtkjwn2+zvttc1vmstb/mvev/weyslasslimcohobjxw+n3ap/sjefnl5gepzmpu4kg7opr1+tofpyuu3becwykcwqcdfmwfkauo90fhkdinbcamvqnymgqueagqwcohbdc1rjv9pild8ibvkz6qyviibqgtjpx4k0xpigezorn1da0cij4vfr0ta3wvbxh/rjdcufv6r2zpgph/e4pxsbcpeatqprjniso203/5s/za171mv8+w1loaaaaaelftksuqmcc"> <img class="intlink" title="undo" onclick="formatdoc('undo');" src="data:image/gif;base64,r0lgodlhfgawaomkadljwlie33morpgjuykl8aezxqpd+7/i19dv3nha7p///////////////////////yh5baekaa8alaaaaaawabyaaarr8mljq7046807tkayejjbnes4eeujvigapwyac0csocq7sdlwjkakca6tomywiargqf3mrqviejkksvlibsfewhdrih4fh/dzmice3/c4nbqbads=" /> <img cla...
...And 4 more matches
Making content editable - Developer guides
ldzl9vj1dusy14wyodhpwibbsvfy6o7ioxw5qbms+wubcztca0ccs4kddqjdtltmrl1o3yitha7opcsd/f4pfvrvdv8pv5xv///////////////////yh5baekab8alaaaaaawabyaaav84ceozgmeakqubmteyzk547qobcfwtm/jgshq4rhmloxfiehqqsawr+z4iayaj0kegtfolizlwre4ocqwrxototaihmcz0tvgmbqkzhayyfewev14eq8iflhnehmfdqkaiskqci2pdc4qbg+oajc0ewadncogo6anqkkoiqa7" /> <img class="intlink" title="print" onclick="printdoc();" src="data:image/png;base64,ivborw0kggoaaaansuheugaaabyaaaawcayaaadetgw7aaaabgdbtueaalgpc/xhbqaaaazis0deap8a/wd/ol2nkwaaaalwsflzaaalewaacxmbajqcgaaaaad0su1fb9oebxczfmgboiwaaaaidevydenvbw1lbnqa9sywvwaaaufjrefuomvtlutsjfeux//n3nn0ydpbh1abrpt4lfqtqkc3jrkkneisiiribbehjjpklivo4m1rrmkkjqirmjruqudkpt71qpipirkpaqdf55tv5vvuszjqtjolseukd3xu/3dpzusc/22wtu2wrn+jg5so/ocdh8ycmjdflehmlkjkvk7kuyn+ufza/rtth76zavocdptrxzqtni3mrwupc+6cktlxz/sddp2...
...a9sywvwaaaufjrefuomvtlutsjfeux//n3nn0ydpbh1abrpt4lfqtqkc3jrkkneisiiribbehjjpklivo4m1rrmkkjqirmjruqudkpt71qpipirkpaqdf55tv5vvuszjqtjolseukd3xu/3dpzusc/22wtu2wrn+jg5so/ocdh8ycmjdflehmlkjkvk7kuyn+ufza/rtth76zavocdptrxzqtni3mrwupc+6cktlxz/sddp2uu9uxlmyxz6qm8v4tz8lhf1h+zdqxt7s8olmxtbf4e8qafhjj3kbp2mzkkthpitjp9vh6ihia+whtasx5brpwuemgdondf/2a4m7ukds1jw662+xkqtkeuoqjktojm2h53yfl15psj04zc94wdtibr26fxlc2mzrvbccebz2kirfd414tkmlezbvgt33+qcohgha81swysew0r1uzfnylmtpx80pngqq91lwvk2jgvgnfvzg6ycyrat16gftw5kkkfo1eqltfh5q2ett0biwf+aitq4fdbk+imyo1oxvgf03wafjqvbckvdffryetxqiffygazths0zwagd7fg5tnnyntp8/fzvgwjofmgg7gox0sakkgqgdmgkbi0njgmeimpgdk5+wacewed0ywblhguz4hw5oduekrblt7dtgdegxacsiznx8zpmwh7k4rkpjcuhdxcul6mdsmmbxdlwch2+xozsgbnzsncee4euyv4pwcpswypw0uhdybkswu1nyjendreqtkjwn2+zvttc1vmstb/mvev/weyslasslimcohobjxw...
...vbckvdffryetxqiffygazths0zwagd7fg5tnnyntp8/fzvgwjofmgg7gox0sakkgqgdmgkbi0njgmeimpgdk5+wacewed0ywblhguz4hw5oduekrblt7dtgdegxacsiznx8zpmwh7k4rkpjcuhdxcul6mdsmmbxdlwch2+xozsgbnzsncee4euyv4pwcpswypw0uhdybkswu1nyjendreqtkjwn2+zvttc1vmstb/mvev/weyslasslimcohobjxw+n3ap/sjefnl5gepzmpu4kg7opr1+tofpyuu3becwykcwqcdfmwfkauo90fhkdinbcamvqnymgqueagqwcohbdc1rjv9pild8ibvkz6qyviibqgtjpx4k0xpigezorn1da0cij4vfr0ta3wvbxh/rjdcufv6r2zpgph/e4pxsbcpeatqprjniso203/5s/za171mv8+w1loaaaaaelftksuqmcc"> <img class="intlink" title="undo" onclick="formatdoc('undo');" src="data:image/gif;base64,r0lgodlhfgawaomkadljwlie33morpgjuykl8aezxqpd+7/i19dv3nha7p///////////////////////yh5baekaa8alaaaaaawabyaaarr8mljq7046807tkayejjbnes4eeujvigapwyac0csocq7sdlwjkakca6tomywiargqf3mrqviejkksvlibsfewhdrih4fh/dzmice3/c4nbqbads=" /> <img cla...
...And 4 more matches
Creating Event Targets - Archive of obsolete content
arks the user adds. create a new directory called "bookmarks", navigate to it, and run jpm init, accepting all the defaults. ...
... .getservice(ci.nsinavbookmarksservice); var bookmarkobserver = { onitemadded: function(aitemid, afolder, aindex) { console.log("added ", bookmarkservice.getbookmarkuri(aitemid).spec); }, onitemvisited: function(aitemid, avisitid, time) { console.log("visited ", bookmarkservice.getbookmarkuri(aitemid).spec); }, queryinterface: xpcomutils.generateqi([ci.nsinavbookmarkobserver]) }; exports.main = function() { bookmarkservice.addobserver(bookmarkobserver, false); }; exports.onunload = function() { bookmarkservice.removeobserver(bookmarkobserver); } try running this add-on, adding and visiting bookmarks, and observing the output in the console. modules as event targets we can adapt this code into a separate module that exposes the sdk's standard ...
... this we'll use the event/core module. ...
...And 3 more matches
Templates - Archive of obsolete content
thers that reference internal rdf datasources will only work if you load them from a chrome url. for security reasons, mozilla doesn't allow access to them from other sources. to view this example, you will need to create a chrome package and load the file from there (you can do this easily, see manifest files). you can then enter the chrome url into the browser url field. example 1 : source <vbox datasources="rdf:bookmarks" ref="nc:bookmarksroot" flex="1"> <template> <button uri="rdf:*" label="rdf:http://home.netscape.com/nc-rdf#name"/> </template> </vbox> here, a vertical box has been created that will contain a column of buttons, one for each top-level bookmark. you can see that the template contains a single button. this single button is used as a basis for all the button...
... adding these features to the container the template is in, which in this case is a box, and to the elements inside the template, we can generate various interesting lists of content from external data. we can of course put more than one element inside a template and add the special rdf references to the attributes on any of the elements. the example below demonstrates this. example 2 : source <vbox datasources="rdf:bookmarks" ref="nc:bookmarksroot" flex="1"> <template> <vbox uri="rdf:*"> <button label="rdf:http://home.netscape.com/nc-rdf#name"/> <label value="rdf:http://home.netscape.com/nc-rdf#url"/> </vbox> </template> </vbox> this creates a vertical box with a button and a label for each bookmark. the button will have the name of the bookmark and the label wil...
...nes that you put directly in the xul file. the id attribute is added to every element created through a template which is set to a value which identifies the resource. you can use this to identify the resource. you can also specify mutliple resource values in the same attribute by separating them with a space, as in the example below. more about resource syntax (xulplanet). example 3 : source <vbox datasources="rdf:bookmarks" ref="nc:bookmarksroot" flex="1"> <template> <label uri="rdf:*" value="rdf:http://home.netscape.com/nc-rdf#name rdf:http://home.netscape.com/nc-rdf#url"/> </template> </vbox> how templates are built when an element has a datasources attribute, it indicates that the element is expected to be built from a template. note that it isn't the template tag tha...
...And 3 more matches
CustomizableUI.jsm
et that does not correspond to the node itself. in particular, toolbars that have a customizationtarget attribute set will have their customization target set to that node. this means widgets will end up in the customization target, not in the dom node with the id that corresponds to the area id. this is useful because it lets you have fixed content in a toolbar (e.g. the panel menu item in the navbar) and have all the customizable widgets use the customization target. using this api yourself is discouraged; you should generally not need to be asking for the dom container node used for a particular area. in particular, if you're wanting to check it in relation to a widget's node, your dom node might not be a direct child of the customize target in a window if, for instance, the window is in...
...e non-default items, non-existent items, and so forth. please don't call unless necessary. canundoreset bool whether the "restore defaults" operation can be reverted. this is only true after "restore defaults" has been performed and no other ui changes happen after the "restore defaults" operation. area constants attribute type description area_navbar string "nav-bar", a constant reference to the id of the navigation toolbar. area_tabstrip string "tabstoolbar", a constant reference to the id of the tabstrip toolbar. area_menubar string "toolbar-menubar", a constant reference to the id of the menubar's toolbar. area_bookmarks string "personaltoolbar", a constant reference to the id of the boo...
...guish items that span the entire menu panel. panel_column_count number 3, the (constant) number of columns in the menu panel. examples createwidget - button type this is likely the code you need for your widget. only rare need a type:custom widget. ...
...And 3 more matches
Extensions support in SeaMonkey 2 - Archive of obsolete content
popup> <menuitem label="menuitem"/> <menuitem label="menuitem"/> <menuitem label="menuitem"/> </menupopup> </button> </hbox> technical note: the code 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. ...
...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. ...
...d, 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. ...
...And 2 more matches
JXON - Archive of obsolete content
= oxmlparent.childnodes.item(nitem); if (onode.nodetype === 4) { scollectedtxt += onode.nodevalue; } /* nodetype is "cdatasection" (4) */ else if (onode.nodetype === 3) { scollectedtxt += onode.nodevalue.trim(); } /* nodetype is "text" (3) */ else if (onode.nodetype === 1 && !onode.prefix) { atmpels.push(onode); } /* nodetype is "element" (1) */ } var nlevelend = atmpels.length, vbuiltval = parsetext(scollectedtxt); if (oparentnode.hasattributes && oxmlparent.hasattributes()) { vresult = objectify(vbuiltval); for (nlength; nlength < oxmlparent.attributes.length; nlength++) { oattrib = oxmlparent.attributes.item(nlength); vresult["@" + oattrib.name.tolowercase()] = parsetext(oattrib.value.trim()); } } else if (nlevelend > nlevelstart) { vresult =...
...arsetext(scollectedtxt); if (oparentnode.hasattributes && oxmlparent.hasattributes()) { vresult = objectify(vbuiltval); for (nlength; nlength < oxmlparent.attributes.length; nlength++) { oattrib = oxmlparent.attributes.item(nlength); vresult["@" + oattrib.name.tolowercase()] = parsetext(oattrib.value.trim()); } } else if (nlevelend > nlevelstart) { vresult = objectify(vbuiltval); } for (var nelid = nlevelstart; nelid < nlevelend; nelid++) { sprop = atmpels[nelid].nodename.tolowercase(); vcontent = getjxontree(atmpels[nelid]); if (vresult.hasownproperty(sprop)) { if (vresult[sprop].constructor !== array) { vresult[sprop] = [vresult[sprop]]; } vresult[sprop].push(vcontent); } else { vresult[sprop] = vcontent; nlength++; } } atmpels...
... note: if you want to freeze the whole object tree (be...
...And 2 more matches
Multiple Rule Example - Archive of obsolete content
because a particular result has a property that others do not. for instance, in an earlier example, one of the photos had a description and the other photos did not. in this case, you might wish to display the photo with a description in a different manner. this is useful if you wish to hide any content that would be needed to display the description. the next example shows how we can do this. ...
... object="?title"/> <triple subject="?photo" predicate="http://purl.org/dc/elements/1.1/description" object="?description"/> <triple subject="?photo" predicate="http://purl.org/dc/elements/1.1/date" object="?date"/> </conditions> <action> <hbox uri="?photo" class="box-padded"> <vbox> <label value="?title"/> <image src="?photo"/> </vbox> <groupbox> <caption label="photo details"/> <label value="?description"/> <label value="date: ?date"/> </groupbox> </hbox> </action> </rule> <rule> <conditions> <content uri="?start"/> <member container="?sta...
...the second rule matches those photos with a title. if a photo did not have a title, it would not match any rule. in the ex...
...And 2 more matches
Rule Compilation - Archive of obsolete content
lts to be generated in the same manner. for instance, if generating the items in a listbox, you will typically use only one rule. if only one rule is needed, the rule element is optional. a template without any rules (or, in fact, one with a rule with no query defined) will generate output unconditionally for each result. template syntax outline here is the outline of the template syntax so far. ...
...this step involves working through the query rules and processing them into internal structures. ...
...y the template again. this means that you can change the rules using dom methods, rebuild the template, and get different results. once the template builder has compiled the rules, query processing and content generation can begin. the template builder generates content lazily, that is, it processes as little as needed, and only continues when necessary. ...
...And 2 more matches
Things I've tried to do with XUL - Archive of obsolete content
can't easily, at least not yet. this means that creating any sort of visual display (not necessarily "ui"; my use case is for creating a calendar time display) that sizes sanely when the user resizes the window is unfortunately very difficult. ...
... display) that sizes sanely when the user resizes the window is unfortunately very difficult. (to add insult, xul layout code *explicitly* trims off '%' from width/height, thus treating it as pixels.) for reference, i'd like the following to give a vbox that resizes along with the window, with the green, red, and blue inside boxes always maintaining a 30%-20%-50% ratio to the height of the parent vbox. ...
...) that sizes sanely when the user resizes the window is unfortunately very difficult. (to add insult, xul layout code *explicitly* trims off '%' from width/height, thus treating it as pixels.) for reference, i'd like the following to give a vbox that resizes along with the window, with the green, red, and blue inside boxes always maintaining a 30%-20%-50% ratio to the height of the parent vbox. ...
...And 2 more matches
Drag and Drop Example - Archive of obsolete content
r)"> </stack> the board only needs to respond to the dragdrop and dragover events. we'll add a boardobserver to the file dragboard.js in a moment. next, a palette will be added to the right side of the window. it will contain three buttons, one to create new buttons, one to create check boxes and the other to create textboxes. this buttons will respond to the draggesture event and start a drag. ...
...we'll create a listobserver object that will set the data to be dragged. note that each button here has an additional elem attribute. this is a made-up attribute. xul doesn't handle it and just ignores it, but we can still retrieve it with the dom's getattribute function. ...
... <script src="chrome://global/content/nsdraganddrop.js"/> <script src="chrome://global/content/nstransferable.js"/> <script src="dragboard.js"/> <stack id="board" style="width:300px; height: 300px; max-width: 300px; max-height: 300px" ondragover="nsdraganddrop.dragover(event, boardobserver)" ondragdrop="nsdraganddrop.drop(event, boardobserver)"> </stack> <vbox> <button label="button" elem="button" ondraggesture="nsdraganddrop.startdrag(event, listobserver)"/> <button label="check box" elem="checkbox" ondraggesture="nsdraganddrop.startdrag(event, listobserver)"/> <button label="text box" elem="textbox" ondraggesture="nsdraganddrop.startdrag(event, listobserver)"/> </...
...ox> <button label="button" elem="button" ondraggesture="nsdraganddrop.startdrag(event, listobserver)"/> <button label="check box" elem="checkbox" ondraggesture="nsdraganddrop.startdrag(event, listobserver)"/> <button label="text box" elem="textbox" ondraggesture="nsdraganddrop.startdrag(event, listobserver)"/> </vbox> </window> var listobserver = { ondragstart: function (event, transferdata, action) { var txt = event.target.getattribute("elem"); transferdata.data = new transferdata(); transferdata.data.adddataforflavour("text/unicode", txt); } }; var boardobserver = { getsupportedflavours : function () { var flavours = new flavourset(); flavours.appendflavour("text/unicode"); ...
Actions - Archive of obsolete content
sing the <xul:action> element which should either be the next sibling of the <xul:query> element (if no rules need be specified) or be a direct child of a <xul:rule> element. the content to generate goes directly inside the action element. this content will be copied for each matching result (though see below for an exception) and inserted into the document. let's look at a simple example first. ...
...instead, the action element is placed directly inside the <xul:template> element after the query is defined. this action contains only one element, but you can put as many or as few elements as you need. in this case, a button will be created for each res...
...e ids on the other parts of the template, such as within the query statements, if you wish to change the statements and rebuild the template. you can use getelementbyid to get at particular results, for instance document.getelementbyid("http://www.xulplanet.com/rdf/c") would retrieve the second generated button. ...
...additional content the previous example generated only a set of buttons, but the action body may contain additional content. for instance, you might want to add a label to each item. <action> <hbox uri="?relateditem"> <label value="related item:"/> <bu...
XUL Event Propagation - Archive of obsolete content
event. this flexibility in the xul event model is the focus of this article. ...
... this flexibility in the xul event model is the focus of this article. ...
...the hierarchy of the interface can be represented as follows: when one of these menuitems raises an event, any of the elements above it in the hierarchy can handle it. in the example above, when the menuitem raises the "command" event, indicating that it has been selected, the menupo...
...the hierarchy of the interface can be represented as follows: when one of these menuitems raises an event, any of the elements above it in the hierarchy can handle it. in the example above, when the menuitem raises the "command" event, indicating that it has been selected, the menupopup, the menu itself, the pa...
scrollbox - Archive of obsolete content
ppear, add style='overflow: auto;'. this may also be used with any other container element. examples the following shows the xul for a bunch of labels. they come out in a box. if their container doesn't give enough room to hold them (geometrically) what happens depends on the enclosing elements; often the content is just clipped off on the bottom or right (depending on what's too big to fit). ...
...st clipped off on the bottom or right (depending on what's too big to fit). <vbox> <label value="01 four score and seven years ago "/> <label value="02 our fathers brought forth on "/> <label value="03 this continent, a new nation, "/> <label value="04 conceived in liberty, and "/> <label value="05 dedicated to the proposition "/> <label value="06 that all men are created equal."/> </vbox> the next bunch of labels is similar, but if the container doesn't give enough room for it, scroll bars will sprout out of nowhere and allow the user to scroll around the big content in the small view space. for the most part, the horizontal and vertical scrollbars will independently handle too-tall and too-wide cases, but each scroll bar takes up additional width and so the appearance of one...
... allow the user to scroll around the big content in the small view space. for the most part, the horizontal and vertical scrollbars will independently handle too-tall and too-wide cases, but each scroll bar takes up additional width and so the appearance of one scroll bar can trigger the other one if it's close to the edge anyway. use overflow:scroll if you want the scroll bars on all the time. ...
...if you want the scroll bars on all the time. <vbox flex="1" style="overflow:auto"> <label value="01 four score and seven years ago "/> <label value="02 our fathers brought forth on "/> <label value="03 this continent, a new nation, "/> <label value="04 conceived in liberty, and "/> <label value="05 dedicated to the proposition "/> <label value="06 that all men are created equal."/> </vbox> the flex="1" above may or may not be needed, or even desired. in our case an enclosing element also was overflow:auto. if the user made the window smaller, the outer box would get smaller in response and sprout its scroll bars. we wanted our vbox to get smaller and sprout its scroll bars instead. note that this example doesn't use a scrollbox tag; you only need that tag if you want to progr...
window - Archive of obsolete content
type examples <?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <!-- run this example using copy & paste in this live xul editor: https://github.com/km-200/xul --> <!-- extremely recommended to keep this css include!! ...
...xtremely recommended to keep this css include!! ...
... activetitlebarcolor type: color string specify background color of the window's titlebar when it is active (foreground). moreover this hides separator between titlebar and window contents. this only affects...
... activetitlebarcolor type: color string specify background color of the window's titlebar when it is active (foreground). moreover this hides separator between titlebar and window contents. this only affects mac os x. chromemargin type: margin stri...
SubtleCrypto.unwrapKey() - Web APIs
lt that is to be used in derivation of the key-wrapping key, alongside the password the user supplies. this must match the salt value that was originally used to derive the key. */ const saltbytes = [180,253,62,216,47,35,90,55,218,233,103,10,172,143,161,177]; /* iv that is to be used in decrypting the key to unwrap. this must the the same iv that was originally used to encrypt the key. */ const ivbytes = [212,187,26,247,172,51,37,151,27,177,249,142]; /* the wrapped key itself. */ const wrappedkeybytes = [6,155,182,208,7,141,44,18,3,151,58,126,68,100,252, 225,241,11,25,201,153,171,102,174,150,29,62,195,110,138,106,109,14,6,108, 148,104,221,22,93,102,221,146,25,65,112,4,140,79,194,164,163,156,250,108, 11,14,220,78,194,161,17,14,57,121,70,13,28,220,210,78,32,46,217,36,165,220, 170,244...
...ing the raw bytes. takes an array containing the bytes, and returns a promise that will resolve to a cryptokey representing the private key. */ async function unwrapprivatekey(wrappedkey) { // 1. get the unwrapping key const unwrappingkey = await getunwrappingkey(); // 2. initialize the wrapped key const wrappedkeybuffer = bytestoarraybuffer(wrappedkey); // 3. ...
...ray containing the bytes, and returns a promise that will resolve to a cryptokey representing the private key. */ async function unwrapprivatekey(wrappedkey) { // 1. get the unwrapping key const unwrappingkey = await getunwrappingkey(); // 2. initialize the wrapped key const wrappedkeybuffer = bytestoarraybuffer(wrappedkey); // 3. initialize the iv const ivbuffer = bytestoarraybuffer(ivbytes); // 4. ...
... const ivbuffer = bytestoarraybuffer(ivbytes); // 4. ...
StringView - Archive of obsolete content
aaaaa3ayaaaaaaaaaacaaaaaaaaeaaaagaaaa4ayaaaaaaadgbmaaaaaaaoagyaaaaaaamaiaaaaaaaa4agaaaaaaaaaaiaaaaaaaagaaaayaaad4bgaaaaaaapggyaaaaaaa+azgaaaaaadqaqaaaaaaanabaaaaaaaacaaaaaaaaaaeaaaabaaaabwcaaaaaaaahajaaaaaaaacakaaaaaaaeqaaaaaaaaaraaaaaaaaaaeaaaaaaaaafdldgqeaaaatauaaaaaaac0buaaaaaaalqfqaaaaaaanaaaaaaaaaa0aaaaaaaaaaqaaaaaaaaauev0zayaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaacaaaaaaaaaavbglinjqvbgqtbgludxgtedg2lty0lnnvljiabaaaabaaaaabaaaar05vaaaaaaacaaaabgaaacaaaaaeaaaafaaaaamaaabhtluaksr2sawefp5pykgmju+b+9ybp2ubaaaaaqaaaaeaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaasaaaasaaaaaaaaaaaaaaaaaaaaaaaaabaaaaasaaaaaaaaaaaaaaaaaaaaaaaaaciaaaagaaaaaaaaaaaaaaaaaaaaaaaaaabsawjjlnnvljyachv0cwbfx2xpymnfc3rhcnrfbwfpbgbfx2dtb25fc3rhcnrfxwbhtelcq18yljiunqaaaaacaaiaaaaaaaeaaqaba...
...aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa+azgaaaaaaaaaaaaaaaaaaaaaaaaaaaa5gnaaaaaaad2a0aaaaaaaayeqaaaaaaaaaaaaaaaaaaaaaaaaaaaaeddqzogkedovskgnc44ljagmjaxmza1mdigkhbyzxjlbgvhc2upaeddqzogkedovskgnc44ljeaac5zew10ywialnn0cnrhygauc2hzdhj0ywialmludgvycaaubm90zs5bqkktdgfnac5ub3rllmduds5idwlszc1pzaauz251lmhhc2galmr5bnn5bqauzhluc3ryac5nbnuudmvyc2lvbgauz251lnzlcnnpb25fcgaucmvsys5kew4alnjlbgeucgx0ac5pbml0ac50zxh0ac5maw5pac5yb2rhdgealmvox2zyyw1lx2hkcgauzwhfznjhbwualmluaxrfyxjyyxkalmzpbmlfyxjyyxkalmpjcgauzhluyw1pywauz290ac5nb3qucgx0ac5kyxrhac5ic3malmnvbw1lbnqaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabsaaaabaaaaagaaaaaaaaaaakaaaaaaaaacaaaaaaaahaaaaaaaaaaaaaaaaaaaaaeaaaaaaaaaaaaaaaaaaaajaaaabwaaaaiaaaaaa...
...aaaaaaguaaaaaaaaa4qeaabaagqaycwaaaaaaaaaaaaaaaaaa5geaabiadqaqbeaaaaaaaaaaaaaaaaaa7qeaabaagqaqcwaaaaaaaaaaaaaaaaaa+qeaabiadqaabuaaaaaaabuaaaaaaaaa/geaacaaaaaaaaaaaaaaaaaaaaaaaaaaegiaabecgaaqcwaaaaaaaaaaaaaaaaaahgiaacaaaaaaaaaaaaaaaaaaaaaaaaaaoaiaabiacwcoa0aaaaaaaaaaaaaaaaaaagluaxquywbjcnrzdhvmzi5jaf9fsknsx0xju1rfxwbkzxjlz2lzdgvyx3rtx2nsb25lcwbyzwdpc3rlcl90bv9jbg9uzxmax19kb19nbg9iywxfzhrvcnnfyxv4agnvbxbszxrlzc42mzu5af9fzg9fz2xvymfsx2r0b3jzx2f1ef9maw5px2fycmf5x2vudhj5agzyyw1lx2r1bw15af9fznjhbwvfzhvtbxlfaw5pdf9hcnjhev9lbnryeqbozwxsby5jaf9frljbtuvfru5ex18ax19kq1jfru5ex18ax19pbml0x2fycmf5x2vuzabfrfloqu1jqwbfx2luaxrfyxjyyxlfc3rhcnqax0dmt0jbtf9prkztrvrfvefctevfaf9fbgliy19jc3vfzmluaqbfsvrnx2rlcmvnaxn0zxjutunsb25lvgfibguazgf0yv9zdgfydabwdxrzqebhtelcq18yljiunqbfzwrhdgeax2zpbmkax19sawjjx3n0yxj0x21haw5aq...
The Box Model - Archive of obsolete content
lar to an html div. it's an invisible rectangular container with no styling at all (divs may have some default styling, though). their behavior is similar. however, one of the fundamental differences between xul and html has been the fact that xul boxes can be oriented vertically or horizontally (this behavior is being introduced into html standards). there are 3 basic box elements in xul: hbox, vbox and box. an hbox is oriented horizontally by default, meaning that its child nodes are displayed next to each other from left to right. a vbox is oriented vertically by default, its child nodes displayed one below the other from top to bottom. a box is a generic version that you can orient as you please, but its default is horizontal orientation, so it's pretty much equivalent to an hbox and it...
...lt is horizontal orientation, so it's pretty much equivalent to an hbox and it is seldom used. here's a very simple example of an hbox with 3 child buttons: <hbox> <button label="cat" /> <button label="parrot" /> <button label="porcupine" /> </hbox> this is how it looks on mac os (the black border was added for illustrative purposes, boxes don't have borders by default): if you use a vbox instead, it looks like this: the orientation of boxes (and most xul elements) can be controlled using the orient attribute or the -moz-box-orient css property. with these you can make an hbox have vertical orientation and viceversa, although that isn't very useful. the css property may be useful on some occasions, but using the orient attribute is not recommended because it mixes content and...
...tml div is as big as its contents unless you override its dimensions using css. this is similarly the case for xul, except there are two flexibility directions to consider. an hbox is as big as its contents horizontally, but it will occupy all the available space vertically. you can make an hbox flexible horizontally with the css property -moz-box-flex or the flex attribute. the same applies to a vbox, but in the other direction. unlike most style attributes, the flex attribute is considered acceptable to use in xul code. this is because this attribute is used much too often, and it would require a great deal of css code to avoid using it. at any rate, it can always be overriden using css, so your extension won't lose skinability because of it. flexibility is defined as a numeric value. th...
Index - Archive of obsolete content
Archive › Mozilla › XUL › Index
sively. after generating a result's content, the builder starts again using a new parent and starting point. naturally, the parent will be the new result's content, rather than the outer containing element, and the starting point will be the endpoint of the previous iteration. for the top level generation the parent insertion point is the element with the datasources attribute, in this example a <vbox>. for nested results, the insertion point is the generated element. here is the content that was generated after one iteration:</vbox> 937 result generation xul, xul_template_guide in this section, we'll look at generating template output using rdf datasources. first, however, some background. 938 rule compilation xul, xul_template_guide a xul template ...
...nt. this element is optional and you may just use any other container in place of it. 1186 tabpanels xul elements, xul reference a container to hold the set of pages in a tabbox. the tabpanels element should be placed in a tabbox although it does not have to be a direct child. the children of the tabpanels element become the panels of the tabbox. in most cases you would use a vbox, but they can be any element, although some people like to use tabpanel elements. by clicking the first tab, the first panel will be displayed. by clicking the second tab, the second panel will be displayed and so on. there should be the same number of panels as there are tabs. panels should never be hidden; hiding the tab suffices to make the panel inaccessible. 1187 tabs xul el...
...ree. 1213 triple xul elements, xul reference a triple can be included inside a rule's conditions element. it is used to check for an assertion within a graph. if such an assertion exists, the rule may match, assuming that all the conditions match. if the assertion does not exist, the rule will not match. both the subject and object attributes may be variables. 1214 vbox xul elements, xul reference a container element which can contain any number of child elements. this is equivalent to the box element, except it defaults to vertical orientation. 1215 where xul elements, xul reference indicate a condition that must match for a template result to be used. if the condition is true, the corresponding action body is generated; otherwi...
Recursive Generation - Archive of obsolete content
sively. after generating a result's content, the builder starts again using a new parent and starting point. naturally, the parent will be the new result's content, rather than the outer containing element, and the starting point will be the endpoint of the previous iteration. ...
...l be the new result's content, rather than the outer containing element, and the starting point will be the endpoint of the previous iteration. for the top level generation the parent insertion point is the element with the datasources attribute, in this example a <vbox>. for nested results, the insertion point is the generated element. ...
...however, since c is the only element that will end up having any additional content, only the second <hbox> element will have additional children added to it. for a nested item, the builder processes the query in the same way as usual, however instead of using the ref attribute as the seed starting point, the end p...
XBL Example - Archive of obsolete content
suitable to hold the page content. the content of the pages will be specified in the xul file, not in xbl, but we'll need to add it inside the deck. the children tag will need to be used. along the bottom, we'll need a button to go the previous page, a label to display the current page number, and a button to go to the next page. example 1 : source <binding id="slideshow"> <content> <xul:vbox flex="1"> <xul:deck xbl:inherits="selectedindex" selectedindex="0" flex="1"> <children/> </xul:deck> <xul:hbox> <xul:button xbl:inherits="label=previoustext"/> <xul:label flex="1"/> <xul:button xbl:inherits="label=nexttext"/> </xul:hbox> </xul:vbox> </content> </binding> this binding creates the slideshow structure that we want. th...
...e added to go to the first and last pages. the label element could be changed to a field where the user could enter the page to go to, or a popup could be added to allow selection of the page from a menu. we could also add a border around the deck with css to make it look a bit nicer. ...
...electedindex="0" flex="1"> <children/> </xul:deck> <xul:hbox> <xul:button xbl:inherits="label=previoustext" oncommand="parentnode.parentnode.parentnode.page--;"/> <xul:description flex="1"/> <xul:button xbl:inherits="label=nexttext" oncommand="parentnode.parentnode.parentnode.page++;"/> </xul:hbox> </xul:vbox> </content> <implementation> <constructor> var totalpages=this.childnodes.length; document.getanonymousnodes(this)[0].childnodes[1].childnodes[1] .setattribute("value",(this.page+1)+" of "+totalpages); </constructor> <property name="page" onget="return parseint(document.getanonymousnodes(this)[0].childnodes[0].getattribute('selectedindex'))...
resizer - Archive of obsolete content
ing the element attribute, to use the resizer to resize the specified element instead of the window. ...
...e="true" windowtype="main" orient="vertical" sizemode="normal" width="400" height="300" persist="screenx screeny width height"> <hbox flex="1"> <vbox width="2" style="background-color: grey;"> <resizer dir="topleft" height="2" style="cursor: nw-resize;"/> <resizer dir="left" flex="1" style="cursor: w-resize;"/> <resizer dir="bottomleft" height="2" style="cursor: sw-resize;"/> </vbox> <vbox flex="1"> <resizer dir="top" height="2" style="background-color: grey; cursor: n-resize;"/> <browser flex="1" id="browser" type="content-primary"/> <resizer dir="bottom" height="2" style="background-color: grey; cursor: s-resize;"/> </vbox> <vbox width="2" style="background-color: grey; overflow: hidden;"> <resizer dir="topright" height="2" style="cursor: ne-resize;"/> ...
...wser" type="content-primary"/> <resizer dir="bottom" height="2" style="background-color: grey; cursor: s-resize;"/> </vbox> <vbox width="2" style="background-color: grey; overflow: hidden;"> <resizer dir="topright" height="2" style="cursor: ne-resize;"/> <resizer dir="right" flex="1" style="cursor: e-resize;"/> <resizer dir="bottomright" height="2" style="cursor: se-resize;"/> </vbox> </hbox> </window> resizing an element <stack style="border: 1px solid black;"> <button id="button" label="resizable" left="18" top="18" right="18" bottom="18"/> <resizer dir="topleft" style="background: black; -moz-appearance: none;" element="button" left="0" top="0" width="16" height="16"/> <resizer dir="topright" style="background: black; -moz-appearance: none;" ...
IPDL Tutorial
hows how these specifiers are used and how these specifiers change the generated abstract actor classes. ...
...used and how these specifiers change the generated abstract actor classes. ...
... can be sent from-child-to-parent both: async baz(); // can be sent both ways }; // pdirectionparent.h class pdirectionparent { protected: virtual void recvbar() = 0; virtual void recvbaz() = 0; public: void sendfoo() { /* boilerplate */ } void sendbaz() { /* boilerplate */ } }; // pdirectionchild.h class pdirectionchild { protected: virtual void recvfoo() = 0; virtual void recvbaz() = 0; public: void sendbar() { /* boilerplate */ } void sendbaz() { /* boilerplate */ } }; you can use the child, parent, and both labels multiple times in a protocol specification. they behave like public, protected, and private labels in c++. parameters message declarations allow any number of parameters. parameters specify data that are sent with the message. their values are seri...
Index
-l can return and print the information for a single, specific certificate. ...
...while the -a argument prints the certificate in ascii format: $ certutil -l -d sql:/home/my/sharednssdb -a -n "certificate authority - example domain" -----begin certificate----- miidmtccaoggawibagibatanbgkqhkig9w0baqufada5mrcwfqydvqqkew5fegft cgxliervbwfpbjeembwga1ueaxmvq2vydglmawnhdgugqxv0ag9yaxr5mb4xdtew mdqyotixnty1ofoxdteymdqxodixnty1ofowotexmbuga1uechmorxhhbxbszsbe b21haw4xhjacbgnvbamtfunlcnrpzmljyxrlief1dghvcml0etccasiwdqyjkozi hvcnaqebbqadggepadccaqocggebao/bquli2kwqxfkmmmg93kn1sanzntxa/vlf tmrih3hqgjvr1ktiy9ag6cb7dskwmthp/+p4pucmql4zrsgt901qxkepyz2dymm2 rnelk+seuipiutozadhndiyse/yude8vqwj0vhcvl0w72qfucsq/wzt7fcrnuiui udewnopsun70glhcj/lvxl7k9bhyd4sq5czktwytfwliiwv+zy/fl6jgbgaqyqb2 bp4irmflogqsxgub1evwvdf1hagpfdspgmnepslg3/3dxn+hdjbz29eu8/xkzqeb 3v0ahkbu80zglllet2zx/...
...ucsq/wzt7fcrnuiui udewnopsun70glhcj/lvxl7k9bhyd4sq5czktwytfwliiwv+zy/fl6jgbgaqyqb2 bp4irmflogqsxgub1evwvdf1hagpfdspgmnepslg3/3dxn+hdjbz29eu8/xkzqeb 3v0ahkbu80zglllet2zx/wdirgjen9ymfgkfpcml+bvirsmh0vscaweaaaobqzcb qdafbgnvhsmegdawgbqatgxhqyrufkiztdp55bzlfr+tfzapbgnvhrmbaf8ebtad aqh/ma4ga1uddweb/wqeawibxjadbgnvhq4efgquae4mr0mkvhyigbxaeew2zra/ rrcwrqyikwybbquhaqeeota3mdugccsgaqufbzabhilodhrwoi8vbg9jywxob3n0 lmxvy2fszg9tywluojkxodavy2evb2nzcdanbgkqhkig9w0baqufaaocaqeai8gk l3xo43u7/tdoeeswpmq+jzsdz3gz85ajt3krolwekvzzza2e2hnsvf2uxbk5amke lrxdserh9g85pv4ky7z8xz71nri3+k3uwmnqkc6t0hhyb1mw/gx8oaaoluqx3bix jbdxji73cf7xuopplhbjjiwygijuo8bezj5l+tf4p38mjz1snltzzpeax5bl0u76 bfu/tzfwbbe8yawytkctmcalbpj6jn2wd3m01kgozw4mmbvsj1crb9hnsgsqyhcu u0ujll1h/rwcjn607+ctekh9jlmuqciqpjnoa+kq/6f7nhnrriuzasibz...
NSS tools : certutil
n return and print the information for a single, specific certificate. ...
...le the -a argument prints the certificate in ascii format: $ certutil -l -d sql:/home/my/sharednssdb -a -n "certificate authority - example domain" -----begin certificate----- miidmtccaoggawibagibatanbgkqhkig9w0baqufada5mrcwfqydvqqkew5fegft cgxliervbwfpbjeembwga1ueaxmvq2vydglmawnhdgugqxv0ag9yaxr5mb4xdtew mdqyotixnty1ofoxdteymdqxodixnty1ofowotexmbuga1uechmorxhhbxbszsbe b21haw4xhjacbgnvbamtfunlcnrpzmljyxrlief1dghvcml0etccasiwdqyjkozi hvcnaqebbqadggepadccaqocggebao/bquli2kwqxfkmmmg93kn1sanzntxa/vlf tmrih3hqgjvr1ktiy9ag6cb7dskwmthp/+p4pucmql4zrsgt901qxkepyz2dymm2 rnelk+seuipiutozadhndiyse/yude8vqwj0vhcvl0w72qfucsq/wzt7fcrnuiui udewnopsun70glhcj/lvxl7k9bhyd4sq5czktwytfwliiwv+zy/fl6jgbgaqyqb2 bp4irmflogqsxgub1evwvdf1hagpfdspgmnepslg3/3dxn+hdjbz29eu8/xkzqeb 3v0ahkbu80zglllet2zx/...
...ucsq/wzt7fcrnuiui udewnopsun70glhcj/lvxl7k9bhyd4sq5czktwytfwliiwv+zy/fl6jgbgaqyqb2 bp4irmflogqsxgub1evwvdf1hagpfdspgmnepslg3/3dxn+hdjbz29eu8/xkzqeb 3v0ahkbu80zglllet2zx/wdirgjen9ymfgkfpcml+bvirsmh0vscaweaaaobqzcb qdafbgnvhsmegdawgbqatgxhqyrufkiztdp55bzlfr+tfzapbgnvhrmbaf8ebtad aqh/ma4ga1uddweb/wqeawibxjadbgnvhq4efgquae4mr0mkvhyigbxaeew2zra/ rrcwrqyikwybbquhaqeeota3mdugccsgaqufbzabhilodhrwoi8vbg9jywxob3n0 lmxvy2fszg9tywluojkxodavy2evb2nzcdanbgkqhkig9w0baqufaaocaqeai8gk l3xo43u7/tdoeeswpmq+jzsdz3gz85ajt3krolwekvzzza2e2hnsvf2uxbk5amke lrxdserh9g85pv4ky7z8xz71nri3+k3uwmnqkc6t0hhyb1mw/gx8oaaoluqx3bix jbdxji73cf7xuopplhbjjiwygijuo8bezj5l+tf4p38mjz1snltzzpeax5bl0u76 bfu/tzfwbbe8yawytkctmcalbpj6jn2wd3m01kgozw4mmbvsj1crb9hnsgsqyhcu u0ujll1h/rwcjn607+ctekh9jlmuqciqpjnoa+kq/6f7nhnrriuzasibz...
certutil
-l can return and print the information for a single, specific certificate. ...
...while the -a argument prints the certificate in ascii format: $ certutil -l -d sql:/home/my/sharednssdb -a -n "certificate authority - example domain" -----begin certificate----- miidmtccaoggawibagibatanbgkqhkig9w0baqufada5mrcwfqydvqqkew5fegft cgxliervbwfpbjeembwga1ueaxmvq2vydglmawnhdgugqxv0ag9yaxr5mb4xdtew mdqyotixnty1ofoxdteymdqxodixnty1ofowotexmbuga1uechmorxhhbxbszsbe b21haw4xhjacbgnvbamtfunlcnrpzmljyxrlief1dghvcml0etccasiwdqyjkozi hvcnaqebbqadggepadccaqocggebao/bquli2kwqxfkmmmg93kn1sanzntxa/vlf tmrih3hqgjvr1ktiy9ag6cb7dskwmthp/+p4pucmql4zrsgt901qxkepyz2dymm2 rnelk+seuipiutozadhndiyse/yude8vqwj0vhcvl0w72qfucsq/wzt7fcrnuiui udewnopsun70glhcj/lvxl7k9bhyd4sq5czktwytfwliiwv+zy/fl6jgbgaqyqb2 bp4irmflogqsxgub1evwvdf1hagpfdspgmnepslg3/3dxn+hdjbz29eu8/xkzqeb 3v0ahkbu80zglllet2zx/...
...ucsq/wzt7fcrnuiui udewnopsun70glhcj/lvxl7k9bhyd4sq5czktwytfwliiwv+zy/fl6jgbgaqyqb2 bp4irmflogqsxgub1evwvdf1hagpfdspgmnepslg3/3dxn+hdjbz29eu8/xkzqeb 3v0ahkbu80zglllet2zx/wdirgjen9ymfgkfpcml+bvirsmh0vscaweaaaobqzcb qdafbgnvhsmegdawgbqatgxhqyrufkiztdp55bzlfr+tfzapbgnvhrmbaf8ebtad aqh/ma4ga1uddweb/wqeawibxjadbgnvhq4efgquae4mr0mkvhyigbxaeew2zra/ rrcwrqyikwybbquhaqeeota3mdugccsgaqufbzabhilodhrwoi8vbg9jywxob3n0 lmxvy2fszg9tywluojkxodavy2evb2nzcdanbgkqhkig9w0baqufaaocaqeai8gk l3xo43u7/tdoeeswpmq+jzsdz3gz85ajt3krolwekvzzza2e2hnsvf2uxbk5amke lrxdserh9g85pv4ky7z8xz71nri3+k3uwmnqkc6t0hhyb1mw/gx8oaaoluqx3bix jbdxji73cf7xuopplhbjjiwygijuo8bezj5l+tf4p38mjz1snltzzpeax5bl0u76 bfu/tzfwbbe8yawytkctmcalbpj6jn2wd3m01kgozw4mmbvsj1crb9hnsgsqyhcu u0ujll1h/rwcjn607+ctekh9jlmuqciqpjnoa+kq/6f7nhnrriuzasibz...
Retrieving part of the bookmarks tree
components.classes["@mozilla.org/browser/nav-history-service;1"] .getservice(components.interfaces.nsinavhistoryservice); var options = historyservice.getnewqueryoptions(); var query = historyservice.getnewquery(); find the folder you want to get known folder ids are retrieved from the bookmarks service. ...
...it contains administrative data as well as user data, and is therefore not recommended for use in querying. ...
...s.classes["@mozilla.org/browser/nav-history-service;1"] .getservice(components.interfaces.nsinavhistoryservice); var options = historyservice.getnewqueryoptions(); var query = historyservice.getnewquery(); var bookmarksservice = components.classes["@mozilla.org/browser/nav-bookmarks-service;1"] .getservice(components.interfaces.nsinavbookmarksservice); var toolbarfolder = bookmarksservice.toolbarfolder; query.setfolders([toolbarfolder], 1); var result = historyservice.executequery(query, options); var rootnode = result.root; rootnode.containeropen = true; // iterate over the immediate children of this folder and dump to console for (var i = 0; i < rootnode.childcount; i ++) { var node = rootnode.getchild(i); dump("child:...
Building the WebLock UI
idgets like the kind you see in menus that divide sets of functionality available there. the parent of the textbox that users enter an url into is something called an <hbox/>, which is a layout widget - often invisible - that controls the way its child elements are rendered. in this case the <hbox/> centers the textbox and the button children, and it orients them horizontally (in contrast to the <vbox/>, which orients its children vertically). notice also that when it's clicked, the button executes a javascript function called addthissite(), which we've already defined in the weblock.js file in client code overview above. weblock.xul <?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <dialog id="weblock_mgg" xmlns="http://www.mozilla.org/keymast...
...esheet href="chrome://global/skin/" type="text/css"?> <dialog id="weblock_mgg" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" title="web lock manager" style="width: 30em;" persist="screenx screeny" screenx="24" screeny="24"> <script src="chrome://weblock/content/weblock.js"/> <hbox> <separator orient="vertical" class="thin"/> <vbox flex="1"> <separator class="thin"/> <hbox align="center"> <textbox id="dialog.input" flex="1"/> <button label="add this url" oncommand="addthissite();"/> </hbox> <hbox align="center"> <radiogroup onchange="togglelock();"> <radio label="lock"/> <radio label="unlock"/> </radiogroup> <spacer flex="1...
...and how do 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...
Document.createElementNS() - Web APIs
y available in some browsers. return value the new element. important namespace uris html http://www.w3.org/1999/xhtml svg http://www.w3.org/2000/svg mathml http://www.w3.org/1998/math/mathml xul http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul xbl http://www.mozilla.org/xbl example this creates a new <div> element in the xhtml namespace and appends it to the vbox element. although this is not an extremely useful xul document, it does demonstrate the use of elements from two different namespaces within a single document: <?xml version="1.0"?> <page xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" xmlns:html="http://www.w3.org/1999/xhtml" title="||working with elements||" onload="init()"> <script type="application/...
...this particular example is actually an xul document with embedded xhtml, however, the recommendation still applies. specifications specification status comm...
...tml", "div"); txtnode = document.createtextnode("this is text that was constructed dynamically with createelementns and createtextnode then inserted into the document using appendchild."); newdiv.appendchild(txtnode); container.appendchild(newdiv); } ]]></script> <vbox id="containerbox" flex="1"> <html:div> the script on this page will add dynamic content below: </html:div> </vbox> </page> the example given above uses inline script which is not recommended in xhtml documents. this particular example is actually an xul document with embedded xhtml, however, the recommendation still applies. specifications specification status comment domthe definition of 'document.createelementns()' in that specification. living standard ...
SubtleCrypto.importKey() - Web APIs
mat. pem format is a way to encode binary data in ascii. it consists of a header and a footer, and in between, the base64-encoded binary data. a pem-encoded privatekeyinfo looks like this: -----begin private key----- mig2ageambagbyqgsm49agegbsubbaaibigemigbagebbdau9bd0jxdff5ov380z 9vieun2w5kjdz3hbuadencxliamsoquktffaou71eldn0tshzaniaarmuhcee/cp xmjgc1roj0d0k6vluqta+jvcwigxciaukoethcngzdkcrd4pkxdbvbcijdzkvo+l ml2fikoovzh/8yetkmjumb804g6omjuc9vvojcrv0ydasmykkjmjblg= -----end private key----- to get this into a format you can give to importkey() you need to do two things: base64-decode the part between header and footer, using window.atob(). convert the resulting string into an arraybuffer. see the examples section for more concrete guidance. subjectpublickeyinfo you can use this form...
...aaoibaqdd0tpv/du2vftjvxj1t/gxtk39snbvroaeb/jkzxae+xa0h+3lhzaqiqnmfacibsgifzuvegb+7tqxwqpolofr/r7mvgwcsk98jyrvtved8zmzyyitsy7m2hcasqafikyoouv5vzyre87/leyzzbpf3bqq4idaqu+k9hj5fkuu6rroeohsdnjc+vddqlschxvmolz9vtt+ok9j4/tolwr4cg8khdlburcby6gpclo3dpu09sw+6ctx2cx4mkxx6o/0mmdtmacr/vu50kdrmlefezyowpaehhmfywybtuzbipvizvp8wfcsknmbfi1s9a9pdbqnebwwhhx3/hsebt2bagmbaaecggeabei1p6nf6zs7mjlybdv+pfl5rjl2coqly6tovvzvblmkcppjyfunipdk2tk2i897zaxfhpdbikmllm2hq6jzqkb110oantpdg0jxzmiihps32s1d/kilhjgff4hjd4nxp1l1dp8bupollorr2tym2x6dccgfw9lhtr8o03qp4hjn84vjgiwadyck83mgs4nrsnhkdiqynwx1ajkly51yek6rcrdmi0th2rxrrinoc35svv+apt2rkomgi52rwtesea1kzgfrxjq61rejif6p2vxecvhex6cwlx014lgk43z6q28p6hgeevefijyqcuea5du/myb/qsrscosxlxbqwqkbgqd1+fdc9zimrvi+km7nx2ckbn8rjrdmuh5sbxn2myjdrud8bynnzkcgkmgxvxsvjrbmvorby2txoiqudzkk5md3e5o/qzwpw...
...const bufview = new uint8array(buf); for (let i = 0, strlen = str.length; i < strlen; i++) { bufview[i] = str.charcodeat(i); } return buf; } const pemencodedkey = `-----begin public key----- miibijanbgkqhkig9w0baqefaaocaq8amiibcgkcaqeay3xo3u13dc+xojwqywojlcboq5fovy8llnqcjm1w1bftxihoajwohihuirmctv7dzx47tllmarskvtrjd0df92jx/xy20lz+dxp8yl5yuwafga3xko3lsjgeoex10nb8jfkmgsb7qiudtvvbbudfd5fwibmctacwwx7nyewwdb7a9cfxj7ejrdrdak3ux/tomlhfxvlqsl341tkcf4zqoz96rfpugpplofvn0x66cm1pqckdhzje6u5xge964zkkyuppsy6dcie4obhw4vdjgumlzv0z7ud010rlineugde2fqbfy/c+uwignpbpkkq+bv/uigs6dhqtcved5wgybqidaqab -----end public key-----`; function importrsakey(pem) { // fetch the part of the pem string between header and footer const pemheader = "-----begin public key-----"; const pemfoote...
clipboard - Archive of obsolete content
dolor sit amet</blink>", "html"); if the clipboard contains html content, open it in a new tab. var clipboard = require("sdk/clipboard"); if (clipboard.currentflavors.indexof("html") != -1) require("sdk/tabs").open("data:text/html;charset=utf-8," + clipboard.get("html")); set the clipboard contents to an image. var clipboard = require("sdk/clipboard"); clipboard.set("data:image/png;base64,ivborw0kggoaaaansuheugaaacaaaaagcaya" + "aabzenr0aaaasuleqvryhe3o0qkaiawd0eyqe3q993aq3cbsukpygfsnty" + "n5ugbqpk0baadgp0brdwxwlweaaaaagpsa3rzdaaaaahgpcgrpganzq2fg" + "bwrr9aaaaabjru5erkjggg%3d%3d"); if the clipboard contains an image, open it in a new tab. var clipboard = require("sdk/clipboard"); if (clipboard.currentflavors.indexof("image") != -1) requi...
..."sdk/clipboard"); if (clipboard.currentflavors.indexof("image") != -1) require("sdk/tabs").open(clipboard.get()); as noted before, data type can be easily omitted for images. if the intention is set the clipboard to a data url as string and not as image, it can be done by specifying a different flavor, like text. var clipboard = require("sdk/clipboard"); clipboard.set("data:image/png;base64,ivborw0kggoaaaansuheugaaacaaaaagcaya" + "aabzenr0aaaasuleqvryhe3o0qkaiawd0eyqe3q993aq3cbsukpygfsnty" + "n5ugbqpk0baadgp0brdwxwlweaaaaagpsa3rzdaaaaahgpcgrpganzq2fg" + "bwrr9aaaaabjru5erkjggg%3d%3d", "text"); globals functions set(data, datatype) replace the contents of the user's clipboard with the provided data. parameters data : string the data to put...
Using XPCOM without chrome - Archive of obsolete content
le for the xpcom bookmark observer. examples bookmarks observer normally, a bookmark observer would require chrome components and xpcomutils as described in the following links: (observing changes to bookmarks and tags) , (creating event targets). however, with the sdk module , we can remove this need. below is an example, where we extend the xpcom module's unknown class with an nsinavbookmarkobserverinterface and one of its optional interface methods (onitemchanged). we can then create an object from it and add it as an observer to the bookmarks service. // this removes the need to import ci and the xpcomutils const { class } = require("sdk/core/heritage"); const { unknown } = require('sdk/platform/xpcom'); const { placesutils } = require("resource://gre/modules/plac...
...). we can then create an object from it and add it as an observer to the bookmarks service. ...
HTML to DOM - Archive of obsolete content
element is overkill, or does not meet your needs, or you can't fulfill its requirements. while working on donkeyfire, i discovered the iframe xul element, and it is very easy to implement it. as an example, i will show a browser overlay .xul file, and some javascript code to access it. here is some xul code you can add to your browser overlay .xul file. ...
...frame xul element, and it is very easy to implement it. as an example, i will show a browser overlay .xul file, and some javascript code to access it. here is some xul code you can add to your browser overlay .xul file. ...
Connecting to Remote Content - Archive of obsolete content
sform the xml you receive (in our case, the example xml document above) and convert it into xul. the xslt tutorial contains details for building these templates. ...
...after that, the xslt stylesheet can be imported into an xslt processor as shown below. now, the processor is ready to perform the transformation. ...
Custom XUL Elements with XBL - Archive of obsolete content
d have a strong relationship with each other, it makes sense to keep them together. as for the css file, it's usually good to have a single file declaring all bindings in your extension. content under the content tag you define the xul content that will be displayed for your element. ...
...ave a single file declaring all bindings in your extension. content under the content tag you define the xul content that will be displayed for your element. <content> <xul:hbox> <xul:image class="xulshoolhello-person-image" xbl:inherits="src=image" /> <xul:vbox flex="1"> <xul:label xbl:inherits="value=name" /> <xul:description xbl:inherits="value=greeting" /> </xul:vbox> <xul:vbox> <xul:button label="&xulshoolhello.remove.label;" accesskey="&xulshoolhello.remove.accesskey;" oncommand="document.getbindingparent(this).remove(event);" /> </xul:vbox> </xul:hbox> </content> our element is very simple, displaying an image, a couple of text lines and a button. here are a couple of important things to notice: the "xul:" namespace ...
The Essentials of an Extension - Archive of obsolete content
enu" label="&xulschoolhello.hello.label;" accesskey="&xulschoolhello.hellomenu.accesskey;" insertafter="helpmenu"> <menupopup> <menuitem id="xulschoolhello-hello-menu-item" label="&xulschoolhello.hello.label;" accesskey="&xulschoolhello.helloitem.accesskey;" oncommand="xulschoolchrome.browseroverlay.sayhello(event);" /> </menupopup> </menu> </menubar> <vbox id="appmenusecondarypane"> <menu id="xulschoolhello-hello-menu-2" label="&xulschoolhello.hello.label;" accesskey="&xulschoolhello.hellomenu.accesskey;" insertafter="appmenu_addons"> <menupopup> <menuitem id="xulschoolhello-hello-menu-item-2" label="&xulschoolhello.hello.label;" accesskey="&xulschoolhello.helloitem.accesskey;" oncommand="xulschoolchrom...
... there are two similar code blocks, because in modern versions of firefox, particularly on windows, a single firefox menu button is presented, with simplified menu options, rather than an extensive menu bar. the second code block covers the common menu button case; the first code block covers all other cases. check menu...
XUL user interfaces - Archive of obsolete content
ing sure that you scroll to get all of it: <?xml version="1.0"?> <?xml-stylesheet type="text/css" href="style7.css"?> <!doctype window> <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" title="css getting started - xul demonstration" onload="init();"> <script type="application/javascript" src="script7.js"/> <label class="head-1" value="xul demonstration"/> <vbox> <groupbox class="demo-group"> <caption label="day of week calculator"/> <grid> <columns> <column/> <column/> </columns> <rows> <row> <label class="text-prompt" value="date:" accesskey="d" control="date-text"/> <textbox id="date-text" type="timed" timeout="750" oncommand="refresh();"/> <...
...copy and paste the content from here, making sure that you scroll to get all of it: /*** xul demonstration ***/ window { -moz-box-align: start; background-color: -moz-dialog; font: -moz-dialog; padding: 2em; } .head-1 { font-weight: bold; font-size: 200%; padding-left: 5px; } /* the group box */ .demo-group { padding: 1em; ...
Images, Tables, and Mysterious Gaps - Archive of obsolete content
ther main choice is leave the image inline and alter the vertical alignment of the image with respect to the line box. for example, you could try the following: td img {vertical-align: bottom;} this will cause the bottom edges of the images to be aligned with the bottom of the line box, instead of the baseline. as we can see in figure 10, this has the intended effect: the space underneath our navbar images is gone. however, the decorative cell is still too tall, and other images are misaligned with respect to the text around them. again, we could class images, cells, or rows in order to narrow down the focus of the effect. however, the styles shown above won't overcome the problem of one-pixel images, because the line box surrounding them will be the height of the font-size for the tabl...
...image. in addition, any other image which is shorter than the line box is tall will still have space appear around it-- as happened with the red spacer cell. the one-pixel image in the cell is aligned with the bottom of the cell now, but the line box is back and it's the size of normal text. see, for example, figure 11, where the font-size of the document has been raised to a large amount. the navbar images now have space appearing above them, and the red spacer got even bigger. it's difficult to avoid this, because the images are (in this approach) still inline and so still participate in the creation of a line box. if that line box gets tall enough, space will begin to appear around the images. looking forward to a fix thanks to mozilla's thorough implementation of css2, the problem ...
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.xu...
...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...
accesskey - Archive of obsolete content
the accesskey text will always be appended as described above. for consistency, this occurs for languages such as japanese even if the labels have their accesskey characters. ...
...s. for example, when an the accesskey for an 'ok' button is 'o', and the accesskey for the button labeled 'キャンセル' (which means 'cancel') is 'c', the labels will be 'ok(o)' and 'キャンセル(c)'. ...
Containment Properties - Archive of obsolete content
e, rather than use the children. this allows you to iterate over a non-container. to do this, use the containment attribute on the root node, set to the predicate to iterate over. let's look back at the very first example again. it doesn't have any containers, but we may want to iterate over the relateditem predicate using the simple query syntax. we can add the containment attribute to do this. <vbox datasources="template-guide-ex1.rdf" ref="http://www.xulplanet.com/rdf/a" containment="http://www.xulplanet.com/rdf/relateditem"> <template> <rule> <label uri="rdf:*" value="rdf:*"/> </rule> </template> </vbox> instead of iterating over a container, this example iterates over a specific predicate. this attribute is useful when the rdf data is structured in s...
...e by separating them with spaces. each will be applied in sequence. the containment attribute also applies to member tests when using the extended template syntax. that is, in addition to iterating over the children, it will iterate over the predicates listed in the containment attribute. for example, the following is equivalent to the previous example, except that the full query syntax is used. <vbox datasources="template-guide-ex3.rdf" ref="http://www.xulplanet.com/rdf/a" containment="http://www.xulplanet.com/rdf/relateditem"> <template> <query> <content uri="?start"/> <member container="?start" child="?child"/> </query> <action> <label uri="?child" value="?child"/> </action> </template> </vbox> try this example. what happens is that...
Introduction - Archive of obsolete content
ource, performs a query on the datasource and generates content based on the results in combination with the template. the type of datasource is specified with the querytype attribute. the type affects how the datasource is used as well as the syntax for specifying queries. content generated by the template is inserted into the xul just as if you had placed it there yourself. here is an example: <vbox datasources="http://www.xulplanet.com/ds/sample.rdf" querytype="rdf"> this example specifies the datasource 'http://www.xulplanet.com/ds/sample.rdf', using the datasource type rdf as indicated by the querytype attribute'. we'll look at rdf datasources first. the template builder loads an rdf datasource using the rdf service in the same way as you would create a datasource through the rdf servi...
.... that means that a template query can grab data from anywhere in all of the datasources. this combining of datasources is often termed 'aggregation'. this can be quite a useful feature and works regardless of the datasource. for instance, you might use the built-in bookmarks datasource which holds the user's browser bookmarks and use your own datasource to add custom data about those bookmarks. <vbox datasources="rdf:bookmarks http://www.xulplanet.com/ds/sample.rdf"> in addition, when using the rdf type for chrome xul (such as in extensions), the datasource rdf:local-store is always included in the composite. the local store is a datasource which is usually used to hold state information such as window sizes, which columns in a tree are showing, and which tree items are open. you can query...
RDF Query Syntax - Archive of obsolete content
« previousnext » let's look at a simple query with two statements. each statement is placed as a direct child of the <query> element within the template. <vbox datasources="http://www.xulplanet.com/ds/sample.rdf" ref="http://www.xulplanet.com/rdf/a"> <template> <query> <content uri="?start"/> <triple subject="?start" predicate="http://www.xulplanet.com/rdf/relateditem" object="?relateditem"/> </query> <rule> ... </rule> </template> </vbox> this query has two statements, each specified with a different tag. the template won't generate anything yet since we still need to fill in the content to be generated which goes in the missing part inside the rule. however, the template builder will be able to com...
...s set to 'http://www.xulplanet.com/rdf/a'. you'll notice that this is the value of the ref attribute which is the desired starting node in the rdf graph. thus, the ?start variable becomes the container or reference variable. actually, in the current template implementation, the above description isn't quite correct. the seed is actually an internal variable set to the container, in this case, the vbox, and the ?start variable is set to the ref later, but that is a minor detail that doesn't make templates more understandable. for this discussion, assume that so far we have a single potential result as above. the content tag doesn't do anything else at this point, meaning it doesn't add anything else to the network of potential results, so processing continues on to the next statement, the tri...
Simple Example - Archive of obsolete content
mple to create. unlike previous examples where we iterated over a property to navigate the graph, here we want to iterate over the children of an rdf container. the container, an rdf seq, has the uri 'http://www.xulplanet.com/rdf/myphotos'. this will be the starting point of the navigation. we want the endpoints to be the three images. first, we set the datasources and ref attributes as needed: <vbox datasources="template-guide-ex2.rdf" ref="http://www.xulplanet.com/rdf/myphotos"> this time, we need to use a new statement, the member condition as well as a triple. <query> <content uri="?start"/> <member container="?start" child="?photo"/> <triple subject="?photo" predicate="http://purl.org/dc/elements/1.1/title" object="?title"/> </query> the seed is set i...
...tp://www.xulplanet.com/rdf/myphotos, ?photo = http://www.xulplanet.com/ndeakin/images/t/obelisk.jpg, ?title = 'obelisk') since the triple is the last statement, three matches total have been found. the action body might look like the following, which displays the image using its url and title in a label. you might note that the image's src attribute uses the member variable ?photo <action> <vbox uri="?photo" align="start"> <image src="?photo"/> <label value="?title"/> </vbox> </action> it shouldn't be too difficult to tell what would appear in the window in this example. you can see if you guessed correctly by viewing the example. « previousnext » ...
Simple Query Syntax - Archive of obsolete content
uery syntax whenever a template does not have a <query> element. if a <query> element is present, the full syntax is used instead. in the simple syntax, the builder will use the default query shown above, although the variable names are randomly generated. since the photos list iterates over the children of a container, we can use the simple syntax. here is what it might look like: <template> <vbox class="box-padded" uri="rdf:*"> <image src="rdf:*"/> <label value="rdf:http://purl.org/dc/elements/1.1/title"/> </vbox> </template> there is no <query> or <action> element used. instead, the builder uses a default query, and the action is placed directly inside the <template> element. you can see that this code is much simpler than the full syntax. to understand how this works, let's...
...veral criteria. in this case, all of the criteria must match for the result to be accepted. for example, to filter for photos with a specific country: <hbox id="photoslist" datasources="template-guide-photos4.rdf" ref="http://www.xulplanet.com/rdf/myphotos" xmlns:r="http://www.xulplanet.com/rdf/"> <template> <rule r:country="http://www.daml.org/2001/09/countries/iso#it"> <vbox class="box-padded" uri="rdf:*"> <image src="rdf:*"/> <label value="rdf:http://purl.org/dc/elements/1.1/title"/> </vbox> </rule> </template> </hbox> this example shows how a single attribute may be used to filter for only those results that have a country set to 'http://www.daml.org/2001/09/countries/iso#it'. photos that do not have this country will not have any con...
Using Multiple Queries to Generate More Results - Archive of obsolete content
bject="?item" predicate="http://purl.org/dc/elements/1.1/title" object="?title"/> <action> <label uri="?item" value="?title"/> </action> </rule> </queryset> </template> you can view the example. multiple queries with xml sources you can also use more than query when using an xml source. here is an example which generates two sets of results and shows them together. ...
...ows them together. ...
XML Assignments - Archive of obsolete content
r in the query, as the query must return dom nodes as results. in this case, we use an expression that returns the nodes as in earlier examples, and use some additional syntax of the query to get the length of the names. to do this, we use an additional element, the assign element. this element allows the use of additional xpath expressions to get more data from the xml data. ...
...it allows us to declare additional variables that may be used in the action body. the expr attribute specifies the xpath expression and the var attribute specifies the variable to assign to. note that while the query expression uses the root node (or reference node) as the xpath context, the expressions for the assign element ar...
Box Model Details - Archive of obsolete content
mple will work with a vertical box as well, although the second button will be underneath the first one, instead of beside it. ...
...t. a find text dialog example 5 : source view <?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <window id="findtext" title="find text" orient="horizontal" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> <vbox flex="3"> <label control="t1" value="search text:"/> <textbox id="t1" style="min-width: 100px;" flex="1"/> </vbox> <vbox style="min-width: 150px;" flex="1" align="start"> <checkbox id="c1" label="ignore case"/> <spacer flex="1" style="max-height: 30px;"/> <button label="find"/> </vbox> </window> here, two vertical boxes are created, one for the textbox and the other for the check box and button. the left box has a flexiblity that is 3 times greater than the right one so it will alway...
Keyboard Shortcuts - Archive of obsolete content
close command when the user presses esc. ...
...of course, the clipboard commands don't do anything anyway, as we haven't written those scripts. key events there are three keyboard events that may be used if the key related features described above aren't suitable. these events are: keypress called when a key is pressed and released when an element has the focus. you...
Localization - Archive of obsolete content
"&pastecmd.label;" accesskey="&pastecmd.accesskey;" disabled="true"/> </menupopup> </popupset> <keyset> <key id="cut_cmd" modifiers="accel" key="&cutcmd.commandkey;"/> <key id="copy_cmd" modifiers="accel" key="&copycmd.commandkey;"/> <key id="paste_cmd" modifiers="accel" key="&pastecmd.commandkey;"/> <key id="close_cmd" keycode="vk_escape" oncommand="window.close();"/> </keyset> <vbox flex="1"> <toolbox> <menubar id="findfiles-menubar"> <menu id="file-menu" label="&filemenu.label;" accesskey="&filemenu.accesskey;"> <menupopup id="file-popup"> <menuitem label="&opencmd.label;" accesskey="&opencmd.accesskey;"/> <menuitem label="&savecmd.label;" accesskey="&savecmd.accesskey;"/> <menuseparator/> ...
...a dtd file has been included near the beginning of the xul file. each entity that was added should be declared in the dtd file. the window will not be displayed if an entity is found in the xul file that hasn't been declared. note that the name of the entity is not important. in the example above, words in entities have b...
Modifying a XUL Interface - Archive of obsolete content
unction addbutton(){ var abox = document.getelementbyid("abox"); var button = document.createelement("button"); button.setattribute("label","a new button"); abox.appendchild(button); } </script> <box id="abox" width="200"> <button label="add" oncommand="addbutton();"/> </box> this example has two parts a box container element in xul. notice that this is not the same as a vbox or an hbox. (this is discussed more in the box model pages.) the box element has two attributes "id" and "width". the box element contains a button element. the button element has two attributes "label" and "oncommand" a javascript function named "addbutton()" this script fir...
...hat the copy won't have any children. if true, all of the children are copied as well. this is done recursively, so for large tree structures make sure that this is desired before passing true to the clonenode() function. here is an example: example 2 : source view <hbox height="400"> <button label="copy" oncommand="this.parentnode.appendchild(this.nextsibling.clonenode(true));"/> <vbox> <button label="first"/> <button label="second"/> </vbox> </hbox> when the copy button is pressed.. we retrieve the nextsibling of the button, which will be the vbox element. a copy of this element is made using the clonenode() function and the copy is appended using appendchild(). note that some elements, such as listbox and menulist provide some additional specialized modif...
More Event Handlers - Archive of obsolete content
the event object has a number of properties which can be examined during an event. for a full list, see the reference. we already saw the event's target property in the last section. it holds a reference to the element where the event occurred. a similar property currenttarget holds the element that is currently having its event listeners handled. ...
...y saw the event's target property in the last section. it holds a reference to the element where the event occurred. a similar property currenttarget holds the element that is currently having its event listeners handled. in the example below, currenttarget is always the vbox, whereas target would be the specific element, either the button or checkbox, that was activated. example 1 : source view <vbox oncommand="alert(event.currenttarget.tagname);"> <button label="ok"/> <checkbox label="show images"/> </vbox> stop event propagation once you handle an event, regardless of where in the propagation the event is, you will likely want to stop the event from being sent to further elements, essentially stopping the capturing or bubbling phases from continuing. depending on how you attach the e...
Skinning XUL Files by Hand - Archive of obsolete content
archy, but it is not itself hierarchical, as you saw in the global skin. instead, a css file is usually simply a list of style definitions that are applied to their respective elements and classes by the rendering engine. here is a very short (but complete!) cascading stylesheet that might be referenced and used by a xul file: toolbar.nav-bar { background-image: url("chrome://navigator/skin/navbar-bg.gif"); padding: 0px; padding-bottom: 2px; } box#navbar { background-color: lightblue; } a:link { color: #fa8072; } this stylesheet exhibits three of the different types of style definitions described above. each type uses a different grouping of elements. in the first definition, the selector "toolbar.nav-bar" is used to define style information for all xul toolbars of the class ...
... label="click me" /> <toolbarbutton label="don't click me" /> ... </toolbar> will be styled with the css rules that appear in the block after the toolbar.nav-bar selector in the css example above. similarly, the next item uses the id selector to apply style information to a single xul element. since id attribute must be unique in a document, there can only be a single element with the id "navbar", and it will pick up the style information in the block. the third type of selector, thepseudo-class, is one you may have seen in the in-line style definitions for hyperlinks which commonly appear in html documents. the pseudo-class is connected to an element (or not: you can also define styles that apply to any element in the state specified by a pseudo-class) with the ":" character. in this...
XUL Reference - Archive of obsolete content
/gecko 1.9) tabbox tabpanel tabpanels tabs template textnode textbox textbox (firefox autocomplete) textbox (mozilla autocomplete) timepicker titlebar toolbar toolbarbutton toolbargrippy toolbaritem toolbarpalette toolbarseparator toolbarset toolbarspacer toolbarspring toolbox tooltip tree treecell treechildren treecol treecols treeitem treerow treeseparator triple vbox where window wizard wizardpage categorical list of all xul elements « xul reference « windows window wizard wizardpage titlebar window structure --- menus and popups --- toolbars toolbar toolbarbutton toolbargrippy toolbaritem toolbarpallete toolbarseperator toolbarspring tabs and grouping tab tabbox tabpanel tabpanels tabs controls ...
... checkbox colorpicker datepicker menulist progressmeter radio radiogroup scale splitter textbox textbox (firefox autocomplete) textbox (mozilla autocomplete) timepicker description label image listbox listitem listcell listcol listcols listhead listheader richlistbox richlistitem tree treecell treechildren treecol treecols treeitem treerow treeseparator box hbox vbox bbox deck stack grid columns column rows row scrollbox action assign binding bindings conditions content member param query queryset rule template textnode triple where script commandset command broadcaster broadcasterset observes key keyset stringbundle stringbundleset arrowscrollbox dropmarker grippy scrollbar scrollcorner spinbuttons all attributes a...
XUL Template Primer - Bindings - Archive of obsolete content
t be matched, the rule will still fire. example to illustrate how <bindings> work, we'll examine this xul document, which builds a simple content model an rdf/xml file. ...
... we'll use a the following data model to illustrate how bindings work. see the rdf/xml file friends.rdf, below, a simple database with name and address information for some of my good friends. <?xml version="1.0"?> <rdf:rdf xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"...
panel - Archive of obsolete content
Archive › Mozilla › XUL › panel
torefocus, onpopuphidden, onpopuphiding, onpopupshowing, onpopupshown, position, titlebar, top, type properties accessibletype, label, popupboxobject, popup, state methods hidepopup, moveto, openpopup, openpopupatscreen, sizeto examples the following example shows how a panel may be attached to a label. ...
...e methods hidepopup, moveto, openpopup, openpopupatscreen, sizeto examples the following example shows how a panel may be attached to a label. <panel id="thepanel"> <hbox align="start"> <image src="warning.png"/> <vbox> <description value="you have 6 new messages."/> <hbox> <button label="read mail"/> <button label="new message"/> </hbox> </vbox> </hbox> </panel> <description value="6 new messages" popup="thepanel"/> attributes backdrag type: boolean setting the backdrag attribute on a xul panel lets the user move the panel by clicking and dragging anywhere on its background area. close type: boolean if the panel has a titlebar, set the panel's close attribute to true to have a close button appear o...
textbox - Archive of obsolete content
decimalplaces type: integer the number of decimal places to display. the default is 0, which doesn't show any decimal places. the value infinity may be used if you want no limit on ...
...utfield, label, max, maxlength, min, placeholder, readonly, searchbutton, selectionend, selectionstart, size, spinbuttons, tabindex, textlength, timeout, type, value, valuenumber, wraparound methods decrease, increase, reset, select, setselectionrange style classes plain examples <vbox> <label control="your-name" value="enter your name:"/> <textbox id="your-name" value="john"/> </vbox> attributes cols type: integer for multiline textboxes, the number of columns to display. decimalplaces type: integer the number of decimal places to display. the default is 0, which doesn't show any decimal places. the value infinity may be used if you want no limit on the number of decimal places. note that decimal numbers are stored as floats. disabled type: boole...
tooltip - Archive of obsolete content
an ellipsis will be used in place of the cropped text. if the box direction is rev...
...an ellipsis will be used in place of the cropped text. if the box direction is reversed, the cropping is reversed. start the text will be cropped on it...
Extentsions FAQ - Archive of obsolete content
there are workarounds to this restriction by messing around with overflow or negative margins but i forgot offhand how to do that. how to create a dynamic drop down menu that may have submenus using javascript for an extension? these ...
...there are workarounds to this restriction by messing around with overflow or negative margins but i forgot offhand how to do that. how to create a dynamic drop down menu that may have submenus using javascript for an extension? these two links should give you a starting point: ...
Browser Detection and Cross Browser Support - Archive of obsolete content
<li><a href="choice1.html">choice1</a></li> <li><a href="choice2.html">choice2</a></li> </ul> </noscript> </body> </html> using script language to choose the browser where it will be executed the choice of scripting language is determined by the language attribute of the script tag. internet explorer 4 and above can support a variety of script languages. the most common are vbscript and javascript. internet explorer also uses jscript as a synonym for javascript. since other browsers do not support the language attribute vbscript or jscript you can use these languages when you wish certain scripts to only be executed by internet explorer 4 and above. <html> <head> <title>script languages</title> </head> <body> <script language="javascript"> // javas...
...> <title>script languages</title> </head> <body> <script language="javascript"> // javascript code to implement fancy menu // visible to all javascript capable browsers </script> <script language="jscript"> // javascript code that uses proprietary // internet explorer features not available in // other browsers. </script> <script language="vbscript"> // vbscript code that uses proprietary // internet explorer features not available in // other browsers. </script> </body> </html> using netscape navigator 4's css limitations it is possible to use netscape navigator 4's limitations for css support to automatically exclude certain css rules from ever being seen by navigator 4. for example, navigator 4 does not ...
Displaying Places information using views
nternal instance of nsinavhistoryresultobserver, you would pass it instead. (the three built-in views take this approach.) the results object then communicates to your view via this instance, notifying it about changes in the underlying data so it can update its display. var bmserv = components.classes["@mozilla.org/browser/nav-bookmarks-service;1"]. getservice(components.interfaces.nsinavbookmarksservice); var histserv = components.classes["@mozilla.org/browser/nav-history-service;1"]. getservice(components.interfaces.nsinavhistoryservice); var opts = histserv.getnewqueryoptions(); var query = histserv.getnewquery(); query.setfolders([bmserv.placesroot], 1); var result = histserv.executequery(query, opts); // here myview is your view, and myview.viewer is some object implemen...
...{ switch (acol.id || acol.element.getattribute("anonid")) { case "fulluri": case "indexinparent": case "parity": // you might resort by column here. break; default: this._cycleheader(acol); break; } }; // execute a query and gets its result. var bmserv = components.classes["@mozilla.org/browser/nav-bookmarks-service;1"]. getservice(components.interfaces.nsinavbookmarksservice); var histserv = components.classes["@mozilla.org/browser/nav-history-service;1"]. getservice(components.interfaces.nsinavhistoryservice); var opts = histserv.getnewqueryoptions(); var query = histserv.getnewquery(); query.setfolders([bmserv.placesroot], 1); var result = histserv.executequery(query, opts); // hook up the result's viewer and the tree's nsitreeview to our custom...
PRSockOption
enumeration type used in the option field of prsocketoptiondata to form the name portion of a name-value pair. syntax #include <prio.h> typedef enum prsockoption { pr_sockopt_nonblocking, pr_sockopt_linger, pr_sockopt_reuseaddr, pr_sockopt_keepalive, pr_sockopt_recvbuffersize, pr_sockopt_sendbuffersize, pr_sockopt_iptimetolive, pr_sockopt_iptypeofservice, pr_sockopt_addmember, pr_sockopt_dropmember, pr_sockopt_mcastinterface, pr_sockopt_mcasttimetolive, pr_sockopt_mcastloopback, pr_sockopt_nodelay, pr_sockopt_maxsegment, pr_sockopt_last } prsockoption; enumerators the enumeration has the following enumerators: pr_sockopt_nonblocking nonblocking i/o. pr_sockopt_linger time to linger on close if data is present in the socket send buffer. pr_sockopt...
...ay, pr_sockopt_maxsegment, pr_sockopt_last } prsockoption; enumerators the enumeration has the following enumerators: pr_sockopt_nonblocking nonblocking i/o. pr_sockopt_linger time to linger on close if data is present in the socket send buffer. pr_sockopt_reuseaddr allow local address reuse. pr_sockopt_keepalive periodically test whether connection is still alive. pr_sockopt_recvbuffersize receive buffer size. pr_sockopt_sendbuffersize send buffer size. pr_sockopt_iptimetolive ip time-to-live. pr_sockopt_iptypeofservice ip type-of-service and precedence. pr_sockopt_addmember join an ip multicast group. pr_sockopt_dropmember leave an ip multicast group. pr_sockopt_mcastinterface ip multicast interface address. pr_sockopt_mcasttimetolive ip multicast time-to-l...
Places utilities for JavaScript
: "text/x-moz-url", type_html: "text/html", type_unicode: "text/unicode", services there's easy access to some of the common services used in bookmarks or history navigation here. ...
...sses["@mozilla.org/browser/nav-bookmarks-service;1"] .getservice(components.interfaces.nsinavbookmarksservice); with places utils all you need to write is: placesutils.bookmarks this should save on the number of references to the service that are needed, and can help clean up interfaces that are already fairly cluttered. there are currently 11 services defined in here. ...
Using the Places livemark service
ing into an nsiuri using nsiioservice. when creating livemarks during startup, you should use the nsilivemarkservice.createlivemarkfolderonly() to avoid http traffic. this creates the encapsulating livemark without actually fetching the rss feed's contents. var bmsvc = components.classes["@mozilla.org/browser/nav-bookmarks-service;1"]. ...
... determine whether a folder is a livemark you can use the nsilivemarkservice.islivemark() method to determine whether or not a given folder is a livemark container: if (livemarkservice.islivemark(folderid)) { // it's a livemark } else { // it's not a livemark } accessing the container's site uri the nsilivemarkservice.getsiteuri() method let...
Index
Mozilla › Tech › XPCOM › Index
message windows, xpcom api reference, xpcom interface reference, thunderbird the javascript implementation of this used by thunderbird is given here. 787 nsimutablearray interfaces, interfaces:scriptable, xpcom, xpcom api reference, xpcom interface reference consumers of nsiarray should not queryinterface to nsimutablearray unless they own the array. ...
...iarray should not queryinterface to nsimutablearray unless they own the array. 788 nsinavbookmarkobserver developing mozilla, extensions, interfaces, interfaces:scriptable, places, xpcom, xpcom api reference, xpcom interface reference this method notifies this observer that an item is about to be removed. it is called before the actual removal takes place. 789 nsinavbookmarksservice developing mozilla, interfaces, interfaces:scriptable, places, xpcom, xpcom api reference, xpcom interface reference implemented by: @mozilla.org/browser/nav-bookmarks-service;1. to use this service, use: 790 nsinavhistorybatchcallback interfaces, interfaces:scriptable, needscontent, xpcom interface reference no summary! 791 nsinavhistoryco...
nsISyncJPAKE
services/crypto/component/nsisyncjpake.idlscriptable please add a summary to this article. ...
... in acstring agv4, in acstring ar4, out acstring aa, out acstring agva, out acstring ara); methods final() perform the final step of the jpake exchange. this will compute the key and expand the key to two keys, an aes256 encryption key and a 256 bit hmac key. it returns a key confirmation value (sha256d of the key) and the encryption and hmac keys. void final( in acstring ab, in acstring agvb, in acstring arb, in acstring ahkdfinfo, out acstring aaes256key, out acstring ahmac256key ); parameters ab schnorr signature value b, in hex representation. agvb schnorr signature value g^vb (vb is a random value), in hex representation. arb schnorr signature value rb = vb - xb * h, in hex representation. ahkdfinfo missing description aaes256key the aes 256 encryption key, in base64 re...
WebGLRenderingContext.vertexAttribPointer() - Web APIs
tribute is defined as a integer in the vertex shader (e.g. uvec4 or ivec4, instead of vec4). description let's assume we want to render some 3d geometry, and for that we will need to supply our vertices to the vertex shader. each vertex has a few attributes, like position, normal vector, or texture coordinate, that are defined in an arraybuffer and will be supplied to the vertex buffer object (vbo). first, we need to bind the webglbuffer we want to use to gl.array_buffer, then, with this method, gl.vertexattribpointer(), we specify in what order the attributes are stored, and what data type they are in. in addition, we need to include the stride, which is the total byte length of all attributes for one vertex. also, we have to call gl.enablevertexattribarray() to tell webgl that this attr...
...d[1] * 0xffff, true); } for higher performance, we could also do the previous json to arraybuffer conversion on the server-side, e.g. with node.js. then we could load the binary file and interpret it as an array buffer: const response = await fetch('assets/geometry.bin'); const buffer = await response.arraybuffer(); consume array buffer with webgl first, we create a new vertex buffer object (vbo) and supply it with our array buffer: //bind array buffer to a vertex buffer object const vbo = gl.createbuffer(); gl.bindbuffer(gl.array_buffer, vbo); gl.bufferdata(gl.array_buffer, buffer, gl.static_draw); then, we specify the memory layout of the array buffer, either by setting the index ourselves: //describe the layout of the buffer: //1. position, not normalized gl.vertexattribpointer(0...
CSS values and units - CSS: Cascading Style Sheets
glyph in the element’s font, as represented by the “水” (cjk water ideograph, u+6c34) glyph. rem font size of the root element. lh line height of the element. rlh line height of the root element. vw 1% of viewport's width. vh 1% of viewport's height. vi 1% of viewport's size in the root element's inline axis. vb 1% of viewport's size in the root element's block axis. vmin 1% of viewport's smaller dimension. vmax 1% of viewport's larger dimension. absolute length units are fixed to a physical length: either an inch or a centimeter. many of these units are therefore more useful when the output is a fixed size media, such as print. for example, mm is a physical millimeter, ...
...min(), max() and clamp() functions.) some legacy functional notations such as rgba() use commas, but generally commas are only used to separate items in a list. if a comma is used to separate arguments, white space is optional before and after the comma. specifications specification status comment css values and units module level 4 editor's draft adds the vi, vb, ic, cap, lh and rlh units. adds the min(), max() and clamp() functional notation adds toggle() css values and units module level 3 candidate recommendation adds calc(), ch, rem, vw, vw, vmin, vmax, q css color module level 4 working draft adds commaless syntaxes for the rgb(), rgba(), hsl(), and hsla() functions. allows alpha values in rgb() and hsl(), turni...
<length> - CSS: Cascading Style Sheets
Web › CSS › length
to the size of the viewport, i.e., the visible portion of the document. viewport lengths are invalid in @page declaration blocks. vh equal to 1% of the height of the viewport's initial containing block. vw equal to 1% of the width of the viewport's initial containing block. vi equal to 1% of the size of the initial containing block, in the direction of the root element’s inline axis. vb equal to 1% of the size of the initial containing block, in the direction of the root element’s block axis. vmin equal to the smaller of vw and vh. vmax equal to the larger of vw and vh. absolute length units absolute length units represent a physical measurement when the physical properties of the output medium are known, such as for print layout. this is done by anchoring one of the...
...result'; result.style.width = inputelem.value; result.innerhtml = `<code>width: ${inputelem.value}</code>`; resultsdiv.appendchild(result); inputelem.value = ''; inputelem.focus(); }) result specifications specification status comment css values and units module level 4the definition of '<length>' in that specification. editor's draft adds the vi, vb, ic, lh, and rlh units. css values and units module level 3the definition of '<length>' in that specification. candidate recommendation adds the ch, rem, vw, vh, vmin, vmax, and q units. css level 2 (revision 1)the definition of '<length>' in that specification. recommendation explicit definition of the em, pt, pc, and px units. css level 1the definition of ...
Boxes - Archive of obsolete content
however, you can easily add this capability with a style change. ...
Dialogs and Prompts - Archive of obsolete content
s oncommand is executed only when the button is pressed, and ondialog* handlers are executed for keyboard and other events too. example: <?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <dialog xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" ondialogaccept="alert('ok!');"> <hbox> <label value="hey!"/> <spacer flex="1"/> <vbox> <button dlgtype="accept"/> <button dlgtype="cancel"/> </vbox> </hbox> </dialog> default button since firefox 1.5, there are defaultbutton attributes and properties on the <dialog> element bug 284776. the possible values for the attribute are the names of buttons listed above, and the default is "accept", for compatibility with previous versions. using <dialogheader> you can use t...
Embedding SVG - Archive of obsolete content
ttp://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <!-- xul and svg go here --> </window> example: <?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" xmlns:svg="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <vbox> <label value="hello"/> <svg:svg version="1.1" baseprofile="full" width="150" height="150"> <svg:rect x="10" y="10" width="100" height="100" fill="red"/> <svg:circle cx="50" cy="50" r="30" fill="blue"/> </svg:svg> <label value="world"/> </vbox> </window> ...
QuerySelector - Archive of obsolete content
); alert(foo.$('bar').nodename); // gives 'bar' element.prototype.$ = function (selector) { // works for html, xul, and plain xml return this.queryselector(selector); }; html example: <h1><a>test!<a/></h1> <script> element.prototype.$ = function (selector) { return this.queryselector(selector); }; alert(document.getelementsbytagname('h1')[0].$('a').nodename); // 'a' xul example: <hbox><vbox/></hbox> <script type="text/javascript"><![cdata[ element.prototype.$ = function (selector) { return this.queryselector(selector); }; var xulns = 'http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul'; alert(document.getelementsbytagnamens(xulns, 'hbox')[0].$('vbox').nodename); // vbox ]]></script> xml example: <foo xmlns="somens"><bar/></foo> in document earlier var foo = documen...
Toolbar - Archive of obsolete content
lem && elem.parentnode == toolbar) before = elem.nextelementsibling; } toolbar.insertitem(id, before); toolbar.setattribute("currentset", toolbar.currentset); document.persist(toolbar.id, "currentset"); if (toolbarid == "addon-bar") toolbar.collapsed = false; } } if (firstrun) { installbutton("nav-bar", "my-extension-navbar-button"); // the "addon-bar" is available since firefox 4 installbutton("addon-bar", "my-extension-addon-bar-button"); } ...
How to convert an overlay extension to restartless - Archive of obsolete content
l ui construction function. step 6a. details on adding elements dynamically to chrome xul window there is a way that makes constructing of ui a lot similar to the way it was made with xul overlay. it involves using firebug.sdk. ...
Inline options - Archive of obsolete content
yntax appears in the extension's detail view in the add-on manager. this functionality originally appeared in firefox mobile and is now available in firefox on the desktop as well. options file the xul allowed for the inline options is limited to a few new tags. here is an example of an options.xul file: <?xml version="1.0"?> <!doctype mydialog system "chrome://myaddon/locale/mydialog.dtd"> <vbox xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> <setting type="bool" pref="extensions.myaddon.bool" title="boolean" desc="stored as a boolean preference" /> </vbox> note that it's limited to <setting> tags. the root <vbox> just acts as a container, it isn't merged into the main window. if you need script support, see the display notifications section. setting types ...
Adding sidebars - Archive of obsolete content
ex="2"> <hbox> <!-- content for the first child. --> </hbox> <hbox> <!-- content for the second child. --> </hbox> </deck> note how this is one of the few cases where an attribute of an element is named using camel case instead of all small caps. the size of the deck depends on the size of the largest child node, just like in a tabbox. we recommend that you use hbox or vbox elements as children of a deck or stack. the code is easier to read and maintain this way. a deck can be very useful when you have a large piece of xul code that only changes in a small way depending on different circumstances. for instance, you could have a window that is used for two different purposes, and the only difference between the two cases is a label that has a value in one case a...
Adding preferences to an extension - Archive of obsolete content
er2.symbol" preference. this lets the preference value automatically be updated to reflect the content of the textbox. alternative method: inline options requires gecko 7(firefox 7 / thunderbird 7 / seamonkey 2.4) you could use inline options for this preference. you must set em:optionstype to 2 in your install.rdf. your options.xul file would look like this: <?xml version="1.0" ?> <vbox xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> <setting pref="extensions.stockwatcher2.symbol" type="string" title="stock to watch" /> </vbox> adding the context menu adding the contextual menu is easy; all the work that needs doing is done in the stockwatcher2.xul file. the first step is to add the context attribute to the status bar panel: <statusbar id="status-...
Space Manager Detailed Design - Archive of obsolete content
frameinfo* getframeinfofor(nsiframe* aframe); frameinfo* createframeinfo(nsiframe* aframe, const nsrect& arect); void destroyframeinfo(frameinfo*); void clearframeinfo(); void clearbandrects(); bandrect* getnextband(const bandrect* abandrect) const; void divideband(bandrect* aband, nscoord abottom); prbool canjoinbands(bandrect* aband, bandrect* aprevband); prbool joinbands(bandrect* aband, bandrect* aprevband); void addrecttoband(bandrect* aband, bandrect* abandrect); void insertbandrect(bandrect* abandrect); nsresult getbandavailablespace(const bandrect* aband, nscoord ay, const nssize& amaxsize, nsband...
width - Archive of obsolete content
he inner hbox will be displayed at 40 pixels. the displayed width is also 40 pixels as no flexibility or alignment applies. <hbox> <hbox width="40" style="background-color: red;"> <label value="40"/> </hbox> </hbox> however, in the following example, despite that the preferred width of the box is 30 pixels, the displayed size of the box will be larger to accommodate the larger label. <vbox width="30" align="start" style="background-color: red;"> <label value="vbox xul width 10px red"/> </vbox> note: when used on treecol objects, the width attribute can be used to allow a tree to be scrolled horizontally if the column widths add up to be wider than the containing object. ...
List of commands - Archive of obsolete content
also obtained from http://www.mozilla.org/unix/customizing.html ...
ContextMenus - Archive of obsolete content
o the menupopup by id. this may be useful, for example, when a context menu is associated with only 1 element. it is also useful in xbl bindings, as you wouldn't want to refer to a popup by id in this case. if the context attribute is set to the value '_child', the context menu is found by examining the children of the element instead of looking for a menupopup with the given id. for example: <vbox context="_child"> <label value="hello"/> <menupopup> <menuitem label="cut"/> <menuitem label="copy"/> <menuitem label="paste"/> </menupopup> </vbox> in this sample, the context menu is found as the child of the vbox, because the context attribute is set to '_child'. note that this special value must begin with an underscore to distinguish it from an id of 'child'. the menupo...
Additional Navigation - Archive of obsolete content
://www.xulplanet.com/ndeakin/images/t/palace.jpg) (?start = http://www.daml.org/2001/09/countries/iso#it, ?countrytitle = italy, ?photo = http://www.xulplanet.com/ndeakin/images/t/obselisk.jpg) the third triple just grabs the title from the photo as previous examples did, adding a value for the ?title variable for each photo. we can then display these results using the following action body. <vbox uri="?photo" class="box-padded"> <image src="?photo"/> <label value="?title"/> <label value="country: ?countrytitle"/> </vbox> a label for the country will be displayed as well. naturally, it will have the same value for every photo. some padding has been added around each photo using the 'box-padded' class. here is the example. by carefully defining the rdf graph and using the right ...
Multiple Rules - Archive of obsolete content
eater than 1000 differently beforematch if a value comes before another alphabetically aftermatch if a value comes after another alphabetically startswithmatch if a value starts with a specific string endswithmatch if a value ends with a specific string containsmatch if a value contains a substringto highlight results that contain a search term here is an example using the 'contains' operator: <vbox datasources="people.xml" ref="*" querytype="xml"> <template> <query expr="person"> <assign var="?letters" expr="string-length(@name) - 1"/> </query> <rule> <where subject="?name" rel="contains" value=" "/> <action> <label uri="?" value="?name has two names for a total length of ?letters"/> </action> </rule> </template> </vbox> this example co...
Result Generation - Archive of obsolete content
emplate. in the image, the resource uri's are the blue labels of each node. there are no literals in this example, but we'll see some later. let's say we want the starting point to be a from the above example graph. we will use a's uri (http://www.xulplanet.com/rdf/a) as the reference starting point. in a xul template, you specify the starting point using the 'ref' attribute. here is an example: <vbox datasources="http://www.xulplanet.com/ds/sample.rdf" ref="http://www.xulplanet.com/rdf/a" flex="1"> this is an indicator that we want to construct a xul template using the reference point with the uri 'http://www.xulplanet.com/rdf/a'. query processing a query for an rdf datasource consists of a number of statements, placed as children of the query element. during query processing, the...
SQLite Templates - Archive of obsolete content
l value '?name'. the syntax with the question mark is similar as with the other query types. it means, substitute the attribute value with the value of a column from the result. in this case, '?name' means replace this with the value of the name column. the effect is a listbox containing the names from the database. you can return multiple columns or filtered data by using a more complex query. <vbox datasources="profile:userdata.sqlite" ref="*" querytype="storage"> <template> <query> select name, email from myfriends where age >= 30 </query> <action> <hbox uri="?"> <label value="?name"/> <label value="?email"/> </hbox> </action> </template> </vbox> this template displays the results of two columns. any occurance of a question mark in t...
Sorting Results - Archive of obsolete content
the rdf datasource changes, and a new result is available, the new content is inserted at the right location. for rdf datasources, you can also use an rdf predicate for sorting instead of a variable: <hbox datasources="template-guide-photos5.rdf" sort="http://purl.org/dc/elements/1.1/title" sortdirection="ascending" ref="http://www.xulplanet.com/rdf/myphotos"> <template> <vbox class="box-padded" uri="rdf:*"> <image src="rdf:*"/> <label value="rdf:http://purl.org/dc/elements/1.1/title"/> </vbox> </template> </hbox> in this example, the generated items will be sorted by title. when sorting, the predicate specified in the sort attribute for the result is used to determine where in the content the generated output should be inserted. the is similar to ...
Template Builder Interface - Archive of obsolete content
e causes the new datasource to be retrieved and the template to be rebuilt. the rdf datasource associated with the template can be retrieved using the element's 'database' property. it implements the nsirdfcompositedatasource interface. since this is a composite datasource, it may contain more than one datasource. these may be listed in the datasources attribute separated by spaces. for example: <vbox datasources="template-guide-photos5.rdf template-guide-streets.rdf"> sometimes, you will want to calculate the datasource to be used and attach it to the template later. you can do this using the composite datasource's adddatasource method. you can add as many datasources as you wish, and you can remove them using the removedatasource method. a common pattern is to use the following: var rdf =...
Template Logging - Archive of obsolete content
ways in which template errors may be detected. the first debugging method involves logging all new results that apply to the template due to the data changing as well as logging results that are changed or removed. in addition, each result generated when the template is first created and initialized is logged. this logging of result changes is not done by default; it must be enabled with a flag. <vbox datasources="..." flags="logging"/> the flags attribute on the root element of the template should include the logging flag. if other flags are used as well, separate them with spaces. enabling logging will output details to the error console for each result. the error console can be found on the firefox tools menu. this logging of results can be very useful for debugging, but remember to remo...
XML Templates - Archive of obsolete content
the use of the ?name value, causes the name attribute on each result node to be used as the value of the label. you can see the name attributes in the original xml data above. this substitution occurs for any attribute within the action body, so you can also set other attributes with this technique. in this example, an hbox element containing a button and a label is generated for each result. <vbox datasources="people.xml" ref="*" querytype="xml"> <template> <query expr="person"/> <action> <hbox uri="?" align="center"> <button label="?name"/> <label value="?gender"/> </hbox> </action> </template> </vbox> note how two attributes are substituted here, the label on the button and the value on the label. the query does not have to be as simple as...
Adding Event Handlers - Archive of obsolete content
separate script. an example of responding to a button being pressed: example 1 : source view <button label="ok" oncommand="alert('button was pressed!');"/> since the command event will bubble, it is also possible to place the event listener on an enclosing element. in the example below, the listener has been placed on a box and will receive events for both elements. example 2 : source view <vbox oncommand="alert(event.target.tagname);"> <button label="ok"/> <checkbox label="show images"/> </vbox> in this example, the command event will bubble up from the button or checkbox to the vbox, where it is handled. if a second listener (the oncommand attribute) were placed on the button, its code will be called first, followed by the handler on the vbox. event handlers are passed the even...
Anonymous Content - Archive of obsolete content
n elements and have certain elements be placed in one location and other elements placed in another. by adding a includes attribute and setting it to a vertical bar-separated list of tags, you can make only elements in that list be placed at that location. for example, the following xbl will cause text labels and buttons to appear in a different location than other elements: source <binding id="navbox"> <content> <xul:vbox> <xul:label value="labels and buttons"/> <children includes="label|button"/> </xul:vbox> <xul:vbox> <xul:label value="other elements"/> <children/> </xul:vbox> </content> </binding> the first children element only grabs the label and button elements, as indicated by its includes attribute. the second children element, because it...
Creating a Skin - Archive of obsolete content
atch the background. the first rule above (for 'window > box') specifies that the child box of the window has a different color. this probably isn't the best way to do this. we should really change this to use a style class. let's do this. that way, we can modify the xul without needing to keep the box as the first child of the window. css: .findfilesbox { background-color: #0088cc; } xul: <vbox class="findfilesbox" orient="vertical" flex="100%"> <toolbox> rounding on the tabs next, let's modify the tabs. we will make the selected tab bold and change the rounding on the tabs. tab:first-child { -moz-border-radius: 4px 0px 0px 0px; } tab:last-child { -moz-border-radius: 0px 4px 0px 0px; } tab[selected="true"] { color: #000066; font-weight: bold; text-decoration: underline...
Popup Menus - Archive of obsolete content
dd a simple popup menu to the find files dialog. for simplicity, we'll just replicate the contents of the edit menu. let's have the popup appear when clicking over the first tab panel: <popupset> <menupopup id="editpopup"> <menuitem label="cut" accesskey="t"/> <menuitem label="copy" accesskey="c"/> <menuitem label="paste" accesskey="p" disabled="true"/> </menupopup> </popupset> <vbox flex="1"> . . . <tabpanel id="searchpanel" orient="vertical" context="editpopup"> here a simple popup that is similar to the edit menu has been added to the first tabpanel. if you right-click (control-click on the macintosh) anywhere on the first panel, the popup will appear. however, the popup will not appear if you click anywhere else. note that the textbox has its own built-in popup menu ...
Tabboxes - Archive of obsolete content
l create an options tab (and select it by default) that will contain some options for searching. this may not be the best interface for doing this, but we'll use it to demonstrate tabs. the label across the top and the search criteria box will need to go on the first tab. we'll add some options on the second tab. the progress bar and the buttons can stay on the main dialog, outside of the tabs. <vbox flex="1"> <tabbox selectedindex="1"> <tabs> <tab label="search"/> <tab label="options"/> </tabs> <tabpanels> <tabpanel id="searchpanel" orient="vertical"> <description> enter your search criteria below and select the find button to begin the search. </description> <spacer style="height: 10px"/> <groupbox orient="horizontal"> <caption label="...
Toolbars - Archive of obsolete content
ctly to the toolbar. for more information about customizable toolbars, see creating toolbar buttons. our find files example let's add a toolbar to the find files dialog. we don't really need one but we'll add one anyway to demonstrate its use. two buttons will be added, an open button and a save button. presumably, they would allow the user to save search results and re-open them later. <vbox flex="1"> <toolbox> <toolbar id="findfiles-toolbar"> <toolbarbutton id="opensearch" label="open"/> <toolbarbutton id="savesearch" label="save"/> </toolbar> </toolbox> <tabbox> a toolbar with two buttons has been added here. in the image, you can see them appear horizontally along the top. notice that the toolbar has been placed inside the vertical box just a...
Accessibility/XUL Accessibility Reference - Archive of obsolete content
ldren see tree treecol see tree treecols see tree treeitem see tree treerow see tree elements that do not expose anything to screen readers/have no discovered accessibility issues yet: arrowscrollbox bbox box grippy hbox menuseparator overlay page script spacer splitter stringbundle stringbundleset vbox window elements not processed yet: action binding bindings broadcaster broadcasterset conditions content dialog dialogheader editor listcell member observes preference preferences prefpane prefwindow resizer richlistbox richlistitem resizer rule scrollbar scrollbox scrollcorner separator template textnode titlebar toolbar toolbarbutton toolbargrippy toolb...
box - Archive of obsolete content
Archive › Mozilla › XUL › box
des(), insertbefore(), isdefaultnamespace(), isequalnode, issamenode, issupported(), lookupnamespaceuri, lookupprefix, normalize(), queryselector(), queryselectorall(), removeattribute(), removeattributenode(), removeattributens(), removechild(), removeeventlistener(), replacechild(), setattribute(), setattributenode(), setattributenodens(), setattributens(), setuserdata related elements vbox, hbox ...
elements - Archive of obsolete content
stringbundle stringbundleset t tab tabbrowser tabbox tabpanel tabpanels tabs template textnode textbox titlebar toolbar toolbarbutton toolbargrippy toolbaritem toolbarpalette toolbarseparator toolbarset toolbarspacer toolbarspring toolbox tooltip tree treecell treechildren treecol treecols treeitem treerow treeseparator triple v vbox w window wizard wizardpage ...
hbox - Archive of obsolete content
Archive › Mozilla › XUL › hbox
, insertbefore(), isdefaultnamespace(), isequalnode, issamenode, issupported(), lookupnamespaceuri, lookupprefix, normalize(), queryselector(), queryselectorall(), removeattribute(), removeattributenode(), removeattributens(), removechild(), removeeventlistener(), replacechild(), setattribute(), setattributenode(), setattributenodens(), setattributens(), setuserdata related elements box, vbox ...
tabpanels - Archive of obsolete content
« xul reference home [ examples | attributes | properties | methods | related ] a container to hold the set of pages in a tabbox. the tabpanels element should be placed in a tabbox although it does not have to be a direct child. the children of the tabpanels element become the panels of the tabbox. in most cases you would use a vbox, but they can be any element, although some people like to use tabpanel elements. by clicking the first tab, the first panel will be displayed. by clicking the second tab, the second panel will be displayed and so on. there should be the same number of panels as there are tabs. panels should never be hidden; hiding the tab suffices to make the panel inaccessible. more information is available in the xul tutorial. attributes selectedindex...
Introduction to Public-Key Cryptography - Archive of obsolete content
:76:79:ba:f8:b4:d2:62:58:c3:c5: b6:c1:43:ac:63:44:42:fd:af:c8:0f:2f:38:85:6d:d6:59:e8:41:42:a5: 4a:e5:26:38:ff:32:78:a1:38:f1:ed:dc:0d:31:d1:b0:6d:67:e9:46:a8: d:c4 here is the same certificate displayed in the 64-byte-encoded form interpreted by software: -----begin certificate----- miickzccazsgawibagibazanbgkqhkig9w0baqqfada3mqswcqydvqqgewjvuzer ma8ga1uechmitmv0c2nhcguxftatbgnvbastdfn1chjpewencybdqtaefw05nzew mtgwmtm2mjvafw05otewmtgwmtm2mjvamegxczajbgnvbaytalvtmrewdwydvqqk ewhozxrzy2fwztenmasga1uecxmeuhviczexmbuga1ueaxmou3vwcml5ysbtagv0 dhkwgz8wdqyjkozihvcnaqefbqadgy0amigjaogbamr6ezipgfjx3urjgejmkiqg 7sdatyazbcabu1avyd7chrkiq31fbxfogd3wnktbf6hro6eamm5/r1askzz8aw7l iqzbcrxpc0k4du+2q6xju2mpm/8wkumontuvzpo+sgxelmhvcheqoocwfdizywyz nmmrjgaoma2ms6pukfqvagmbaagjnja0mbegc...
NSPR Release Engineering Guide - Archive of obsolete content
m bits rename the .vx.y.z directory to vx.y.z (remove the hidden directory 'dot'). copy /share/builds/components/nspr20/vx.y.z/* to /share/systems/mozilla/pub/nspr/vx.y.z/ original document information author: larryh@netscape.com last updated date: september 20, 2000 1 copying files to /share/builds/components requires that one be logged on to a machine named "smithers" as user "svbld". the password to this account is restricted to a small set of designated release engineers. ...
E4X for templating - Archive of obsolete content
{ for (k in arr) { if (it < min) { ++it; continue; } if (it > max) { break; } ret+=h(k, arr[k], it, lev); ++it; } } return ret; } the following real case example iterates over an array of the lines in an e4x child element to produce an xmllist of multiple vbox's representing each line: <vbox> {foreach(e(someel.somechild[0]).split('\n'), function (line) <description>{line}</description> )} </vbox> the following example shows iteration over an e4x object itself: {foreach(elems, function (k, elem, iter) <> <row>{k}: {elem}</row> <row><image src="chrome://myext/skin/images/fillerrow.jpg" /></row> </>)} or if the e4x child element had it...
Date.getVarDate() - Archive of obsolete content
date object. syntax dateobj.getvardate() parameters the required dateobj reference is a date object. return value returns a vt_date value. remarks the getvardate() method is used when javascript code interacts with com objects, activex objects, or other objects that accept and return date values in vt_date format. these include objects in visual basic and visual basic scripting edition (vbscript). the actual format of the returned value depends on regional settings. requirements supported in the following document modes: quirks, internet explorer 6 standards, internet explorer 7 standards, internet explorer 8 standards, internet explorer 9 standards, and internet explorer 10 standards. not supported in windows 8.x store apps. applies to: date object see also date.getdate() ...
Enumerator - Archive of obsolete content
any collection object. remarks collections differ from arrays in that the members of a collection are not directly accessible. instead of using indexes, as you would with arrays, you can move the current item pointer only to the first or next element of a collection. the enumerator object provides a way to access any member of a collection and behaves similarly to the for...each statement in vbscript. example the following code shows the usage of the enumerator object: var bytespergb = 1024 * 1024 * 1024; var fso = new activexobject("scripting.filesystemobject"); document.write(fso.drives); var e = new enumerator(fso.drives); var drivestring = ""; e.movefirst(); while (e.atend() == false) { var drv = e.item(); drivestring += drv.path + " - "; if (drv.isready){ ...
Microsoft JavaScript extensions - Archive of obsolete content
warning: these apis will only work in microsoft applications, and are not on a standards track. ...
Gecko FAQ - Gecko Redirect 1
lopers worldwide. are gecko's apis based on activex? com? javabeans? gecko is reusable on all platforms thanks to xpcom, a subset of com that works across platforms. com, developed by digital and later adopted by microsoft, is the de facto standard for modular interfaces on windows platforms. additionally, on the windows platform, gecko's xpcom interfaces are wrapped in an activex control that vb developers can utilize (activex wrappers are not available on other platforms because activex is a windows-only technology). a javabean wrapper is not currently under development, but there is nothing in gecko's architecture that precludes such development in the future. source code and documentation for these interfaces are available through mozilla.org. for future embedding api plans, see wik...
Mozilla splash page - Learn web development
ill looking ok. tinypng.com is a great service for doing this easily. adding a logo to the header inside the <header> element, add an <img> element that will embed the small version of the firefox logo in the header. adding a video to the main article content just inside the <article> element (right below the opening tag), embed the youtube video found at https://www.youtube.com/watch?v=ojcncvb1olg, using the appropriate youtube tools to generate the code. the video should be 400px wide. adding responsive images to the further info links inside the <div> with the class of further-info you will find four <a> elements — each one linking to an interesting mozilla-related page. to complete this section you'll need to insert an <img> element inside each one containing appropriate src, al...
Handling common JavaScript problems - Learn web development
cross-browser problems, and use appropriate tools and techniques to fix them. the trouble with javascript historically, javascript was plagued with cross-browser compatibility problems — back in the 1990s, the main browser choices back then (internet explorer and netscape) had scripting implemented in different language flavours (netscape had javascript, ie had jscript and also offered vbscript as an option), and while at least javascript and jscript were compatible to some degree (both based on the ecmascript specification), things were often implemented in conflicting, incompatible ways, causing developers many nightmares. such incompatibility problems persisted well into the early 2000s, as old browsers were still being used and still needed supporting. this is one of the main...
Multiprocess on Windows
a library statement is included in the idl) type libraries (also known as typelib). oicf metadata is much richer than typelib metadata, however com requires typelibs whenever it is being used with interpreted languages. in particular, typelibs were originally designed to work with 1990s-era visual basic. typelib metadata is limited to supporting the same language features which were supported by vb at that time. given those two options, it may seem that oicf is the preferred format. however, for various reasons, our com interceptor currently only supports typelib metadata. in order for the interceptor to be able to work with our interfaces, we must do some additional work to compensate for typelib's weaknesses. the required steps are as follows: ensure that you generate typelibs for all...
Creating MozSearch plugins
ch.yahoo.com/, the value of the <searchform> element. example: searching mdc this plugin lets you easily search the mozilla developer center web site. ...
Limitations of frame scripts
<need more examples> services some services will not work in frame scripts. services.search services.downloads chrome windows anything that needs to use chrome windows will not work in the content process. for example: nsisessionstore nsiwindowmediator <need more examples> places api the places api can't be used inside a frame script. for example: nsinavhistoryservice nsinavbookmarksservice observers in the content process as noted in observers in the chrome process, most observers should be registered in the chrome process and will not work in the content process. the exceptions are: content-document-global-created document-element-inserted outer-window-destroyed inner-window-destroyed dom-window-destroyed these must be registered in the content process. ...
Limitations of frame scripts
<need more examples> services some services will not work in frame scripts. services.search services.downloads chrome windows anything that needs to use chrome windows will not work in the content process. for example: nsisessionstore nsiwindowmediator <need more examples> places api the places api can't be used inside a frame script. for example: nsinavhistoryservice nsinavbookmarksservice observers in the content process as noted in observers in the chrome process, most observers should be registered in the chrome process and will not work in the content process. the exceptions are: content-document-global-created document-element-inserted outer-window-destroyed inner-window-destroyed dom-window-destroyed these must be registered in the content process. ...
NSPR release procedure
...
NSS 3.52 release notes
nss 3.52 source distributions are available on ftp.mozilla.org for secure https download: source tarballs: https://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/nss_3_52_rtm/src/ other releases are available in nss releases. notable changes in nss 3.52 bug 1603628 - update nss to support pkcs #11 v3.0. note: this change modifies the ck_gcm_params struct to include the ulivbits field which, prior to pkcs #11 v3.0, was ambiguously defined and not included in the nss definition. if an application is recompiled with nss 3.52+, this field must be initialized to a value corresponding to ulivlen. alternatively, defining nss_pkcs11_2_0_compat will yield the old definition. see the bug for more information. bug 1623374 - support new pkcs #11 v3.0 message interface for ...
NSS Sample Code sample5
jkozihvcnaqebbqadswawsajbal3f6tic3jeysugo+a2fpu3w+epv/feix21dc86wynpftw4srftz2onuzyluzdhzdb+k//8dct3iaozuui3r2emcaweaaq==" #define base64_encoded_privatekeyinfo "miibvqibadanbgkqhkig9w0baqefaascat8wgge7ageaakeavcxpmhzckriy6cj5rz89tdb4sm/8v4hfbumlzpziekw1biysw3pag1tpittmmdl1v6t//x1xpcga7nrsldhz4widaqabakeajh8+4qncwcmgivnm6ytbpqt+k/jeoexg2bqhjojvnxn3fazgcefxvpuibcjvfaijs9ybcmozzrato0+k2hwnoqihaoc4nvbo8fqhzs4yxm1m86kml47fa9ui//oufbhladw1aiea2dbmixnsbokb+ohver69p0gnewlvcjc9bjdvfdlvslcciqcptv3vgyjv2vdwxqzqahc+yb4gigaqoqbcbmjd3lyflqiga+vtydunoqwtzwve4grf7izk2v5ccnhg3gr5rgwxn58cigccaforruksm66isg0iti04g9v/w+wmx91wjeeb+qbz" int main(int argc, char **argv) { secstatus rv; certcertificate *cert = null; seckeypublickey *pubkey = null; certsubjectpublickeyinfo *spki = null; sec...
Secure Development Guidelines
rite("welcome to " + document.location); ... ...
mozIAsyncHistory
i.e. title change and add visit). exceptions thrown ns_error_invalid_arg passing in null for aplaceinfo. not providing at least one valid guid or uri for all moziplaceinfo object[s]. not providing an array or nothing for the visits property of moziplaceinfo. not providing a visitdate and transitiontype for each mozivisitinfo. providing an invalid transitiontype (see nsinavbookmarksservice.constants) for a mozivisitinfo. see also moziplaceinfo mozivisitinfo mozivisitinfocallback ...
mozIVisitInfo
ast changed in gecko 2.0 (firefox 4 / thunderbird 3.3 / seamonkey 2.1) attributes attribute type description referreruri nsiuri read only: the referring uri of this visit. this may be null. sessionid long read only: the sessionid of this visit. transitiontype long read only: the transition type used to get to this visit. one of the nsinavbookmarksservice.constants on nsinavhistory. visitdate prtime read only: the time the visit occurred. visitid long read only: the machine-local (internal) id of the visit. see also moziasynchistory ...
nsIDynamicContainer
the given container is about to be deleted from the bookmarks table, so that the service can do any necessary cleanup. it is called before the container is deleted, so that the service can still reference it. void oncontainerremoving( in long long aitemid ); parameters aitemid the item-id of the container item. see also places nsinavhistorycontainerresultnode nsinavhistoryqueryoptions nsinavbookmarksservice.createdynamiccontainer() ...
nsIFilePicker
filterallowurls 0x80 allow urls. filteraudio 0x100 corresponds to the *.aac, *.aif, *.flac, *.iff, *.m4a, *.m4b, *.mid, *.midi, *.mp3, *.mpa, *.mpc, *.oga, *.ogg, *.ra, *.ram, *.snd, *.wav and *.wma filters for file extensions. filtervideo 0x200 corresponds to the *.avi, *.divx, *.flv, *.m4v, *.mkv, *.mov, *.mp4, *.mpeg, *.mpg, *.ogm, *.ogv, *.ogx, *.rm, *.rmvb, *.smil, *.webm, *.wmv and *.xvid filters for file extensions. methods appendfilter() appends a custom file extension filter to the dialog. the filter appended first will be used to display the nsifilepicker dialog, the user may then select another from the list. void appendfilter( in astring title, in astring filter ); parameters title the title of the filter. filter the f...
nsILivemarkService
sn't a valid nsiuri object (or null) start() this method starts the livemark refresh timer. being able to manually control this allows activity such as bookmarks import to occur without kicking off http traffic. void start(); parameters none. stopupdatelivemarks() stop the livemark refresh timer. void stopupdatelivemarks(); parameters none. see also places livemark service nsinavbookmarksservice ...
Building an Account Manager Extension
load="parent.onpanelloaded('am-devmo-account.xul');"> <script type="application/javascript" src="chrome://messenger/content/accountmanager.js"/> <script type="application/javascript" src="chrome://example@mozilla.org/content/am-devmo-account.js"/> <dialogheader title="devmo example panel"/> <description> this panel is only shown in imap accounts... </description> <vbox flex = "1"/> </page> as with the xul page, the content of the property file relies on a very strict naming. as our account manager extension is named "devmo-account", we are required to include a property named prefpanel-devmo-account. prefpanel-devmo-account=devmo demo panel step4: the new panel and javascript the javascript for an account manager panel needs to implement at least the fo...
nsINavHistoryBatchCallback
inavhistoryservice.idlscriptable please add a summary to this article. 1.0 66 introduced gecko 1.9 inherits from: nsisupports last changed in gecko 1.9 (firefox 3) method overview void runbatched(in nsisupports auserdata); methods runbatched() void runbatched( in nsisupports auserdata ); parameters auserdata see also nsinavhistoryservice.runinbatchmode() nsinavbookmarksservice.runinbatchmode() ...
nsINavHistoryObserver
long aadded ); parameters auri the uri of the page being visited. avisitid id of the visit that was just created. atime time of the visit. asessionid the id of one connected sequence of visits. areferringid the id of the visit the user came from. 0 if empty. atransitiontype the type of the item that is about to be removed; this is one of the nsinavbookmarksservice.constants defined in the nsinavbookmarksservice interface. aguid the unique id associated with the page. aadded incremented by query nodes when the visited uri belongs to them. if no such query exists, the history result creates a new query node dynamically. it is used in places views only and can be ignored. using onbeforedeleteuri() in gecko 1.9.1 if you wish to...
nsINavHistoryQueryOptions
nnotation x"). expandqueries boolean when set, allows items with "place:" uris to appear as containers, with the container's contents filled in from the stored query. if not set, these will appear as normal items. doesn't do anything if excludequeries is set. defaults to false. note that this has no effect on folder links, which are place: uris returned by nsinavbookmarkservice's getfolderuri method. these are always expanded and will appear as bookmark folders. includehidden boolean most items in history are marked "hidden." only toplevel pages that the user sees in the url bar are not hidden. hidden things include the content of iframes and all images on web pages. normally, you don't want these things. if you do, set t...
nsINavHistoryService
de() this method runs the passed callback in batch mode. use this when a lot of things are about to change. calls can be nested, observers will only be notified when all batches begin/end. void runinbatchmode( in nsinavhistorybatchcallback acallback, in nsisupports aclosure ); parameters acallback nsinavhistorybatchcallback interface to call. aclosure opaque parameter passed to nsinavbookmarksbatchcallback. importhistory() this method imports the given mork history file. void importhistory( in nsifile file ); parameters file the mork history file to import. getcharsetforuri() gets the stored character-set for an uri. void getcharsetforuri( in nsiuri auri ); parameters auri uri to retrieve character-set for returns returns the character-set, empty stri...
XPCOM Interface Reference
imsgdbviewcommandupdaternsimsgdatabasensimsgfilternsimsgfiltercustomactionnsimsgfilterlistnsimsgfoldernsimsgheaderparsernsimsgidentitynsimsgincomingservernsimsgmessageservicensimsgprotocolinfonsimsgruleactionnsimsgsearchcustomtermnsimsgsearchnotifynsimsgsearchscopetermnsimsgsearchsessionnsimsgsearchtermnsimsgsearchvaluensimsgsendlaternsimsgthreadnsimsgwindownsimsgwindowcommandsnsimutablearraynsinavbookmarkobservernsinavbookmarksservicensinavhistorybatchcallbacknsinavhistorycontainerresultnodensinavhistoryfullvisitresultnodensinavhistoryobservernsinavhistoryquerynsinavhistoryqueryoptionsnsinavhistoryqueryresultnodensinavhistoryresultnsinavhistoryresultnodensinavhistoryresultobservernsinavhistoryresulttreeviewernsinavhistoryresultviewobservernsinavhistoryresultviewernsinavhistoryservicensinavh...
XPCOM Interface Reference by grouping
nsiappshellservice nsiappstartup xul nsixulappinfo nsixulruntime nsixultemplatebuilder nsixultemplatequeryprocessor nsixultemplateresult bookmark livemark nsilivemarkservice nsinavbookmarkobserver nsinavbookmarksservice nsinavhistoryservice browser dom nsiwebbrowser nsiwebbrowserpersist cache nsicache nsicachedeviceinfo nsicacheentrydescriptor nsicacheentryinfo nsicachelistener nsicachemetadatavisito...
DOM Inspector internals - Firefox Developer Tools
all into the category of host-integration overlays. that's because dom inspector also uses shared overlays to build up its own ui. shared structure overlays taking a look at the contents of inspector.xul, dom inspector's primary ui, will reveal that it contains almost no visible elements. as of this writing, there's a toolbox containing an empty menubar and an empty toolbar, as well as an empty vbox: <toolbox id="tbxinstoolbox"> <menubar id="mbrinspectormain"/> <toolbar id="tbinspectorprimary"/> </toolbox> <vbox id="bxinspectormain" flex="1"/> there are no menus, toolbar items, et cetera defined here. even most of the elements that aren't visible, such as key- and commandsets, are not defined in inspector.xul. these are pulled in from a series of overlays, so that the xul...
CSS Flexbox Inspector: Examine Flexbox layouts - Firefox Developer Tools
click the word flex in the html pane to keep the overlay visible when you move the mouse away from the container. in the infobar when you hover over an element in the html pane, you will see a tooltip that gives you more information about the element. when you hover over a flex container or flex item, the tooltip includes the appropriate information. this header is a flex container: each navbar link is a flex item: the nav element within the header is both a flex item and a flex container which holds the navigation links: in the css pane in the css pane's rules view, any instance of a display: flex declaration gets a small flexbox icon next to the word flex. clicking the icon toggles the display of an overlay on the page, which appears over the selected flex container that ...
CSS numeric factory functions - Web APIs
argument and the unit being the name of the method used. these functions create new numeric values less verbosely than using the cssunitvalue.cssunitvalue() constructor. ...
HTMLCanvasElement.toDataURL() - Web APIs
ntents have or may have been loaded from a site other than the one from which the document itself was loaded. ...
Ajax navigation example - Web APIs
, 508: "loop detected", 509: "unassigned", 510: "not extended", 511: "network authentication required" }; var oreq, bisloading = false, bupdateurl = false; oloadingbox.id = "ajax-loader"; ocover.onclick = abortreq; oloadingimg.src = "data:image/gif;base64,r0lgodlheaaqapiaap///waaamlcwkjcqgaaagjiyokcgpkskih/c05fvfndqvbfmi4waweaaaah/hpdcmvhdgvkihdpdgggywphegxvywquaw5mbwah+qqjcgaaacwaaaaaeaaqaaadmwi63p4wyklre2mioggznadomgyjrbexwroumcg2lmdewnhqlvsyod2mbzkydadka+diaaah+qqjcgaaacwaaaaaeaaqaaadnai63p5ojcegg4qmu7dmikrxqlfuydezigbmrvsaqhwctxxf7weyb4ag1xjihkmzsiukkhiaifkecqoaaaasaaaaabaaeaaaazyiujijk8pbyjdmlfyvbovjha70gu7xsujhmktwhpakzlo9hmaokwjz7rf8aypddzkpzbqfvwqaifkecqoaaaasaaaaabaaeaaaazmiumilk8oyhphsnfzfhyumcyuhdaq...
Navigator.msLaunchUri() - Web APIs
r to allow the service or app to be launched. the user can choose to not see the prompt after the first instance for a particular protocol and automatically open the app or service without a user intervention. the mslaunchuri() method does not support http, secure hypertext transfer protocol (https), file transfer protocol (ftp), file, res, javascript, or microsoft visual basic scripting edition (vbscript) protocols. if the user's system does not have a program registered to handle a specific protocol, and a nohandlercallback is provided, windows internet explorer will invoke the nohandlercallback. this enables developers to provide a custom fallback experience for the user. if a handler doesn't exist, and the developer doesn't provide a nohandlercallback, then internet explorer displays a ...
Writing WebSocket servers - Web APIs
ng a custom chat app that uses a proprietary format exclusive to example inc., then you might use this: sec-websocket-protocol: chat.example.com. note that this isn't required, it's just an optional convention, and you can use any string you wish. related websocket handshake library in c++ writing websocket client applications tutorial: websocket server in c# tutorial: websocket server in vb.net tutorial: websocket server in java ...
Rendering and the WebXR frame animation callback - Web APIs
refreshed. historically, displays have refreshed 60 times per second. this is due to early displays using the ac electrical grid's current flow waveform, which cycles 60 times per second in the united states (50 in europe), for timing purposes. this figure goes by a number of different names, but they're all equivalent or nearly so: refresh rate vertical refresh rate vertical blanking rate (vbl) vertical sync rate vertical refresh rate there are other similar terms used as well, but regardless of what it's called, the unit of measurement applied is the hertz, or hz. a display that refreshes 60 times per second has a 60 hz refresh rate. that means that the maximum number of frames it can display in a second is 60. no matter how many frames per second you render beyond that, only 60 ...
attr() - CSS: Cascading Style Sheets
Web › CSS › attr
<fallback> the value to be used if the associated attribute is missing or contains an invalid value. if not set, css will use the default value defined for each <type-or-unit>. ...
<dimension> - CSS: Cascading Style Sheets
Web › CSS › dimension
ensions 12 px the unit must come immediately after the number. 12"px" units are identifiers and therefore unquoted. 3sec the seconds unit is abbreviated "s" not "sec". specifications specification status comment css values and units module level 4the definition of '<dimension>' in that specification. editor's draft adds cap, ic, lh, rlh, vi, vb css values and units module level 3the definition of '<dimension>' in that specification. candidate recommendation adds ch, rem, vw, vw, vmin, vmax, q css level 2 (revision 1)the definition of '<dimension>' in that specification. recommendation defined under numbers and length css level 1the definition of '<dimension>' in that specification. recommendatio...
url() - CSS: Cascading Style Sheets
Web › CSS › url()
relative url, or a data uri. the url() function can be passed as a parameter of another css functions, like the attr() function. depending on the property for which it is a value, the resource sought can be an image, font, or a stylesheet. the url() functional notation is the value for the <url> data type. ...
Video player styling basics - Developer guides
e, these buttons have different states that need to be styled. as mentioned earlier, a `data-state` variable is used to indicate which state such buttons are currently in. for example, the play/pause button has the following background image definitions (the full base64 strings have been omitted for brevity): .controls button[data-state="play"] { background-image: url('data:image/png;base64,ivborw0kggoaaa ... '); } .controls button[data-state="pause"] { background-image: url('data:image/png;base64,ivborw0kggoaaa ... '); } when the data-state of the button is changed, the appropriate image will also be changed. all the other buttons are treated in a similar way. progress bar the <progress> element has the following basic style set up: .controls progress { display:block; wid...
Digital audio concepts - Web media technologies
pts to keep the bit rate on average at a given level, while allowing some fluctuation, cbr uses an actually fixed bit rate for the duration of the audio. cbr is primarily used in codecs designed for voice-only purposes, where the frequency range and variation tends to be minimal, allowing cbr encoding to work without unworkable fluctuations in audio quality. variable bit rate variable bit rate (vbr) encoding works by accepting as an input into the encoder a constant quality setting. this indicates a quality level to maintain for the duration of the audio, allowing the bit rate to fluctuate as needed to achieve that quality level. in portions of the sound where compression is easily achieved with minimum impact to quality, the bit rate may be very low, while in areas where compression is mo...
Codecs used by WebRTC - Web media technologies
n browsers that don't implement that codec. security implications there are interesting potential security issues that come come up while selecting and configuring codecs. webrtc video is protected using datagram transport layer security (dtls), but it is theoretically possible for a motivated party to infer the amount of change that's occurring from frame to frame when using variable bit rate (vbr) codecs, by monitoring the stream's bit rate and how it changes over time. this could potentially allow a bad actor to infer something about the content of the stream, given the ebb and flow of the bit rate. for more about security considerations when using avc in webrtc, see rfc 6184, section 9: rtp payload format for h.264 video: security considerations. rtp payload format media types it ma...