Closed Bug 109437 Opened 23 years ago Closed 21 years ago

Internet Explorer (MSIE) Filters... Do they have a place in Mozilla?

Categories

(Core :: DOM: CSS Object Model, enhancement)

x86
Windows 98
enhancement
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 64019

People

(Reporter: kevinar18, Assigned: jst)

References

()

Details

From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:0.9.5) Gecko/20011011
BuildID:    2001101117

First you may want to check this reference URL:
http://www.webreference.com/js/column68/

Basically, I have a site (cgi generated page) that makes use of of the "Alpha"
transparency filter to make a DIV layer a certain level of transparency.

I just wanted to bring up this issue of filters with the hopes that maybe it can
be included as a future feature of Mozilla....
first with CSS styles then with javascript.

Reproducible: Always
Steps to Reproduce:
Sample code using Alpha transparency on DIV layer:

<div id="SelectionLayer" style="position:absolute; width:100px; height:100px;
z-index:91; background-color: #FFFF00; border: 1px solid #0000FF; filter:
Alpha(Opacity=50); visibility: hidden"></div>

Actual Results:  No transparency.

Expected Results:  Should have an alpha transparency of 50.
We don't need this. Look into -moz-opacity; when the appropriate CSS3 module is
finalized, we'll use the standard opacity property defined there.  Closing WONTFIX.
Status: UNCONFIRMED → RESOLVED
Closed: 23 years ago
Resolution: --- → WONTFIX
*** Bug 109503 has been marked as a duplicate of this bug. ***
If there's gonna be Mozilla specific code (which is only gonna be in effect for
a little while), why not have backwards compatability with IE?

In other words, why make a Mozilla only "moz-opacity" instead of just going with
what has already been used.
Ok, from what I can tell "moz-opacity" is not a filter per say, but a Mozilla
only version of what may be in CSS 3.

But still, why go with Mozilla only code when it could have just been made
backwards compatable with IE?
It took me a bit to track down the proper syntax for this in mozilla and IE, so
I thought I'd repeat it here in case anyone else needs it. The css for 50%
opacity is:

IE:
filter: Alpha(Opacity=50);

Mozilla:
-moz-opacity: 0.50;

To dynamically manipulate this using JavaScript:

IE:
document.getElementById('SelectionLayer').style.filter='Alpha(Opacity=50)';

Mozilla:
document.getElementById('SelectionLayer').style.MozOpacity='0.5';
Summary: Internet Explorer Filters... Do they have a place in Mozilla? → Internet Explorer (MSIE) Filters... Do they have a place in Mozilla?
Another helpful reference that shows % is also a valid unit for Mozilla:
http://www.wsabstract.com/dhtmltutors/opacityns6.shtml
*** Bug 182791 has been marked as a duplicate of this bug. ***
no to 'filter()'
Status: RESOLVED → VERIFIED
Reopening to mark as a dup of bug 64019.
Status: VERIFIED → UNCONFIRMED
Resolution: WONTFIX → ---

*** This bug has been marked as a duplicate of 64019 ***
Status: UNCONFIRMED → RESOLVED
Closed: 23 years ago21 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.