AccessText.Foreground Propriété

Définition

Obtient ou définit le Brush qui dessine le contenu de texte de l'élément.

public:
 property System::Windows::Media::Brush ^ Foreground { System::Windows::Media::Brush ^ get(); void set(System::Windows::Media::Brush ^ value); };
public System.Windows.Media.Brush Foreground { get; set; }
member this.Foreground : System.Windows.Media.Brush with get, set
Public Property Foreground As Brush

Valeur de propriété

Brush qui dessine le texte. La valeur par défaut est Black.

Exemples

L’exemple suivant montre comment définir des propriétés pour modifier l’apparence du texte dans un AccessText contrôle.

<TextBox Name="textBox2" Width="50" Height="30"/>
<Label Target="{Binding ElementName=textBox2}">
  <AccessText Background="Red" Foreground="DarkSlateBlue"    
              FontFamily="Arial Narrow" FontSize="16" FontStyle="Italic" 
              FontWeight="Bold">
    E_dit
  </AccessText>
</Label>

Remarques

Informations sur les propriétés de dépendance

Champ Identificateur ForegroundProperty
Propriétés de métadonnées définies sur true AffectsRender, SubPropertiesDoNotAffectRender, Inherits

S’applique à

Voir aussi