Skip to main content

Posts

Showing posts with the label Firefox

Hr (horizontal line) style in FireFox vs IE vs Chrome - Simplest Simple feature doesn't work same - Hope you can save some time.

ISSUE: I wasted few minutes figuring out World's simplest simple issue 'drawing a single line' with 1pixel width and a color in html that looks same in at least 3 browsers ( Firefox, IE, Chrome ) I just want to do a simple  code like, < hr style = " color : #ff6a00 ; " >  - Firefox: Shows the line with given color but with a border. (Thats good. 4 Stars for Firefox team) - IE: Shows line with default 'gray' with default width - Chrome: Shows line with default 'gray' with default width   (depending on the browser you are looking - the above line will show as mentioned above) < hr style = " color : #ff6a00 ; height : 1 px ; border : 0 ; width : 100 % ; " >   All 3 Browsers: No Show - No line Even if you try increasing border and height,  < hr style = " color : #ff6a00 ; height : 1 0px ; border : 3px; width : 100 % ; " > it will not show the line. FIX:  You have to use the backgro...

Thunderbird or Firefox extension - nsISimpleEnumerator

Issue :  Some of the Firefox or Mozilla application extension API s return  an enumerator object of type interface nsISimpleEnumerator ,  that result objects can not be used in a global scope and can not do iteration through the  list more than one time.   Cause: nsISimpleEnumerator  interface has only two methods hasMoreElements() getNext()   - There is no way to reset this enumerator to the first position once it is iterated through once. Like in this example given in Mozilla developer example page,  ( https://developer.mozilla.org/en-US/docs/Using_nsISimpleEnumerator )   var enumerator = document.getElementById('aStringBundleID').strings; var s = ""; while (enumerator.hasMoreElements()) { var property = enumerator.getNext().QueryInterface(Components.interfaces.nsIProperty); s += property.name + ' = ' + property.value + ';\n'; } If you want to reuse the 'enumerator' object again, in another place another loop, this wil...