Version: (using KDE 4.0.98) Installed from: Debian testing/unstable Packages OS: Linux the css attribute clip does not work in konqueror. There exists an old bug: http://bugs.kde.org/show_bug.cgi?id=28480. Which reports the same problem for 3.0 konqeror.
Created attachment 26201 [details] Testcase
*** Bug 167510 has been marked as a duplicate of this bug. ***
Looks like auto: isn't handled in <shape> parsing, and for that matter in RenderStyle construction for in CSSStyleSelector. Oddly enough, RenderBox::clipRect might do the right thing if one encodes auto as Variable Length.
Created attachment 26426 [details] a partial patch This takes care of the parsing and CSSStyleSelector bits, but RenderBox::clipRect doesn't seem to handle borders properly. This stuff is slightly confusing due to RTL, so I hope someone whose area actually is CSS stuff can take a look.
ergh, it also leaks on invalid lengths, if parseUnit fails.
Erm, well, I would have committed a fix already if I could reconcile what the CSS2.1 spec says about the behavior of the property in RTL mode with what other browsers actually do.
SVN commit 843320 by orlovich: Proper parsing and RenderStyle construction for clip:rect(.. auto ...). RenderBox part still needs fixing, but lets get this into SVN so I don't lose it. CCBUG:166830 M +10 -5 cssparser.cpp M +12 -4 cssstyleselector.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=843320
SVN commit 843321 by orlovich: Merged revision 843320: Proper parsing and RenderStyle construction for clip:rect(.. auto ...). RenderBox part still needs fixing, but lets get this into SVN so I don't lose it. CCBUG:166830 M +10 -5 cssparser.cpp M +12 -4 cssstyleselector.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=843321
SVN commit 846526 by orlovich: Fix handling of borders in clip:; particularly important if the length is auto. RTL handling left as following my reading of the spec and not other browsers' behavior. BUG:166830 M +4 -4 render_box.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=846526
SVN commit 846542 by orlovich: Regression test for #166830 CCBUG:166830 A baseline/css/css-clip1.html-dom AM baseline/css/css-clip1.html-dump.png A baseline/css/css-clip1.html-render A tests/css/css-clip1.html WebSVN link: http://websvn.kde.org/?view=rev&revision=846542