Closed
Bug 646799
Opened 13 years ago
Closed 13 years ago
Content area <iframe> is not clipped to content edge curve when using border-radius
Categories
(Core :: Web Painting, defect)
Tracking
()
VERIFIED
FIXED
mozilla6
People
(Reporter: ottodv, Assigned: tnikkel)
References
()
Details
(Keywords: dev-doc-complete, testcase)
Attachments
(4 files)
17.68 KB,
image/png
|
Details | |
171 bytes,
text/html
|
Details | |
1.34 KB,
patch
|
roc
:
review+
|
Details | Diff | Splinter Review |
3.17 KB,
patch
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:2.0) Gecko/20100101 Firefox/4.0 Build Identifier: Mozilla/5.0 (X11; Linux x86_64; rv:2.0) Gecko/20100101 Firefox/4.0 We have an iframe with rounded corners using CSS (border-radius), the background color does not always respect the rounded corners of the iframe. We have two situations: 1. The background color is defined within the framed document itself. In this case the rounded corners are not respected by the background color. 2. The background color is defined by the iframe (style of the iframe tag), in which case the rounded corners are respected. I have a test page showing these two situations and will attach a screenshot to show what I see. Test page: http://www.7is7.com/devl/firefox/border.html Reproducible: Always Steps to Reproduce: 1. Visit http://www.7is7.com/devl/firefox/border.html Actual Results: Rounded corners not respected in one of the two iframes. Expected Results: Rounded corners respected in both iframes.
Reporter | ||
Comment 1•13 years ago
|
||
The left iframe does not respect rounded corners, the right one does. In the left iframe the background color is defined in the framed document. In the right iframe it is defined in the iframe tag.
Confirmed on Mozilla/5.0 (Windows NT 6.1; rv:2.2a1pre) Gecko/20110330 Firefox/4.2a1pre
Updated•13 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Linux → All
Product: Firefox → Core
QA Contact: general → general
Comment 3•13 years ago
|
||
Comment 4•13 years ago
|
||
roc, timothy, what's up here?
Component: General → Layout: View Rendering
QA Contact: general → layout.view-rendering
Comment 5•13 years ago
|
||
Compare what happens if you take out the background in the subframe and replace it with text. The text will also bleed out of the curved area. The same effect is observed in Opera 11. IE9 has the Webkit behavior of clipping to the border. The relevant part of CSS3 background is this, from <http://www.w3.org/TR/css3-background/#corner-clipping>: The content of replaced elements is always trimmed to the content edge curve. We implement this for <img>, but apparently it doesn't work for <iframe>?
Summary: Background color of framed document doesn't respect CSS rounded corners of iframe. → Content area <iframe> is not clipped to content edge curve when using border-radius
Assignee | ||
Comment 6•13 years ago
|
||
I think we just haven't implemented that clipping for iframes yet. http://hg.mozilla.org/mozilla-central/rev/0aa1272e932f added it for most replaced elements, it doesn't seem like it should be too hard to modify nsSubDocumentFrame::BuildDisplayList to clip using the same method.
Assignee | ||
Comment 7•13 years ago
|
||
Assignee: nobody → tnikkel
Attachment #523942 -
Flags: review?(roc)
Comment on attachment 523942 [details] [diff] [review] patch Need reftest
Attachment #523942 -
Flags: review?(roc) → review+
Assignee | ||
Comment 9•13 years ago
|
||
Assignee | ||
Updated•13 years ago
|
Keywords: checkin-needed
Whiteboard: [needs landing][needs a tryserver check]
Updated•13 years ago
|
Status: NEW → ASSIGNED
Keywords: checkin-needed
Whiteboard: [needs landing][needs a tryserver check] → [fixed in cedar]
Comment 10•13 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/e1b06f3256c8 http://hg.mozilla.org/mozilla-central/rev/6cc6b44735a7
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Keywords: dev-doc-needed
Resolution: --- → FIXED
Whiteboard: [fixed in cedar]
Target Milestone: --- → mozilla6
Comment 11•13 years ago
|
||
Documentation updated: https://developer.mozilla.org/en/HTML/Element/iframe#Notes This change is also now mentioned on Firefox 6 for developers.
Keywords: dev-doc-needed → dev-doc-complete
Assignee | ||
Comment 12•13 years ago
|
||
Thank you.
Comment 13•13 years ago
|
||
This patch might have cause a regression, see bug 610305 comment 13 to 21.
Comment 14•13 years ago
|
||
(In reply to comment #13) > This patch might have cause a regression, see bug 610305 comment 13 to 21. Will this patch be backed out?
Comment 15•13 years ago
|
||
No, see bug 610305 comment 22.
Comment 16•13 years ago
|
||
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:6.0) Gecko/20100101 Firefox/6.0 Verified issue on Mac OS X 10.6, Windows 7x86_64 and Ubuntu 86_64 - rounded corners respect iframes. Setting resolution to VERIFIED FIXED.
Status: RESOLVED → VERIFIED
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
•