New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 652102 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Sep 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 2
Type: Bug



Sign in to add a comment

HTMLInputElement#scrollLeft returns wrong value when using browser zoom

Reported by vmuhac...@gmail.com, Oct 2 2016

Issue description

UserAgent: Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36

Steps to reproduce the problem:
https://jsfiddle.net/dn45k2wg/

1. Create an html file with:

<style>
#div, #input {
  font: inherit;
  padding: 0px;
  margin: 0px;
  border: 1px solid silver;
  width: 50px;
  display: inline-block;
  overflow: hidden;
  vertical-align: middle;
  white-space: nowrap;
  background: white;
}
th {
  text-align: left;
}
</style>
<div id="div">0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF</div>
<input type="text" id="input" value="0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF0123456789ABCDEF" />
<table id="log"></table>
<script>
var div = document.getElementById("div");
var input = document.getElementById("input");
var log = document.getElementById("log");
window.setInterval(function () {
  div.scrollLeft = 10000;
  input.scrollLeft = 10000;
  log.innerHTML = "<tr><th>div.scrollLeft</th><td>" + div.scrollLeft.toFixed(3) + "</td></tr>" +
                  "<tr><th>input.scrollLeft</th><td>" + input.scrollLeft.toFixed(3) + "</td></tr>" +
                  "<tr><th>(div.scrollLeft / input.scrollLeft)</th><td>" + (div.scrollLeft / input.scrollLeft).toFixed(3) + "</td></tr>" +
                  "<tr><th>window.devicePixelRatio</th><td>" + window.devicePixelRatio.toFixed(3) + "</td></tr>";

}, 1000);
</script>

2. Open in Chrome on Windows (note: cannot reproduce on other systems).
3. Try to use the browser zoom.

What is the expected behavior?

What went wrong?
HTMLInputElement#scrollLeft returns wrong value when using browser zoom

Did this work before? N/A 

Chrome version: 49.0.2623.112  Channel: n/a
OS Version: 5.1 (Windows XP)
Flash Version: Shockwave Flash 23.0 r0

It is reproducable only under Windows (7, 8, 10)
 
Note: It is reproducible in Chrome 53


Cc: kkaluri@chromium.org
Labels: M-55 OS-Linux OS-Mac
Status: Untriaged (was: Unconfirmed)
Able to reproduce this issue on Windows-10, Ubuntu 14,04 and Mac OS 10.12 using chrome latest stable M53-53.0.2785.143 and earlier version of chrome M35-35.0.1849.0. Observed that HTMLInputElement#scrollLeft returns wrong value while zooming the browser.

This is a non-regression issue and marking it as untriaged.
 

Components: -Blink Blink>Layout

Comment 4 by drott@chromium.org, Oct 10 2016

Cc: yosin@chromium.org nona@chromium.org
Status: Available (was: Untriaged)

Comment 5 by e...@chromium.org, Sep 8 2017

Status: WontFix (was: Available)
Unable to reproduce.
It is still reproducible in Chrome 62 (Windows 7)

Sign in to add a comment