Window.SystemBackdrop Propriété

Définition

Obtient ou définit la toile de fond système à appliquer à ce Window. L’arrière-plan est affiché derrière le Window contenu.

public:
 property SystemBackdrop ^ SystemBackdrop { SystemBackdrop ^ get(); void set(SystemBackdrop ^ value); };
SystemBackdrop SystemBackdrop();

void SystemBackdrop(SystemBackdrop value);
public SystemBackdrop SystemBackdrop { get; set; }
var systemBackdrop = window.systemBackdrop;
window.systemBackdrop = systemBackdrop;
Public Property SystemBackdrop As SystemBackdrop

Valeur de propriété

Toile de fond du système à appliquer à ce Window.

Exemples

Cet exemple montre comment définir pour utiliser MicaSystemBackdrop Alt.

<Window
    ...>
    <Window.SystemBackdrop>
        <MicaBackdrop Kind="BaseAlt"/>
    </Window.SystemBackdrop>

    <Grid RowDefinitions="*,*">
        <!-- This area has a transparent background, so the Mica
         backdrop will be mostly visible. For example, if there are
         buttons here, the backdrop will show up in the margins
         and gaps between the buttons. -->
        <Grid Background="Transparent"></Grid>

        <!-- This area has an opaque background,
         so the Mica backdrop won't be visible. -->
        <Grid Grid.Row="1" Background="Gray"></Grid>
    </Grid>
</Window>
public MainWindow()
{
    this.InitializeComponent();

    SystemBackdrop = new MicaBackdrop() 
                        { Kind = MicaKind.BaseAlt };
}

Remarques

Pour plus d’informations sur les arrière-plan système, consultez Matériaux dans Windows 11.

La toile de fond est affichée derrière le contenu spécifié dans Window.Content. Si tout le contenu est entièrement opaque, cette toile de fond n’aura aucun effet visible.

S’applique à

Voir aussi