Unofficial CSS property zoom implemented on WebKit
I found unofficial CSS property "zoom
" is implemented on WebKit (Safari and Google Chrome.) And is not implemented on Gecko (Firefox.)
Here is test of CSS
zoom
. (scale by 200%.)
<div style="zoom: 2.0; background-color: #ff8;">
Here is test of CSS <code>zoom</code>. (scale by 200%.)
</div>
I think if you wanna scale you SHALL use CSS3 transform as follows:
Here is test of CSS3
transform
. (scale by 200%.)
<div style="transform: scale(2); -webkit-transform: scale(2); -webkit-transform-origin: 0 0; -moz-transform: scale(2); -moz-transform-origin: 0 0; -o-transform: scale(2); -o-transform-origin: 0 0; -ms-transform: scale(2); -ms-transform-origin: 0 0;">
Here is test of CSS3 <code>transform</code>. (scale by 200%.)
</div>
Note that...
- CSS3 transform is a W3C working draft.
So vender prefix (e.g.
-webkit-
,-moz-
,-o-
, and/or-ms-
) is required. - The default value of
transform-origin
is "50% 50%
" (orcenter center
) So I specifiedtransform-origin: 0 0
(ortop left
) to do the same thing withzoom
.