Class DisplayResolution
Contains information regarding a monitor's display resolution.
Inheritance
Inherited Members
Namespace: OpenTK
Assembly: cs.temp.dll.dll
Syntax
public class DisplayResolution
Properties
BitsPerPixel
Gets a System.Int32 that contains number of bits per pixel of this display. Typical values include 8, 16, 24 and 32.
Declaration
public int BitsPerPixel { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Bounds
Gets a System.Drawing.Rectangle that contains the bounds of this display device.
Declaration
[Obsolete("This property will return invalid results if a monitor changes resolution. Use DisplayDevice.Bounds instead.")]
public Rectangle Bounds { get; }
Property Value
Type | Description |
---|---|
Rectangle |
Height
Gets a System.Int32 that contains the height of this display in pixels.
Declaration
public int Height { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
RefreshRate
Gets a System.Single representing the vertical refresh rate of this display.
Declaration
public float RefreshRate { get; }
Property Value
Type | Description |
---|---|
System.Single |
Width
Gets a System.Int32 that contains the width of this display in pixels.
Declaration
public int Width { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Methods
Equals(Object)
Determines whether the specified resolutions are equal.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | The System.Object to check against. |
Returns
Type | Description |
---|---|
System.Boolean | True if the System.Object is an equal DisplayResolution; false otherwise. |
Overrides
GetHashCode()
Returns a unique hash representing this resolution.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | A System.Int32 that may serve as a hash code for this resolution. |
Overrides
ToString()
Returns a System.String representing this DisplayResolution.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | A System.String representing this DisplayResolution. |
Overrides
Operators
Equality(DisplayResolution, DisplayResolution)
Compares two instances for equality.
Declaration
public static bool operator ==(DisplayResolution left, DisplayResolution right)
Parameters
Type | Name | Description |
---|---|---|
DisplayResolution | left | The first instance. |
DisplayResolution | right | The second instance. |
Returns
Type | Description |
---|---|
System.Boolean | True, if left equals right; false otherwise. |
Inequality(DisplayResolution, DisplayResolution)
Compares two instances for inequality.
Declaration
public static bool operator !=(DisplayResolution left, DisplayResolution right)
Parameters
Type | Name | Description |
---|---|---|
DisplayResolution | left | The first instance. |
DisplayResolution | right | The second instance. |
Returns
Type | Description |
---|---|
System.Boolean | True, if left does not equal right; false otherwise. |