Show / Hide Table of Contents

Class HatchGradientPattern

Represents the hatch gradient pattern style.

Inheritance
System.Object
HatchPattern
HatchGradientPattern
Implements
System.ICloneable
Inherited Members
HatchPattern.Solid
HatchPattern.Line
HatchPattern.Net
HatchPattern.Dots
HatchPattern.Name
HatchPattern.Description
HatchPattern.Style
HatchPattern.Type
HatchPattern.Fill
HatchPattern.Origin
HatchPattern.Angle
HatchPattern.Scale
HatchPattern.LineDefinitions
HatchPattern.NamesFromFile(String)
HatchPattern.Load(String, String)
HatchPattern.Save(String)
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: netDxf.Entities
Assembly: CADability.dll
Syntax
public class HatchGradientPattern : HatchPattern, ICloneable
Remarks

Gradient patterns are only supported by AutoCad2004 and higher DXF versions. It will default to a solid pattern if saved as AutoCad2000.

Constructors

| Improve this Doc View Source

HatchGradientPattern()

Initializes a new instance of the HatchGradientPattern class as a default linear gradient.

Declaration
public HatchGradientPattern()
| Improve this Doc View Source

HatchGradientPattern(AciColor, AciColor, HatchGradientPatternType)

Initializes a new instance of the HatchGradientPattern class as a two color gradient.

Declaration
public HatchGradientPattern(AciColor color1, AciColor color2, HatchGradientPatternType type)
Parameters
Type Name Description
AciColor color1

Gradient AciColor 1.

AciColor color2

Gradient AciColor 2.

HatchGradientPatternType type

Gradient HatchGradientPatternType.

| Improve this Doc View Source

HatchGradientPattern(AciColor, AciColor, HatchGradientPatternType, String)

Initializes a new instance of the HatchGradientPattern class as a two color gradient.

Declaration
public HatchGradientPattern(AciColor color1, AciColor color2, HatchGradientPatternType type, string description)
Parameters
Type Name Description
AciColor color1

Gradient AciColor 1.

AciColor color2

Gradient AciColor 2.

HatchGradientPatternType type

Gradient HatchGradientPatternType.

System.String description

Description of the pattern (optional, this information is not saved in the DXF file). By default it will use the supplied name.

| Improve this Doc View Source

HatchGradientPattern(AciColor, Double, HatchGradientPatternType)

Initializes a new instance of the HatchGradientPattern class as a single color gradient.

Declaration
public HatchGradientPattern(AciColor color, double tint, HatchGradientPatternType type)
Parameters
Type Name Description
AciColor color

Gradient AciColor.

System.Double tint

Gradient tint.

HatchGradientPatternType type

Gradient HatchGradientPatternType.

| Improve this Doc View Source

HatchGradientPattern(AciColor, Double, HatchGradientPatternType, String)

Initializes a new instance of the HatchGradientPattern class as a single color gradient.

Declaration
public HatchGradientPattern(AciColor color, double tint, HatchGradientPatternType type, string description)
Parameters
Type Name Description
AciColor color

Gradient AciColor.

System.Double tint

Gradient tint.

HatchGradientPatternType type

Gradient HatchGradientPatternType.

System.String description

Description of the pattern (optional, this information is not saved in the DXF file). By default it will use the supplied name.

| Improve this Doc View Source

HatchGradientPattern(String)

Initializes a new instance of the HatchGradientPattern class as a default linear gradient.

Declaration
public HatchGradientPattern(string description)
Parameters
Type Name Description
System.String description

Description of the pattern (optional, this information is not saved in the DXF file). By default it will use the supplied name.

Properties

| Improve this Doc View Source

Centered

Gets or sets if the pattern is centered or not.

Declaration
public bool Centered { get; set; }
Property Value
Type Description
System.Boolean
Remarks

Each gradient has two definitions, shifted and unsifted. A shift value describes the blend of the two definitions that should be used. A value of 0.0 (false) means only the unsifted version should be used, and a value of 1.0 (true) means that only the shifted version should be used.

| Improve this Doc View Source

Color1

Gets or sets the gradient AciColor 1.

Declaration
public AciColor Color1 { get; set; }
Property Value
Type Description
AciColor
| Improve this Doc View Source

Color2

Gets or sets the gradient AciColor 2.

Declaration
public AciColor Color2 { get; set; }
Property Value
Type Description
AciColor
Remarks

If color 2 is defined, automatically the single color property will be set to false.

| Improve this Doc View Source

GradientType

Gets or set the gradient pattern HatchGradientPatternType.

Declaration
public HatchGradientPatternType GradientType { get; set; }
Property Value
Type Description
HatchGradientPatternType
| Improve this Doc View Source

SingleColor

Gets or sets the gradient pattern color type.

Declaration
public bool SingleColor { get; set; }
Property Value
Type Description
System.Boolean
| Improve this Doc View Source

Tint

Gets or sets the gradient pattern tint.

Declaration
public double Tint { get; set; }
Property Value
Type Description
System.Double
Remarks

It only applies to single color gradient patterns.

Methods

| Improve this Doc View Source

Clone()

Declaration
public override object Clone()
Returns
Type Description
System.Object
Overrides
HatchPattern.Clone()

Implements

System.ICloneable
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX