Summary: | translateZ(0) shifts file name in file input | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | a5951153 | ||||
Component: | Forms | Assignee: | Simon Fraser (smfr) <simon.fraser> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | ap, eric, jonlee, kyle.wanamaker, mifenton, simon.fraser, simulus, tkent, webkit-bug-importer, webkit.review.bot, yosin | ||||
Priority: | P2 | Keywords: | InRadar | ||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | All | ||||||
OS: | All | ||||||
URL: | http://jsfiddle.net/NWR2f/1/ | ||||||
Attachments: |
|
Description
a5951153
2011-10-03 04:08:06 PDT
Note: In the jsFiddle http://jsfiddle.net/NWR2f/1/ of this bug, you have to disable "Normalized CSS" to see it. I made another one http://jsfiddle.net/Am4CD/ and it appears that any kind of transform causes the "No file chosen" text to be pushed down too much and it's relative to the distance to the top/root. Filenames/"No file selected" are rendered in RenderFileUploadControl::paintObject and Y-coordinate is calculated as below[1]: LayoutUnit textY = buttonRenderer->absoluteBoundingBoxRectIgnoringTransforms().y() + buttonRenderer->baselinePosition(AlphabeticBaseline, true, HorizontalLine, PositionOnContainingLine); Note: It seems translate(1) doesn't shift out text. So, does translate(0) cause the problem? = References = [1] http://trac.webkit.org/browser/trunk/Source/WebCore/rendering/RenderFileUploadControl.cpp#L149 BTW, how about rendering text by shadow DOM rather than rendering object? Created attachment 156899 [details]
Patch 1
Comment on attachment 156899 [details]
Patch 1
Could you review this patch?
Thanks in advance.
Comment on attachment 156899 [details] Patch 1 Clearing flags on attachment: 156899 Committed r124960: <http://trac.webkit.org/changeset/124960> All reviewed patches have been landed. Closing bug. *** Bug 89292 has been marked as a duplicate of this bug. *** |