2

Chrome can be zoomed in or out by pressing Ctrl + + or - (Windows).

And I also noticed that some webpages can detective if current page is zoomed or not.

How do they get that good and is there any Webkit or HTML5 API can zoom Chrome on current page programmatically?

Sam Su
  • 4,585
  • 6
  • 31
  • 74

2 Answers2

3

In css:

zoom: 150%

Appply this css property to body

Or in js

$(document.body).css('zoom','150%')

To catch zoom event there are several techics ( check zoom on 'resize' for example ) - check this topic Catch browser's "zoom" event in JavaScript

Community
  • 1
  • 1
Vasiliy Vanchuk
  • 6,280
  • 2
  • 18
  • 39