Share via


InfoBar.Severity プロパティ

定義

通知の重要度に応じて、一貫した状態の色、アイコン、支援技術の設定を適用する InfoBar の種類を取得または設定します。

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

public:
 property InfoBarSeverity Severity { InfoBarSeverity get(); void set(InfoBarSeverity value); };
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")]
InfoBarSeverity Severity();

void Severity(InfoBarSeverity value);
/// [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")]
InfoBarSeverity Severity();

void Severity(InfoBarSeverity value);
public InfoBarSeverity Severity { [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")] get; [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")] set; }
[Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
[Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")]
public InfoBarSeverity Severity { [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")] get; [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="winrt::InfoBarSeverity::Informational")] set; }
Public Property Severity As InfoBarSeverity

プロパティ値

通知の InfoBar 重要度を示す のスタイル。 既定値は Informational です

属性
Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallbackAttribute Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValueAttribute

ヒント

詳細、設計ガイダンス、およびコード例については、「 InfoBar」を参照してください。

WinUI 3 ギャラリー アプリと WinUI 2 ギャラリー アプリには、ほとんどの WinUI 3 および WinUI 2 コントロールと機能の対話型の例が含まれています。

既にインストールされている場合は、WinUI 3 ギャラリーまたは WinUI 2 ギャラリーのリンクをクリックして開きます。

インストールされていない場合は、Microsoft Store から WinUI 3 ギャラリーWinUI 2 ギャラリーをダウンロードできます。

GitHub から両方のソース コードを取得することもできます (WinUI 3 の場合は main ブランチ、WinUI 2 の場合は winui2 ブランチを使用します)。

適用対象

こちらもご覧ください