Quantcast
Channel: 2,000 Things You Should Know About WPF » Background
Browsing all 8 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

#192 – Setting a Control’s Properties Using Blend

You can set a control’s properties in either Blend or Visual Studio.  To set properties for a control from Blend, do the following: Open the window containing the control.  Left-click to select the...

View Article



Image may be NSFW.
Clik here to view.

#207 – Setting a Control’s Background Color

The Control class is a base class for all user interface elements that a user interacts with.  (This includes the Window class). Control includes a Background property that you can set to cause the...

View Article

Image may be NSFW.
Clik here to view.

#438 – Border Element Can Have a Background

You can use the Background property to specify a background color (or brush) for everything within a Border. <Border Margin="10" BorderBrush="DarkGray" BorderThickness="1" CornerRadius="4">...

View Article

Image may be NSFW.
Clik here to view.

#439 – Using a DropShadow with a Border, part II

I described earlier how you can use two sibling Border elements to end up with the effect of a Border with a DropShadow.  We did this because specifying a DropShadowEffect for a Border will lead to all...

View Article

Image may be NSFW.
Clik here to view.

#682 – Panel Elements Only Fire Mouse Events When Background Is Set

If you create an element derived from Panel, like Canvas, and wire up any of the mouse-related events, you’ll notice that you don’t see your events unless you’ve set the Background property of the...

View Article


Image may be NSFW.
Clik here to view.

#809 – You Can Use a Brush for a Control’s Background

A control’s Background property dictates how the background of the control is rendered.  It is set to an instance of a Brush object.  The two most common types of brushes are solid color brushes...

View Article

Image may be NSFW.
Clik here to view.

#811 – Setting Color Values in Code Based on System Colors

You can set the Foreground or Background properties of a control to a brush that will render the control using one of the predefined system colors.  The SystemColors class contains a number of static...

View Article

Image may be NSFW.
Clik here to view.

#1,046 – Setting the Background Color of a Cell in a Grid

There are several different ways to set the background color of a cell within a Grid.  They include: Setting the Background property of the element within a cell (e.g. a Label) Including a Rectangle in...

View Article

Browsing all 8 articles
Browse latest View live




Latest Images