Share via


NavigationViewTemplateSettings.OpenPaneLength プロパティ

定義

minOpenPaneLength とウィンドウの幅の間を取得します。 これは、ウィンドウを開いて完全に展開したときのウィンドウの幅の計算値です。

このドキュメントは、WinUI 2 for UWP に適用されます (Windows アプリ SDKWinUI については、Windows アプリ SDK名前空間を参照してください)。

public:
 property double OpenPaneLength { double get(); };
/// [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="320.0")]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="320.0")]
double OpenPaneLength();
[Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="320.0")]
public double OpenPaneLength { [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="320.0")] get; }
Public ReadOnly Property OpenPaneLength As Double

プロパティ値

Double

double

minOpenPaneLength とウィンドウの幅の間。 既定値は 320.0 です。

属性
Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValueAttribute

この例では、 NavigationViewTemplateSettings.OpenPaneLength For で ControlTemplateNavigationViewWindows.UI.Xaml.Controls.SplitView.OpenPaneLength に渡すために使用されているプロパティを示します。

<ControlTemplate TargetType="NavigationView">
    <!-- ... -->
    <SplitView
        OpenPaneLength="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.OpenPaneLength}"
        Background="{TemplateBinding Background}"
        BorderBrush="{ThemeResource NavigationViewItemSeparatorForeground}"
        BorderThickness="{ThemeResource NavigationViewBorderThickness}"
        CompactPaneLength="{TemplateBinding CompactPaneLength}"
        DisplayMode="Inline"
        IsPaneOpen="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=IsPaneOpen, Mode=TwoWay}"
        IsTabStop="False"
        PaneBackground="{ThemeResource NavigationViewDefaultPaneBackground}">

適用対象