Compartilhar via


TextFormattingRunProperties.SetBackgroundBrush Method

Gets a new TextFormattingRunProperties with the properties of this one but with the background brush set to the specified brush.

Namespace:  Microsoft.VisualStudio.Text.Formatting
Assembly:  Microsoft.VisualStudio.Text.UI.Wpf (in Microsoft.VisualStudio.Text.UI.Wpf.dll)

Syntax

'Declaração
Public Function SetBackgroundBrush ( _
    brush As Brush _
) As TextFormattingRunProperties
public TextFormattingRunProperties SetBackgroundBrush(
    Brush brush
)
public:
TextFormattingRunProperties^ SetBackgroundBrush(
    Brush^ brush
)
member SetBackgroundBrush : 
        brush:Brush -> TextFormattingRunProperties 
public function SetBackgroundBrush(
    brush : Brush
) : TextFormattingRunProperties

Parameters

Return Value

Type: Microsoft.VisualStudio.Text.Formatting.TextFormattingRunProperties
The TextFormattingRunProperties.

Exceptions

Exception Condition
ArgumentNullException

brush is nulla null reference (Nothing in Visual Basic).

Remarks

The brush is frozen by this method.

.NET Framework Security

See Also

Reference

TextFormattingRunProperties Class

Microsoft.VisualStudio.Text.Formatting Namespace