# eric6.WebBrowser.ZoomManager.ZoomManager

Module implementing a manager for site specific zoom level settings.

### Global Attributes

_ZoomManager

### Classes

ZoomManager | Class implementing a manager for site specific zoom level settings.

### Functions

instance | Global function to get a reference to the zoom manager and create it, if it hasn't been yet.

## ZoomManager

Class implementing a manager for site specific zoom level settings.

### Signals

changed()
  emitted to indicate a change of the zoom level

### Derived from

QObject

### Class Attributes

None

### Class Methods

None

### Methods

ZoomManager | Constructor
__keyFromUrl | Private method to generate a DB key for an URL.
allSiteNames | Public method to get a list of all site names.
clear | Public method to clear the saved zoom values.
close | Public method to close the zoom manager.
load | Public method to load the bookmarks.
removeZoomValue | Public method to remove a zoom value entry.
save | Public method to save the zoom values.
setZoomValue | Public method to record the zoom value for the given URL.
siteInfo | Public method to get the zoom value for the site.
sitesCount | Public method to get the number of available sites.
zoomValue | Public method to get the zoom value for an URL.

### Static Methods

None

#### ZoomManager (Constructor)

ZoomManager(parent=None)

Constructor

parent
  reference to the parent object (QObject)

#### ZoomManager.__keyFromUrl

__keyFromUrl(url)

Private method to generate a DB key for an URL.

url (QUrl)
  URL to generate a key for

Returns:
  key for the given URL

Return Type:
  str

#### ZoomManager.allSiteNames

allSiteNames()

Public method to get a list of all site names.

Returns:
  sorted list of all site names

Return Type:
  list of str

#### ZoomManager.clear

clear()

Public method to clear the saved zoom values.

#### ZoomManager.close

close()

Public method to close the zoom manager.

#### ZoomManager.load

load()

Public method to load the bookmarks.

#### ZoomManager.removeZoomValue

removeZoomValue(site)

Public method to remove a zoom value entry.

site (str)
  web site name

#### ZoomManager.save

save()

Public method to save the zoom values.

#### ZoomManager.setZoomValue

setZoomValue(url, zoomValue)

Public method to record the zoom value for the given URL.

Note: Only zoom values not equal 100% are recorded.

url (QUrl)
  URL of the page to remember the zoom value for
zoomValue (int)
  zoom value for the URL

#### ZoomManager.siteInfo

siteInfo(site)

Public method to get the zoom value for the site.

site (str)
  web site name

Returns:
  zoom value for the site

Return Type:
  int

#### ZoomManager.sitesCount

sitesCount()

Public method to get the number of available sites.

Returns:
  number of sites

Return Type:
  int

#### ZoomManager.zoomValue

zoomValue(url)

Public method to get the zoom value for an URL.

url (QUrl)
  URL of the page to get the zoom value for

Returns:
  zoomValue zoom value for the URL

Return Type:
  int

Up

## instance

instance()

Global function to get a reference to the zoom manager and create it, if it hasn't been yet.

Returns:
  reference to the zoom manager object

Return Type:
  ZoomManager

Up