GridLength 建構函式

定義

初始化 GridLength 結構的新執行個體。

多載

GridLength(Double)

使用指定的絕對值 (以像素為單位),初始化 GridLength 結構的新執行個體。

GridLength(Double, GridUnitType)

初始化 GridLength 結構的新執行個體,並指定要包含何種值。

GridLength(Double)

使用指定的絕對值 (以像素為單位),初始化 GridLength 結構的新執行個體。

public:
 GridLength(double pixels);
public GridLength (double pixels);
new System.Windows.GridLength : double -> System.Windows.GridLength
Public Sub New (pixels As Double)

參數

pixels
Double

與裝置無關 (Device-Independent) 的像素的數目 (每吋 96 個像素)。

例外狀況

適用於

GridLength(Double, GridUnitType)

初始化 GridLength 結構的新執行個體,並指定要包含何種值。

public:
 GridLength(double value, System::Windows::GridUnitType type);
public GridLength (double value, System.Windows.GridUnitType type);
new System.Windows.GridLength : double * System.Windows.GridUnitType -> System.Windows.GridLength
Public Sub New (value As Double, type As GridUnitType)

參數

value
Double

這個 GridLength 執行個體的初始值。

type
GridUnitType

這個 GridUnitType 執行個體包含的 GridLength

例外狀況

另請參閱

適用於