Gets or sets the brush used for painting the diagram background.
Namespace: MindFusion.Diagramming.Wpf
Assembly: MindFusion.Diagramming.Wpf
SyntaxC#
Copy Code
|
|---|
public Brush BackBrush { get; set; } |
Visual Basic
Copy Code
|
|---|
Public Property BackBrush As Brush |
An instance of a System.Windows.Media.Brush-derived class. The default is a solid brush initialized with Color.FromArgb(170, 170, 200).
RemarksThis property enables more spectacular background painting with effects such as gradients, textures and color patterns.
ExampleThe following sample paints the WpfDiagram's background with a gradient brush:
C#
Copy Code
|
|---|
| private void diagram_Loaded(object sender, RoutedEventArgs e) { diagram.BackBrush = new LinearGradientBrush( Colors.LightBlue, Colors.LightCyan, 30); } |
Visual Basic
Copy Code
|
|---|
| Private Sub diagram_Loaded(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) diagram.BackBrush = New LinearGradientBrush( _ Colors.LightBlue, Colors.LightCyan, 30) End Sub |
See Also