diff --git a/lib/OpenLayers/Control/Scale.js b/lib/OpenLayers/Control/Scale.js index 5663bfdae9..770e4735f4 100644 --- a/lib/OpenLayers/Control/Scale.js +++ b/lib/OpenLayers/Control/Scale.js @@ -31,12 +31,7 @@ OpenLayers.Control.Scale.prototype = OpenLayers.Control.prototype.draw.apply(this, arguments); if (!this.element) { this.element = document.createElement("div"); - this.div.style.right = "3px"; - this.div.style.bottom = "2em"; - this.div.style.left = ""; - this.div.style.top = ""; - this.div.style.display = "block"; - this.div.style.position = "absolute"; + this.div.className = "olControlScale"; this.element.style.fontSize="smaller"; this.div.appendChild(this.element); } diff --git a/theme/default/style.css b/theme/default/style.css index e69de29bb2..ebeb103a03 100644 --- a/theme/default/style.css +++ b/theme/default/style.css @@ -0,0 +1,6 @@ +.olControlScale { + right: 3px; + bottom: 3em; + display: block; + position: absolute; +}