NPAPI:BrowserZoomLevelQuery
Jump to navigation
Jump to search
Status
Initial draft
Contributors
- Last modified: 2015-12-21
- Authors: Kyle Machulis (Mozilla)
Overview
Currently, NPAPI plugins have no way to know if the browser is running at a zoom level other than 1x. We need an addition to the API that allows plugins to query the current browser zoom level.
Specification
We'll need to add a NPNV variable:
NPNVbrowserZoomFactor = 23
This can be retrieved via NPN_GetValue, and will return a double representing the current zoom level of the browser. Since changing zoom levels updates the window properties, this value can be re-queried during NPN_SetWindow or other window property update calls, to see if a zoom change has been made.