Top |
const char * | xfw_monitor_get_identifier () |
const char * | xfw_monitor_get_description () |
const char * | xfw_monitor_get_connector () |
const char * | xfw_monitor_get_make () |
const char * | xfw_monitor_get_model () |
const char * | xfw_monitor_get_serial () |
guint | xfw_monitor_get_refresh () |
guint | xfw_monitor_get_scale () |
gdouble | xfw_monitor_get_fractional_scale () |
void | xfw_monitor_get_physical_geometry () |
void | xfw_monitor_get_logical_geometry () |
void | xfw_monitor_get_workarea () |
void | xfw_monitor_get_physical_size () |
XfwMonitorSubpixel | xfw_monitor_get_subpixel () |
XfwMonitorTransform | xfw_monitor_get_transform () |
gboolean | xfw_monitor_is_primary () |
GdkMonitor * | xfw_monitor_get_gdk_monitor () |
char * | connector | Read |
char * | description | Read |
double | fractional-scale | Read |
GdkMonitor * | gdk-monitor | Read |
guint | height-mm | Read |
char * | identifier | Read |
gboolean | is-primary | Read |
GdkRectangle * | logical-geometry | Read |
char * | make | Read |
char * | model | Read |
GdkRectangle * | physical-geometry | Read |
guint | refresh | Read |
guint | scale | Read |
char * | serial | Read |
XfwMonitorSubpixel | subpixel | Read |
XfwMonitorTransform | transform | Read |
guint | width-mm | Read |
GdkRectangle * | workarea | Read |
XfwMonitor represents a physical monitor connected to the XfwScreen.
In some virtual environments (e.g. a nested X11 or Wayland session), the monitor might instead represent an on-screen window that contains the output of the virtual environment.
const char *
xfw_monitor_get_identifier (XfwMonitor *monitor
);
Retrieves an opaque identifier for this monitor. The identifier can usually be relied upon to uniquely identify this monitor (even if you have multiple identical monitors of the same make and model), assuming the monitor's hardware is set up properly.
This identifier should also be stable across application and machine restarts.
If the monitor's hardware is not set up properly, the identifier may not be unique. Unfortunately, this library cannot determine when this is the case.
Since: 4.19.4
const char *
xfw_monitor_get_description (XfwMonitor *monitor
);
Returns a human-readable description of this monitor, suitable for displaying in a user interface.
Since: 4.19.4
const char *
xfw_monitor_get_connector (XfwMonitor *monitor
);
Returns the name of the physical connector this monitor is connected to.
This might be a string such as "eDP-1", "DP-3", or "HDMI-2". Note that in environments where the monitor is "virtual", a synthetic connector name may be returned.
Since: 4.19.4
const char *
xfw_monitor_get_make (XfwMonitor *monitor
);
Returns the monitor's manufacturer's name, if available.
Since: 4.19.4
const char *
xfw_monitor_get_model (XfwMonitor *monitor
);
Returns the monitor's product model name, if available.
Since: 4.19.4
const char *
xfw_monitor_get_serial (XfwMonitor *monitor
);
Returns the monitor's serial number, if available. Note that some manufacturers do not program their monitor's hardware with unique serial numbers.
Since: 4.19.4
guint
xfw_monitor_get_refresh (XfwMonitor *monitor
);
Returns the monitor's current refresh rate, in millihertz.
Since: 4.19.4
guint
xfw_monitor_get_scale (XfwMonitor *monitor
);
Returns the monitor's scaling factor, as an integer.
Since: 4.19.4
gdouble
xfw_monitor_get_fractional_scale (XfwMonitor *monitor
);
Returns the monitor's scaling factor.
Since: 4.19.4
void xfw_monitor_get_physical_geometry (XfwMonitor *monitor
,GdkRectangle *physical_geometry
);
Retrieves the position and size of the monitor in physical device pixels.
monitor |
a XfwMonitor. |
|
physical_geometry |
a GdkRectangle. |
[not nullable][out caller-allocates] |
Since: 4.19.4
void xfw_monitor_get_logical_geometry (XfwMonitor *monitor
,GdkRectangle *logical_geometry
);
Retrieves the position and size of the monitor in logical application pixels, which are affected by the monitor's fractional scale factor.
monitor |
a XfwMonitor. |
|
logical_geometry |
a GdkRectangle. |
[not nullable][out caller-allocates] |
Since: 4.19.4
void xfw_monitor_get_workarea (XfwMonitor *monitor
,GdkRectangle *workarea
);
Retrieves the workarea for monitor
, which may exclude regions of the screen
for windows such as panels or docks.
The returned geometry is in logical application pixels, which are affected by the monitor's integer scale factor. The origin is set to the top-left corner of the monitor.
Since: 4.19.4
void xfw_monitor_get_physical_size (XfwMonitor *monitor
,guint *width_mm
,guint *height_mm
);
Retrieves the physical width and height of the monitor in millimeters.
monitor |
a XfwMonitor. |
|
width_mm |
an unsigned integer. |
[nullable][out caller-allocates] |
height_mm |
an unsigned integer. |
[nullable][out caller-allocates] |
Since: 4.19.4
XfwMonitorSubpixel
xfw_monitor_get_subpixel (XfwMonitor *monitor
);
Returns the subpixel ordering of monitor
.
Since: 4.19.4
XfwMonitorTransform
xfw_monitor_get_transform (XfwMonitor *monitor
);
Returns the rotation and reflection transform set on monitor
.
Since: 4.19.4
gboolean
xfw_monitor_is_primary (XfwMonitor *monitor
);
Returns whether or not monitor
has been designated as the primary
monitor.
Since: 4.19.4
GdkMonitor *
xfw_monitor_get_gdk_monitor (XfwMonitor *monitor
);
Returns the GdkMonitor that corresponds to monitor
.
Since: 4.19.4
Describes how the color components of the physical pixels are laid out on a monitor.
Since: 4.19.4
Describes the rotation and reflection applied to a monitor.
no transformation applied. |
||
rotated counter-clockwise by 90 degrees. |
||
rotated counter-clockwise by 180 degrees. |
||
rotated counter-clockwise by 270 degrees. |
||
flipped along a vertical axis. |
||
flipped along a vertical axis and rotated
counter-clockwise by 90 degrees. |
||
flipped along a vertical axis and rotated counter-clockwise by 270 degrees. |
Since: 4.19.4
“connector”
property “connector” char *
Physical/virtual connector name.
Owner: XfwMonitor
Flags: Read
Default value: NULL
Since: 4.19.4
“description”
property “description” char *
Human-readable description.
Owner: XfwMonitor
Flags: Read
Default value: NULL
Since: 4.19.4
“fractional-scale”
property “fractional-scale” double
UI fractional scaling factor.
Owner: XfwMonitor
Flags: Read
Allowed values: >= 1
Default value: 1
Since: 4.19.4
“gdk-monitor”
property “gdk-monitor” GdkMonitor *
The GdkMonitor corresponding to this monitor.
Since 4.19.4
Owner: XfwMonitor
Flags: Read
“height-mm”
property “height-mm” guint
Physical height of the monitor in millimeters.
Owner: XfwMonitor
Flags: Read
Default value: 0
Since: 4.19.4
“identifier”
property “identifier” char *
Opaque, hopefully-unique monitor identifier.
Owner: XfwMonitor
Flags: Read
Default value: NULL
Since: 4.19.4
“is-primary”
property “is-primary” gboolean
Whether or not this monitor is the primary monitor.
Owner: XfwMonitor
Flags: Read
Default value: FALSE
Since: 4.19.4
“logical-geometry”
property “logical-geometry” GdkRectangle *
Coordinates and size of the monitor in scaled logical pixels.
Owner: XfwMonitor
Flags: Read
Since: 4.19.4
“make”
property “make” char *
Manufacturer name.
Owner: XfwMonitor
Flags: Read
Default value: NULL
Since: 4.19.4
“model”
property “model” char *
Product model name.
Owner: XfwMonitor
Flags: Read
Default value: NULL
Since: 4.19.4
“physical-geometry”
property “physical-geometry” GdkRectangle *
Coordinates and size of the monitor in physical device pixels.
Owner: XfwMonitor
Flags: Read
Since: 4.19.4
“refresh”
property “refresh” guint
Current refresh rate, in millihertz.
Owner: XfwMonitor
Flags: Read
Default value: 60000
Since: 4.19.4
“scale”
property “scale” guint
UI scaling factor.
Owner: XfwMonitor
Flags: Read
Allowed values: >= 1
Default value: 1
Since: 4.19.4
“serial”
property “serial” char *
Product serial number.
Owner: XfwMonitor
Flags: Read
Default value: NULL
Since: 4.19.4
“subpixel”
property“subpixel” XfwMonitorSubpixel
Hardware subpixel layout.
Owner: XfwMonitor
Flags: Read
Default value: XFW_MONITOR_SUBPIXEL_UNKNOWN
Since: 4.19.4
“transform”
property“transform” XfwMonitorTransform
Rotation and reflection of the monitor's contents.
Owner: XfwMonitor
Flags: Read
Default value: XFW_MONITOR_TRANSFORM_NORMAL
“width-mm”
property “width-mm” guint
Physical width of the monitor in millimeters.
Owner: XfwMonitor
Flags: Read
Default value: 0
Since: 4.19.4