Ejemplo n.º 1
0
 public Gradient(
     List <Color> colors         = null,
     List <float> stops          = null,
     GradientTransform transform = null
     )
 {
     D.assert(colors != null);
     this.colors    = colors;
     this.stops     = stops;
     this.transform = transform;
 }
Ejemplo n.º 2
0
 public LinearGradient(
     AlignmentGeometry begin     = null,
     AlignmentGeometry end       = null,
     List <Color> colors         = null,
     List <float> stops          = null,
     TileMode tileMode           = TileMode.clamp,
     GradientTransform transform = null
     ) : base(colors: colors, stops: stops, transform: transform)
 {
     this.begin    = begin ?? Alignment.centerLeft;
     this.end      = end ?? Alignment.centerRight;
     this.tileMode = tileMode;
 }
Ejemplo n.º 3
0
 public SweepGradient(
     AlignmentGeometry center    = null,
     float startAngle            = 0.0f,
     float endAngle              = Mathf.PI * 2,
     List <Color> colors         = null,
     List <float> stops          = null,
     TileMode tileMode           = TileMode.clamp,
     GradientTransform transform = null
     ) : base(colors: colors, stops: stops, transform: transform)
 {
     this.center     = center ?? Alignment.center;
     this.startAngle = startAngle;
     this.endAngle   = endAngle;
     this.tileMode   = tileMode;
 }
Ejemplo n.º 4
0
 public RadialGradient(
     AlignmentGeometry center    = null,
     float radius                = 0.5f,
     List <Color> colors         = null,
     List <float> stops          = null,
     TileMode tileMode           = TileMode.clamp,
     AlignmentGeometry focal     = null,
     float focalRadius           = 0.0f,
     GradientTransform transform = null
     ) : base(colors: colors, stops: stops, transform: transform)
 {
     this.center      = center ?? Alignment.center;
     this.radius      = radius;
     this.tileMode    = tileMode;
     this.focal       = focal;
     this.focalRadius = focalRadius;
 }