Bug 34032 - -webkit-border-radius does not work on <img> tag in Mobile Safari
Summary: -webkit-border-radius does not work on <img> tag in Mobile Safari
Status: RESOLVED INVALID
Alias: None
Product: WebKit
Classification: Unclassified
Component: Images (show other bugs)
Version: 523.x (Safari 3)
Hardware: Other Other
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-01-22 19:40 PST by supercollideher
Modified: 2010-01-26 11:08 PST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description supercollideher 2010-01-22 19:40:36 PST
The sample HTML below does work in the desktop version of Mac Safari but not the iphone 3.0 version (and, presumably, previous versions). Desired behavior is to have the corners of the image rounded off. If you add colored padding of ~10px to the style definition, you can see that the in mobile safari, padding gets rounded off, but then the image with unrounded corners gets drawn over the rounded padding.

If webkit on the iphone and the mac desktop call the same platform drawing routine, I guess that indicates that the iphone implementation of the function that clips the corners works differently from the desktop version (I poked around a little bit in the code -- seems that CGContextClipToRect is what is getting called on the host platform. Could be mistaken, though. First time looking at webkit code)

<html>
<head>
<style type="text/css">
img { -webkit-border-radius: 100px; }
</style>
</head>
<body>
<img src="http://www.fis.ncsu.edu/trademark/images/ncsu/new_cd/NCS_MonoS_2C_2.gif">
</body>
</html>
Comment 1 Simon Fraser (smfr) 2010-01-26 11:08:02 PST
Please file MobileSafari bugs at http://bugreporter.apple.com