• Articles
  • API Documentation
Search Results for

    Show / Hide Table of Contents
    • SixLabors.ImageSharp.Drawing
      • ArcLineSegment
      • ClipPathExtensions
      • ClippingOperation
      • ComplexPolygon
      • CubicBezierLineSegment
      • EllipsePolygon
      • EmptyPath
      • EndCapStyle
      • ILineSegment
      • IPath
      • IPathCollection
      • ISimplePath
      • IntersectionRule
      • JointStyle
      • LinearLineSegment
      • OutlinePathExtensions
      • Path
      • PathBuilder
      • PathCollection
      • PathExtensions
      • PathTypes
      • Polygon
      • RectangularPolygon
      • RegularPolygon
      • SegmentInfo
      • Star
      • TextBuilder
    • SixLabors.ImageSharp.Drawing.Processing
      • Brush
      • BrushApplicator<TPixel>
      • Brushes
      • ClearExtensions
      • ClearPathExtensions
      • ClearRectangleExtensions
      • ClipPathExtensions
      • ColorStop
      • DrawBezierExtensions
      • DrawLineExtensions
      • DrawPathCollectionExtensions
      • DrawPathExtensions
      • DrawPolygonExtensions
      • DrawRectangleExtensions
      • DrawTextExtensions
      • DrawingOptions
      • DrawingOptionsDefaultsExtensions
      • EllipticGradientBrush
      • FillExtensions
      • FillPathBuilderExtensions
      • FillPathCollectionExtensions
      • FillPathExtensions
      • FillPolygonExtensions
      • FillRectangleExtensions
      • GradientBrush
      • GradientRepetitionMode
      • ImageBrush
      • LinearGradientBrush
      • PathGradientBrush
      • PatternBrush
      • PatternPen
      • Pen
      • PenOptions
      • Pens
      • RadialGradientBrush
      • RecolorBrush
      • RichTextOptions
      • RichTextRun
      • ShapeGraphicOptionsDefaultsExtensions
      • ShapeOptions
      • SolidBrush
      • SolidPen
    • SixLabors.ImageSharp.Drawing.Processing.Processors.Drawing
      • ClipPathProcessor
      • DrawPathProcessor
      • FillPathProcessor
      • FillProcessor
    • SixLabors.ImageSharp.Drawing.Processing.Processors.Text
      • DrawTextProcessor
    • SixLabors.ImageSharp.Drawing.Shapes.PolygonClipper
      • ClipperException
      • ClippingType

    Class GradientBrush

    Base class for Gradient brushes

    Inheritance
    object
    Brush
    GradientBrush
    EllipticGradientBrush
    LinearGradientBrush
    RadialGradientBrush
    Implements
    IEquatable<Brush>
    Inherited Members
    Brush.CreateApplicator<TPixel>(Configuration, GraphicsOptions, ImageFrame<TPixel>, RectangleF)
    Brush.Equals(object)
    object.Equals(object, object)
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: SixLabors.ImageSharp.Drawing.Processing
    Assembly: SixLabors.ImageSharp.Drawing.dll
    Syntax
    public abstract class GradientBrush : Brush, IEquatable<Brush>

    Constructors

    | Edit this page View Source

    GradientBrush(GradientRepetitionMode, params ColorStop[])

    Represents a logical configuration of a brush which can be used to source pixel colors.

    Declaration
    protected GradientBrush(GradientRepetitionMode repetitionMode, params ColorStop[] colorStops)
    Parameters
    Type Name Description
    GradientRepetitionMode repetitionMode

    Defines how the colors are repeated beyond the interval [0..1]

    ColorStop[] colorStops

    The gradient colors.

    Remarks

    A brush is a simple class that will return an BrushApplicator<TPixel> that will perform the logic for retrieving pixel values for specific locations.

    Properties

    | Edit this page View Source

    ColorStops

    Gets the list of color stops for this gradient.

    Declaration
    protected ColorStop[] ColorStops { get; }
    Property Value
    Type Description
    ColorStop[]
    | Edit this page View Source

    RepetitionMode

    Gets how the colors are repeated beyond the interval [0..1].

    Declaration
    protected GradientRepetitionMode RepetitionMode { get; }
    Property Value
    Type Description
    GradientRepetitionMode

    Methods

    | Edit this page View Source

    Equals(Brush?)

    Indicates whether the current object is equal to another object of the same type.

    Declaration
    public override bool Equals(Brush? other)
    Parameters
    Type Name Description
    Brush other

    An object to compare with this object.

    Returns
    Type Description
    bool

    true if the current object is equal to the other parameter; otherwise, false.

    Overrides
    Brush.Equals(Brush?)
    | Edit this page View Source

    GetHashCode()

    Serves as the default hash function.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    int

    A hash code for the current object.

    Overrides
    Brush.GetHashCode()

    Implements

    IEquatable<T>
    • Edit this page
    • View Source
    In this article
    Back to top Generated by DocFX