Gm.DisplayPanel¶
- Subclasses:
None
Methods¶
- Inherited:
- Structs:
class |
|
class |
|
class |
|
|
|
|
|
|
|
|
|
|
|
|
Virtual Methods¶
- Inherited:
Properties¶
Name |
Type |
Flags |
Short Description |
|---|---|---|---|
d/r/w |
|
||
r/w |
|||
r/w |
|||
r/w |
|||
r/w |
|||
r/w |
|||
r/w |
|||
r/w |
Signals¶
- Inherited:
Fields¶
- Inherited:
Class Details¶
- class Gm.DisplayPanel(**kwargs)¶
- Bases:
- Abstract:
No
- Structure:
Physical properties of a display panel like size, cutouts and rounded corners.
Added in version 0.0.1.
- classmethod new()¶
- Returns:
The new display panel object
- Return type:
Constructs a new display panel object.
Added in version 0.0.1.
- classmethod new_from_data(data)¶
- Parameters:
data (
str) – The panel’s data as JSON- Raises:
- Returns:
The new display panel object
- Return type:
Constructs a new display panel based on the given data. If that fails
NULLis returned anderrordescribes the error that occurred.Added in version 0.0.1.
- classmethod new_from_resource(resource_name)¶
- Parameters:
resource_name (
str) – A path to a gresource- Raises:
- Returns:
The new display panel object
- Return type:
Constructs a new display panel by fetching the data from the given
Gio.Resource. If that failsNULLis returned anderrordescribes the error that occurred.Added in version 0.0.1.
- get_border_radius()¶
- Returns:
The panel’s border radius.
- Return type:
Gets the panels border radius. 0 indicates rectangular corners. If top and bottom border radius are different then this matches the top border radius. given applies to all corners of the panel.
Added in version 0.0.1.
Deprecated since version 0.6.0: Use [method`DisplayPanel`.get_corner_radii] instead
- get_corner_radii()¶
- Returns:
The panel’s border radii.
- Return type:
[
int]
Gets the panels border radii starting with the top-left corner clockwise.
Added in version 0.6.0.
- get_cutouts()¶
- Returns:
The display cutouts
- Return type:
Get the display cutouts.
Added in version 0.0.1.
- get_height()¶
- Returns:
The panel’s height.
- Return type:
Gets the panels height in mm.
Added in version 0.0.1.
- get_name()¶
- Returns:
The panel’s name
- Return type:
Gets the panel’s name.
Added in version 0.0.1.
- get_width()¶
- Returns:
The panel’s width.
- Return type:
Gets the panels width in mm.
Added in version 0.0.1.
- get_x_res()¶
- Returns:
The x resolution.
- Return type:
Gets the panels resolution (in pixels) in the x direction
Added in version 0.0.1.
Property Details¶
- Gm.DisplayPanel.props.border_radius¶
- Name:
border-radius- Type:
- Default Value:
0- Flags:
The corner radius of the panel edges in device pixels.
Added in version 0.0.1.
Deprecated since version 0.6.0: Use [property`DisplayPanel`:corner-radii] instead
- Gm.DisplayPanel.props.corner_radii¶
- Name:
corner-radii- Type:
- Default Value:
- Flags:
The radii of the panels corner starting top-left and going clockwise.
Added in version 0.6.0.
- Gm.DisplayPanel.props.cutouts¶
- Name:
cutouts- Type:
- Default Value:
- Flags:
The display cutouts as
GListModelof [class`Cutout`].Added in version 0.0.1.
- Gm.DisplayPanel.props.height¶
-
The display height in millimeters
Added in version 0.0.1.
- Gm.DisplayPanel.props.name¶
-
The name of the display
Added in version 0.0.1.
- Gm.DisplayPanel.props.width¶
-
The display width in millimeters
Added in version 0.0.1.
- Gm.DisplayPanel.props.x_res¶
-
The panel resolution in pixels in the x direction
Added in version 0.0.1.