Esempio n. 1
0
 private void addStyleButton(StyleButton button)
 {
     StyleStackPanel.Children.Add(button);
     StyleWrapPanel.Children.Add(button.Clone());
 }
Esempio n. 2
0
        private void defineStyles()
        {
            StyleButton button;

            var color1 = Color.FromArgb(255, 31, 73, 125);

            button = new StyleButton(this, color1, BackgroundColorStyle.Radial, Colors.Black);
            addStyleButton(button);

            var color2 = Color.FromArgb(255, 247, 150, 70);

            button = new StyleButton(this, color2, BackgroundColorStyle.Radial, Colors.Black);
            addStyleButton(button);

            var color3 = Color.FromArgb(255, 192, 0, 0);

            button = new StyleButton(this, color3, BackgroundColorStyle.Radial, Colors.Black);
            addStyleButton(button);

            var color4 = Color.FromArgb(255, 255, 192, 0);

            button = new StyleButton(this, color4, BackgroundColorStyle.Radial, Colors.Black);
            addStyleButton(button);

            var color5 = Color.FromArgb(255, 79, 129, 189);

            button = new StyleButton(this, color5, BackgroundColorStyle.Radial, Colors.Black);
            addStyleButton(button);

            var color6 = Color.FromArgb(255, 155, 187, 89);

            button = new StyleButton(this, color6, BackgroundColorStyle.Radial, Colors.Black);
            addStyleButton(button);

            var color7 = Color.FromArgb(255, 128, 100, 162);

            button = new StyleButton(this, color7, BackgroundColorStyle.Radial, Colors.Black);
            addStyleButton(button);


            button = new StyleButton(this, color1, BackgroundColorStyle.Solid, Colors.White);
            addStyleButton(button);

            button = new StyleButton(this, color2, BackgroundColorStyle.Solid, Colors.Black);
            addStyleButton(button);

            button = new StyleButton(this, color3, BackgroundColorStyle.Solid, Colors.White);
            addStyleButton(button);

            button = new StyleButton(this, color4, BackgroundColorStyle.Solid, Colors.Black);
            addStyleButton(button);

            button = new StyleButton(this, color5, BackgroundColorStyle.Solid, Colors.White);
            addStyleButton(button);

            button = new StyleButton(this, color6, BackgroundColorStyle.Solid, Colors.White);
            addStyleButton(button);

            button = new StyleButton(this, color7, BackgroundColorStyle.Solid, Colors.White);
            addStyleButton(button);



            button = new StyleButton(this, color1, BackgroundColorStyle.TopLeftToBottomRight, Colors.White);
            addStyleButton(button);

            button = new StyleButton(this, Colors.White, BackgroundColorStyle.Solid, Colors.Black);
            addStyleButton(button);
        }