+ img.style.width = null;
+ img.style.whiteSpace = 'nowrap';
+ if (offset == 0) {
+ // Hide the box if there's no room for all the text.
+ img.style.opacity = (img.clientWidth < width / dpr + 10) ? null : 0.0;
+ }
+ img.style.width = (width / dpr) + "px";