# DisplayInfo

Namespace: **Wisej.Hybrid.Shared.Display**

Assembly: **Wisej.Hybrid** (3.5.0.0)

Represents information about the device's screen.

{% tabs %}
{% tab title="C#" %}

```csharp
public class DisplayInfo
```

{% endtab %}

{% tab title="VB.NET" %}

```visual-basic
Public Class DisplayInfo
```

{% endtab %}
{% endtabs %}

## Constructors

### ![](/files/CCV9PPenlC1YZvNh1I6R)DisplayInfo(width, height, density, orientation, rotation)

Initializes a new instance of the [DisplayInfo](/hybrid/start/api/display/wisej.hybrid.shared.display.displayinfo.md) class.

| Name            | Type                                                                                              | Description                 |
| --------------- | ------------------------------------------------------------------------------------------------- | --------------------------- |
| **width**       | [Double](https://docs.microsoft.com/dotnet/api/system.double)                                     | The width of the display.   |
| **height**      | [Double](https://docs.microsoft.com/dotnet/api/system.double)                                     | The height of the display.  |
| **density**     | [Double](https://docs.microsoft.com/dotnet/api/system.double)                                     | The screen density.         |
| **orientation** | [DisplayOrientation](/hybrid/start/api/display/wisej.hybrid.shared.display.displayorientation.md) | The current orientation.    |
| **rotation**    | [DisplayRotation](/hybrid/start/api/display/wisej.hybrid.shared.display.displayrotation.md)       | The rotation of the device. |

### ![](/files/CCV9PPenlC1YZvNh1I6R)DisplayInfo(width, height, density, orientation, rotation, rate)

Initializes a new instance of the [DisplayInfo](/hybrid/start/api/display/wisej.hybrid.shared.display.displayinfo.md) class.

| Name            | Type                                                                                              | Description                      |
| --------------- | ------------------------------------------------------------------------------------------------- | -------------------------------- |
| **width**       | [Double](https://docs.microsoft.com/dotnet/api/system.double)                                     | The width of the display.        |
| **height**      | [Double](https://docs.microsoft.com/dotnet/api/system.double)                                     | The height of the display.       |
| **density**     | [Double](https://docs.microsoft.com/dotnet/api/system.double)                                     | The screen density.              |
| **orientation** | [DisplayOrientation](/hybrid/start/api/display/wisej.hybrid.shared.display.displayorientation.md) | The current orientation.         |
| **rotation**    | [DisplayRotation](/hybrid/start/api/display/wisej.hybrid.shared.display.displayrotation.md)       | The rotation of the device.      |
| **rate**        | [Single](https://docs.microsoft.com/dotnet/api/system.single)                                     | The refresh rate of the display. |

## Properties

### ![](/files/CCV9PPenlC1YZvNh1I6R)Density

[Double](https://docs.microsoft.com/dotnet/api/system.double): Gets a value representing the screen density.

The density is the scaling or a factor that can be used to convert between physical pixels and scaled pixels. For example, on high resolution displays, the physical number of pixels increases, but the scaled pixels remain the same. In a practical example for iOS, the Retina display will have a density of 2.0 or 3.0, but the units used to lay out a view does not change much. A view with a UI width of 100 may be 100 physical pixels (density = 1) on a non-Retina device, but be 200 physical pixels (density = 2) on a Retina device. On Windows, the density works similarly, and may often relate to the scale used in the display. On some monitors, the scale is set to 100% (density = 1), but on other high resolution monitors, the scale may be set to 200% (density = 2) or even 250% (density = 2.5).

### ![](/files/CCV9PPenlC1YZvNh1I6R)Height

[Double](https://docs.microsoft.com/dotnet/api/system.double): Gets the height of the screen (in pixels) for the current [Orientation](#orientation).

### ![](/files/CCV9PPenlC1YZvNh1I6R)Orientation

[DisplayOrientation](/hybrid/start/api/display/wisej.hybrid.shared.display.displayorientation.md): Gets the orientation of the device's display.

### ![](/files/CCV9PPenlC1YZvNh1I6R)RefreshRate

[Single](https://docs.microsoft.com/dotnet/api/system.single): Gets the refresh rate (in Hertz) of the device's display.

### ![](/files/CCV9PPenlC1YZvNh1I6R)Rotation

[DisplayRotation](/hybrid/start/api/display/wisej.hybrid.shared.display.displayrotation.md): Gets the orientation of the device's display.

### ![](/files/CCV9PPenlC1YZvNh1I6R)Width

[Double](https://docs.microsoft.com/dotnet/api/system.double): Gets the width of the screen (in pixels) for the current [Orientation](#orientation).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.wisej.com/hybrid/start/api/display/wisej.hybrid.shared.display.displayinfo.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
