Gdk.Monitor¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
---|---|---|---|
r |
|||
r |
|||
r/w/co |
|||
r |
|||
r |
|||
r |
|||
r |
|||
r |
|||
r |
|||
r |
|||
r |
|||
r |
Signals¶
- Inherited:
Name |
Short Description |
---|---|
Emitted when the output represented by monitor gets disconnected. |
Fields¶
- Inherited:
Class Details¶
- class Gdk.Monitor(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
GdkMonitor
objects represent the individual outputs that are associated with aGdkDisplay
.GdkDisplay
keeps aGListModel
to enumerate and monitor monitors with [method`Gdk`.Display.get_monitors]. You can use [method`Gdk`.Display.get_monitor_at_surface] to find a particular monitor.- get_connector()[source]¶
-
Gets the name of the monitor’s connector, if available.
These are strings such as “eDP-1”, or “HDMI-2”. They depend on software and hardware configuration, and should not be relied on as stable identifiers of a specific monitor.
- get_description()[source]¶
-
Gets a string describing the monitor, if available.
This can be used to identify a monitor in the UI.
New in version 4.10.
- get_display()[source]¶
- Returns:
the display
- Return type:
Gets the display that this monitor belongs to.
- get_geometry()[source]¶
- Returns:
a
GdkRectangle
to be filled with the monitor geometry- Return type:
geometry:
Gdk.Rectangle
Retrieves the size and position of the monitor within the display coordinate space.
The returned geometry is in ”application pixels”, not in ”device pixels” (see [method`Gdk`.Monitor.get_scale_factor]).
- get_height_mm()[source]¶
- Returns:
the physical height of the monitor
- Return type:
Gets the height in millimeters of the monitor.
- get_manufacturer()[source]¶
-
Gets the name or PNP ID of the monitor’s manufacturer.
Note that this value might also vary depending on actual display backend.
The PNP ID registry is located at https://uefi.org/pnp_id_list.
- get_refresh_rate()[source]¶
- Returns:
the refresh rate in milli-Hertz, or 0
- Return type:
Gets the refresh rate of the monitor, if available.
The value is in milli-Hertz, so a refresh rate of 60Hz is returned as 60000.
- get_scale_factor()[source]¶
- Returns:
the scale factor
- Return type:
Gets the internal scale factor that maps from monitor coordinates to device pixels.
On traditional systems this is 1, but on very high density outputs it can be a higher value (often 2).
This can be used if you want to create pixel based data for a particular monitor, but most of the time you’re drawing to a surface where it is better to use [method`Gdk`.Surface.get_scale_factor] instead.
- get_subpixel_layout()[source]¶
- Returns:
the subpixel layout
- Return type:
Gets information about the layout of red, green and blue primaries for pixels.
Signal Details¶
- Gdk.Monitor.signals.invalidate(monitor)¶
- Signal Name:
invalidate
- Flags:
- Parameters:
monitor (
Gdk.Monitor
) – The object which received the signal
Emitted when the output represented by monitor gets disconnected.
Property Details¶
- Gdk.Monitor.props.connector¶
-
The connector name.
- Gdk.Monitor.props.description¶
-
A short description of the monitor, meant for display to the user.
New in version 4.10.
- Gdk.Monitor.props.display¶
- Name:
display
- Type:
- Default Value:
- Flags:
The
GdkDisplay
of the monitor.
- Gdk.Monitor.props.geometry¶
- Name:
geometry
- Type:
- Default Value:
- Flags:
The geometry of the monitor.
- Gdk.Monitor.props.height_mm¶
-
The height of the monitor, in millimeters.
- Gdk.Monitor.props.manufacturer¶
-
The manufacturer name.
- Gdk.Monitor.props.refresh_rate¶
-
The refresh rate, in milli-Hertz.
- Gdk.Monitor.props.scale_factor¶
-
The scale factor.
- Gdk.Monitor.props.subpixel_layout¶
- Name:
subpixel-layout
- Type:
- Default Value:
- Flags:
The subpixel layout.
- Gdk.Monitor.props.valid¶
-
Whether the object is still valid.