Use RGB color to fill Rectangle : Color « Windows Presentation Foundation « VB.Net






Use RGB color to fill Rectangle

Use RGB color to fill Rectangle
      

<Window x:Class="WpfApplication1.Window1"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="WrapPanel" Height="300" Width="300">
    <WrapPanel Background="AliceBlue">
        <Rectangle Fill="#FF000000" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF111111" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF222222" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF333333" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF444444" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF555555" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF666666" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF777777" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF888888" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FF999999" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FFAAAAAA" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FFBBBBBB" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FFCCCCCC" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FFDDDDDD" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FFEEEEEE" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
        <Rectangle Fill="#FFFFFFFF" Height="50" Width="50" Stroke="Black" RadiusX="10" RadiusY="10" />
    </WrapPanel>
</Window>

   
    
    
    
    
    
  








Related examples in the same category

1.A Semi-Transparent ButtonA Semi-Transparent Button
2.Use RGB valued semi-transparent color to paint EllipseUse RGB valued semi-transparent color to paint Ellipse
3.Use RGB solid color to paint EllipseUse RGB solid color to paint Ellipse
4.Rainbow color Animation by GradientStops[index].offsetRainbow color Animation by GradientStops[index].offset
5.RadialGradient StarRadialGradient Star
6.ColorConverter and SolidColorBrushColorConverter and SolidColorBrush
7.Ellipse with explicit SolidColorBrushEllipse with explicit SolidColorBrush
8.Use System Colors in Your GraphicsUse System Colors in Your Graphics
9.Use Named color to paint RectangleUse Named color to paint Rectangle
10.Create semi-transparent colorCreate semi-transparent color
11.Three stops LinearGradientBrushThree stops LinearGradientBrush
12.Animating Color with ColorAnimationAnimating Color with ColorAnimation
13.From a Hex string using ColorConverterFrom a Hex string using ColorConverter
14.From ScRGB values in the Color structureFrom ScRGB values in the Color structure
15.From sRGB values in the Color strutcureFrom sRGB values in the Color strutcure
16.Using a LinearGradientBrushUsing a LinearGradientBrush
17.Multiple gradient stopsMultiple gradient stops
18.Numeric color valuesNumeric color values
19.From predefined color name in the Colors classFrom predefined color name in the Colors class
20.Using SystemColors in CodeUsing SystemColors in Code
21.using system colors to create gradientsusing system colors to create gradients