public override FrameworkElement CreateIcon() { double a = 0.2, b = 0.4, c = 0.6, d = 0.8; return(IconBuilder.BuildIcon() .Polygon( Factory.CreateLinearGradient( Color.FromArgb(255, 200, 255, 0), Color.FromArgb(255, 255, 255, 0), 90), new SolidColorBrush(Colors.Black), new Point(a, b), new Point(b, b), new Point(b, a), new Point(c, a), new Point(c, b), new Point(d, b), new Point(d, c), new Point(c, c), new Point(c, d), new Point(b, d), new Point(b, c), new Point(a, c)) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Polygon( new SolidColorBrush(Color.FromArgb(255, 200, 200, 128)), new SolidColorBrush(Colors.Black), new Point(0.68, 0.98), new Point(1.01, 0.63), new Point(0.875, 0.166), new Point(0.401, 0.055), new Point(0.068, 0.409), new Point(0.208, 0.874)) .Line(0.68, 0.98, 1.01, 0.63) .Line(1.01, 0.63, 0.875, 0.166) .Line(0.875, 0.166, 0.401, 0.055) .Line(0.401, 0.055, 0.068, 0.409) .Line(0.068, 0.409, 0.208, 0.874) .Line(0.208, 0.874, 0.68, 0.98) .Point(0.68, 0.98) .Point(1.01, 0.63) .Point(0.875, 0.166) .Point(0.401, 0.055) .DependentPoint(0.068, 0.409) .Point(0.208, 0.874) .DependentPoint(0.55, 0.5) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Line(0.25, 0.75, 0.75, 0.25) .Polygon(Brushes.Black, Brushes.Black, new Point(0.75, 0.25), new Point(0.5, 0.4), new Point(0.6, 0.5)) .Canvas); }
public static FrameworkElement GetIcon() { #if TABULAPLAYER return(null); // never used and my player excludes IconBuilder #else var builder = IconBuilder .BuildIcon() .Polygon( new SolidColorBrush(Colors.Blue), new SolidColorBrush(Colors.Blue), new Point(0.5, 0), new Point(0.4, 0.2), new Point(0.6, 0.2)) .Polygon( new SolidColorBrush(Colors.Blue), new SolidColorBrush(Colors.Blue), new Point(1, 0.5), new Point(0.8, 0.4), new Point(0.8, 0.6)) .Line(Color.FromArgb(255, 0, 0, 255), 0.5, 0, 0.5, 1) .Line(Color.FromArgb(255, 0, 0, 255), 0, 0.5, 1, 0.5); for (double i = 0.1; i < 1; i += 0.2) { builder.Line(Color.FromArgb(100, 0, 0, 255), i, 0, i, 1); builder.Line(Color.FromArgb(100, 0, 0, 255), 0, i, 1, i); } return(builder.Canvas); #endif }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Line(0, 0, 1, 1) .Line(0.3, 1, 1, 0.3) .Point(0.35, 0.35) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Circle(0.5, 0.5, 0.5) .Point(0.5, 0.5) .Point(0.85, 0.15) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Line(0.25, 0.75, 1, 0) .Point(0.25, 0.75) .Point(0.75, 0.25) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Point(0.25, 0.75) .DependentPoint(0.5, 0.5) .Point(0.75, 0.25) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Ellipse(0.5, 0.5, 0.5, 0.3) .Point(0.5, 0.5) .Point(1.0, 0.5) .Point(0.5, 0.2) .Canvas); }
public override FrameworkElement CreateIcon() { const double r = 0.4; return(IconBuilder.BuildIcon() .Arc(0.5, 0.5, 0.5 + r, 0.5, 0.5, 0.5 - r) .Point(0.5, 0.5 - r) .Point(0.5, 0.5) .Point(0.5 + r, 0.5) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Bezier(0, 0.75, 0, 0, 0.5, 1, 1, 0) //.Line(0, 0, 0, 0.75) //.Line(0.5, 1, 1, 0) //.Point(0, 0) //.Point(0, 0.75) //.Point(1, 0) //.Point(0.5, 1) .Canvas); }
public override FrameworkElement CreateIcon() { const double r = 0.4; return(IconBuilder.BuildIcon() .Circle(r, r, r) .Line(0.5, 0.9, 0.5 + r, 0.9) .Point(r, r) .Point(0.5, 0.9) .Point(0.5 + r, 0.9) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder .BuildIcon() .Polygon( Factory.CreateDefaultFillBrush(), new SolidColorBrush(Colors.Black), new Point(0.2, 0.9), new Point(0.5, 0.1), new Point(0.9, 0.9)) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder .BuildIcon() .Line(0.1, 0.3, 0.4, 0.7) .Line(0.4, 0.7, 0.7, 0.3) .Line(0.7, 0.3, 1.0, 0.7) .Point(1.0, 0.7) .Point(0.7, 0.3) .Point(0.1, 0.3) .Point(0.4, 0.7) .Canvas); }
public override FrameworkElement CreateIcon() { const double a = 0.4; // semi-major const double b = 0.8; // semi-minor Size s = new Size(a, b); return(IconBuilder.BuildIcon() .EllipseArc(0.5, 0.9, 0.5 + a, 0.9, 0.5, 0.9 - b, s, 0) .Point(0.5, 0.9) .Point(0.5 + a, 0.9) .Point(0.5, 0.9 - b) .Canvas); }
public override FrameworkElement CreateIcon() { const double a = 0.9, b = 0.1; var builder = IconBuilder.BuildIcon() .Line(a, a, b, a) .Line(b, a, b, b) .Line(a, b, b, a) .Arc(b, a, 0.4, a, b, 0.6) .Point(a, a) .Point(b, a) .Point(b, b); return(builder.Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Point(0.1, 0.9) .Polygon( new SolidColorBrush(Colors.Yellow), new SolidColorBrush(Colors.Black), new Point(0.3, 0.9), new Point(0.9, 0.9), new Point(0.9, 0.6)) .Polygon( new SolidColorBrush(Color.FromArgb(255, 128, 255, 128)), new SolidColorBrush(Colors.Black), new Point(0.24, 0.06), new Point(0.5, 0.21), new Point(0.2, 0.73)) .Canvas); }
public override FrameworkElement CreateIcon() { return(IconBuilder.BuildIcon() .Line(0.5, 0, 0.5, 1) .Polygon( new SolidColorBrush(Colors.Yellow), new SolidColorBrush(Colors.Black), new Point(0.4, 0.2), new Point(0.4, 0.9), new Point(0, 0.9)) .Polygon( new SolidColorBrush(Color.FromArgb(255, 128, 255, 128)), new SolidColorBrush(Colors.Black), new Point(0.6, 0.2), new Point(0.6, 0.9), new Point(1, 0.9)) .Canvas); }
public override FrameworkElement CreateIcon() { var builder = IconBuilder.BuildIcon(); var size = IconBuilder.IconSize; var centerX = (size - 4) / (2 * size); var centerY = 1 - 4 / size; builder.Line(centerX, centerY, 0.8, 0.2) .Line(centerX, centerY, 1, centerY); var xaml = string.Format(@" <Path xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation' Stroke='Black' StrokeThickness='1' Fill='#33FF33' Data='m 0,{0} v-4 a {1},{1} 0 0 1 {2},0 v4 z m {4},-5 a 6,6 0 0 1 {3},0 z' />", size, (size - 4) / 2, size - 4, size / 2, (size - 4) / 4 - 1); #if SILVERLIGHT var path = XamlReader.Load(xaml) as Path; #else var path = XamlReader.Parse(xaml) as Path; #endif builder.Canvas.Children.Add(path); var radius = ((size - 4) / 2) * 0.95; var radiusSmall = radius * 0.8; Point center = new Point(radius + 1, size - 4); for (double i = 0; i < 16; i++) { var angle = i * Math.PI / 15; builder.Line((center.X + radius * M.Cos(angle)) / size, (center.Y - radius * M.Sin(angle)) / size, (center.X + radiusSmall * M.Cos(angle)) / size, (center.Y - radiusSmall * M.Sin(angle)) / size); } return(builder.Canvas); }
public override FrameworkElement CreateIcon() { double a = 0.2, b = 0.8; return(IconBuilder.BuildIcon() .Polygon( new SolidColorBrush(Color.FromArgb(255, 128, 255, 128)), new SolidColorBrush(Colors.Black), new Point(a, a), new Point(b, a), new Point(b, b), new Point(a, b)) .Line(a, a, b, a) .Line(b, a, b, b) .Line(b, b, a, b) .Line(a, b, a, a) .DependentPoint(a, a) .DependentPoint(b, a) .Point(b, b) .Point(a, b) .Canvas); }
public override FrameworkElement CreateIcon() { var result = IconBuilder .BuildIcon() .Polygon( new SolidColorBrush(Color.FromArgb(255, 255, 200, 200)), new SolidColorBrush(Colors.Black), new Point(0.2, 0.4), new Point(0.3, 0.8), new Point(0.7, 0.8), new Point(0.8, 0.4), new Point(0.6, 0.2)); var text = new TextBlock() { Text = "S²" }; var canvas = result.Canvas; canvas.Children.Add(text); Canvas.SetLeft(text, canvas.Width / 2.0 - text.ActualWidth / 2.0); Canvas.SetTop(text, canvas.Height / 2.0 - text.ActualHeight / 2.0); return(canvas); }
public override FrameworkElement CreateIcon() { var builder = IconBuilder .BuildIcon() .Polygon( new SolidColorBrush(Colors.Yellow), new SolidColorBrush(Colors.Black), new Point(0.1, 0.8), new Point(0.3, 1), new Point(1, 0.3), new Point(0.8, 0.1)) .Line(0, 0.7, 0.7, 0); for (double i = 0.2; i <= 0.7; i += 0.1) { builder.Line(i, 0.9 - i, i + 0.1, 1 - i); } for (double i = 0.15; i <= 0.75; i += 0.1) { builder.Line(i, 0.9 - i, i + 0.05, 0.95 - i); } return(builder.Canvas); }
public override FrameworkElement CreateIcon() { Point[] points = { new Point(10, 5), new Point(10, 21), new Point(14, 17), new Point(18, 25), new Point(19, 25), new Point(20, 24), new Point(17, 17), new Point(17, 16), new Point(21, 16), new Point(10, 5) }; var builder = IconBuilder.BuildIcon(); var polygon = builder.AddPolygon( points.Select(p => new Point(p.X / 32, p.Y / 32))); polygon.Fill = new SolidColorBrush(Colors.White); polygon.Stroke = new SolidColorBrush(Colors.Black); return(builder.Canvas); }