DisplayProperties 類別

定義

注意

Windows 8.1之後,可能會變更或無法使用 DisplayProperties。 請改用 DisplayInformation

提供與實體顯示相關的各種屬性。 對於這些屬性的大部分,類別會提供事件,以允許用戶端監視屬性中的變更。

public ref class DisplayProperties abstract sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, Windows.Foundation.UniversalApiContract)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class DisplayProperties final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
class DisplayProperties final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, typeof(Windows.Foundation.UniversalApiContract))]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public static class DisplayProperties
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Deprecated("DisplayProperties may be altered or unavailable for releases after Windows Phone 8.1. Instead, use DisplayInformation.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 65536, "Windows.Foundation.UniversalApiContract")]
public static class DisplayProperties
Public Class DisplayProperties
繼承
Object Platform::Object IInspectable DisplayProperties
屬性

Windows 需求

裝置系列
Windows 10 (已於 10.0.10240.0 引進)
API contract
Windows.Foundation.UniversalApiContract (已於 v1.0 引進)

屬性

AutoRotationPreferences

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

取得和設定應用程式的慣用方向。

CurrentOrientation

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

取得矩形監視器的目前方向。

LogicalDpi

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

取得目前環境每個邏輯英吋的圖元。

NativeOrientation

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

取得顯示監視器的原生方向,這通常是裝置上按鈕符合監視器方向的方向。

ResolutionScale

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

取得應用程式視窗的縮放比例。

StereoEnabled

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

取得值,這個值表示裝置是否支援身歷聲 3D。

方法

GetColorProfileAsync()

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

以非同步方式取得與實體顯示器相關聯的預設國際色彩聯盟 (ICC) 色彩設定檔。

事件

ColorProfileChanged

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

發生于實體顯示器的色彩設定檔變更時。

DisplayContentsInvalidated

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

當顯示器需要重新繪製時發生。

LogicalDpiChanged

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

發生于 LogicalDpi 屬性變更時,因為每英吋圖元 () 顯示變更。

OrientationChanged

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

發生于 CurrentOrientationNativeOrientation 屬性因為模式變更或監視變更而變更時。

StereoEnabledChanged

注意

Windows 8.1之後,可能會變更或無法使用DisplayProperties。 請改用 DisplayInformation

StereoEnabled 屬性變更時發生,因為支援身歷聲 3D 變更。

適用於