Closed
Bug 216840
Opened 21 years ago
Closed 21 years ago
background of iframe in XUL document can't be transparent if open in chrome window
Categories
(Core :: Web Painting, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 130078
People
(Reporter: phnixwxz1, Assigned: roc)
Details
Attachments
(2 files, 1 obsolete file)
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030820
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030820
The following XUL document (also in attachment):
test.xul:
<!DOCTYPE window>
<window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<vbox id="box1" style="background-color:blue; padding:5px;">
<iframe id="browser1" src="test.html" style="background-color:transparent"/>
</vbox>
</window>
test.html:
<HTML style="overflow: hidden; background-color: transparent">
<BODY style="overflow: hidden; background-color: transparent">
<H1>TEST</H1>
<H1>TEST</H1>
<H1>TEST</H1>
<H1>TEST</H1>
<H1>TEST</H1>
<H1>TEST</H1>
<H1>TEST</H1>
</BODY>
</HTML>
When I open test.xul with command line: mozilla -chrome file:///C:/test.xul, the
background of iframe is always white, although the background-color styles of
iframe itself, HTML and BODY in the HTML are all set to transparent.
When I open test.xul directly in browser window, the iframe background is
transparent as I expected.
Reproducible: Always
Steps to Reproduce:
1. save attachment test.xul and test.html to the same directory (say c:\)
2. mozilla -chrome file:///C:/test.xul
3. open test.xul in mozilla browser window
Actual Results:
step 2. the background of iframe is white (incorrect).
step 3. the background of iframe is transparent (correct).
Expected Results:
step 2. the background of iframe should be transparent
Reporter | ||
Comment 1•21 years ago
|
||
Reporter | ||
Comment 2•21 years ago
|
||
Reporter | ||
Comment 3•21 years ago
|
||
Attachment #130160 -
Attachment is obsolete: true
Reporter | ||
Comment 4•21 years ago
|
||
I hacked into layout/html/base/src/nsPresShell.cpp, and got to know that
document styles are treated differently for chrome windows and other kinds of
windows. Then I modified the following code in nsPresShell.cpp, and rebuild,
and the results are the same.
line 2137 of nsPresShell.cpp (version: 3.647 FIREBIRD_0_6_1_RELEASE)
if (NS_SUCCEEDED(result)){
/*if (nsIDocShellTreeItem::typeChrome == docShellType){
return NS_OK;
}*/
}
If these lines of code are commented out, it will continue to load user
preferences about styles.
Other styles, like link colors, are changed, while the background of iframe is
still white.
Assignee | ||
Comment 5•21 years ago
|
||
*** This bug has been marked as a duplicate of 130078 ***
Status: UNCONFIRMED → RESOLVED
Closed: 21 years ago
Resolution: --- → DUPLICATE
Assignee | ||
Comment 6•21 years ago
|
||
Try the patch I just attached to 130078
Updated•6 years ago
|
Component: Layout: View Rendering → Layout: Web Painting
You need to log in
before you can comment on or make changes to this bug.
Description
•