LineFormat

LineFormat class

Represents all setting of the line.

Properties

NameTypeDescription
CompoundTypeNumberSpecifies the line compound type. The value of the property is MsoLineStyle integer constant.
DashStyleNumberSpecifies the line dash type. The value of the property is MsoLineDashStyle integer constant.
CapTypeNumberSpecifies the ending caps. The value of the property is LineCapType integer constant.
JoinTypeNumberSpecifies the line join type. The value of the property is LineJoinType integer constant.
BeginArrowheadStyleNumberGets and sets the begin arrow type of the line. The value of the property is MsoArrowheadStyle integer constant.
BeginArrowheadWidthNumberGets and sets the begin arrow width type of the line. The value of the property is MsoArrowheadWidth integer constant.
BeginArrowheadLengthNumberGets and sets the begin arrow length type of the line. The value of the property is MsoArrowheadLength integer constant.
EndArrowheadStyleNumberGets and sets the end arrow type of the line. The value of the property is MsoArrowheadStyle integer constant.
EndArrowheadWidthNumberGets and sets the end arrow width type of the line. The value of the property is MsoArrowheadWidth integer constant.
EndArrowheadLengthNumberGets and sets the end arrow length type of the line. The value of the property is MsoArrowheadLength integer constant.
WeightNumberGets or sets the weight of the line in unit of points.
TypeNumberGets and sets the fill type. The value of the property is FillType integer constant. NOTE: This member is now obsolete.
FillTypeNumberGets and sets fill type The value of the property is FillType integer constant.
TransparencyNumberReturns or sets the degree of transparency of the area as a value from 0.0 (opaque) through 1.0 (clear).
SetTypeNumberGets the fill format set type. The value of the property is FormatSetType integer constant. NOTE: This member is now obs
GradientFillGradientFillGets GradientFill object.
TextureFillTextureFillGets TextureFill object.
SolidFillSolidFillGets SolidFill object.
PatternFillPatternFillGets PatternFill object.
GradientColorTypeNumberReturns the gradient color type for the specified fill. The value of the property is GradientColorType integer constant.
GradientStyleNumberReturns the gradient style for the specified fill. The value of the property is GradientStyleType integer constant.
GradientColor1ColorReturns the gradient color 1 for the specified fill.
GradientColor2ColorReturns the gradient color 2 for the specified fill. Only when the gradient color type is GradientColorType.TwoColors, t
GradientDegreeNumberReturns the gradient degree for the specified fill. Only applies for Excel 2007. Can only be a value from 0.0 (dark) thr
GradientVariantNumberReturns the gradient variant for the specified fill. Only applies for Excel 2007. Can only be a value from 1 through 4,
PresetColorNumberReturns the gradient preset color for the specified fill. The value of the property is GradientPresetType integer consta
TextureNumberRepresents the texture type for the specified fill. The value of the property is TextureType integer constant.
PatternNumberRepresents an area’s display pattern. The value of the property is FillPattern integer constant.
PictureFormatTypeNumberGets and sets the picture format type. The value of the property is FillPictureType integer constant.
ScaleNumberGets and sets the picture format scale.
ImageDatabyte[]Gets and sets the picture image data. If the fill format is not custom texture format, returns null.

Methods

NameDescription
hashCodeGets the hash code.
equalsDetermines whether this instance has the same value as another specified LineFormat object.
setOneColorGradientSets the specified fill to a one-color gradient. Only applies for Excel 2007.
setTwoColorGradientSets the specified fill to a two-color gradient. Only applies for Excel 2007.
setPresetColorGradientSets the specified fill to a preset-color gradient. Only applies for Excel 2007.

LineFormat.CompoundType property

Specifies the line compound type. The value of the property is MsoLineStyle integer constant.

Type: Number

LineFormat.DashStyle property

Specifies the line dash type. The value of the property is MsoLineDashStyle integer constant.

Type: Number

LineFormat.CapType property

Specifies the ending caps. The value of the property is LineCapType integer constant.

Type: Number

LineFormat.JoinType property

Specifies the line join type. The value of the property is LineJoinType integer constant.

Type: Number

LineFormat.BeginArrowheadStyle property

Gets and sets the begin arrow type of the line. The value of the property is MsoArrowheadStyle integer constant.

Type: Number

LineFormat.BeginArrowheadWidth property

Gets and sets the begin arrow width type of the line. The value of the property is MsoArrowheadWidth integer constant.

Type: Number

LineFormat.BeginArrowheadLength property

Gets and sets the begin arrow length type of the line. The value of the property is MsoArrowheadLength integer constant.

Type: Number

LineFormat.EndArrowheadStyle property

Gets and sets the end arrow type of the line. The value of the property is MsoArrowheadStyle integer constant.

Type: Number

LineFormat.EndArrowheadWidth property

Gets and sets the end arrow width type of the line. The value of the property is MsoArrowheadWidth integer constant.

Type: Number

LineFormat.EndArrowheadLength property

Gets and sets the end arrow length type of the line. The value of the property is MsoArrowheadLength integer constant.

Type: Number

LineFormat.Weight property

Gets or sets the weight of the line in unit of points.

Type: Number

LineFormat.Type property

Gets and sets the fill type. The value of the property is FillType integer constant. NOTE: This member is now obsolete. Instead, please use FillFormat.FillType property instead. This property will be removed 12 months later since July 2016. Aspose apologizes for any inconvenience you may have experienced.

Type: Number

LineFormat.FillType property

Gets and sets fill type The value of the property is FillType integer constant.

Type: Number

LineFormat.Transparency property

Returns or sets the degree of transparency of the area as a value from 0.0 (opaque) through 1.0 (clear).

Type: Number

LineFormat.SetType property

Gets the fill format set type. The value of the property is FormatSetType integer constant. NOTE: This member is now obsolete. Instead, please use FillFormat.FillType property instead. This property will be removed 12 months later since July 2016. Aspose apologizes for any inconvenience you may have experienced.

Type: Number

LineFormat.GradientFill property

Gets GradientFill object.

Type: GradientFill

LineFormat.TextureFill property

Gets TextureFill object.

Type: TextureFill

LineFormat.SolidFill property

Gets SolidFill object.

Type: SolidFill

LineFormat.PatternFill property

Gets PatternFill object.

Type: PatternFill

LineFormat.GradientColorType property

Returns the gradient color type for the specified fill. The value of the property is GradientColorType integer constant.

Type: Number

LineFormat.GradientStyle property

Returns the gradient style for the specified fill. The value of the property is GradientStyleType integer constant.

Type: Number

LineFormat.GradientColor1 property

Returns the gradient color 1 for the specified fill.

Type: Color

LineFormat.GradientColor2 property

Returns the gradient color 2 for the specified fill. Only when the gradient color type is GradientColorType.TwoColors, this property is meaningful.

Type: Color

LineFormat.GradientDegree property

Returns the gradient degree for the specified fill. Only applies for Excel 2007. Can only be a value from 0.0 (dark) through 1.0 (light).

Type: Number

LineFormat.GradientVariant property

Returns the gradient variant for the specified fill. Only applies for Excel 2007. Can only be a value from 1 through 4, corresponding to one of the four variants on the Gradient tab in the Fill Effects dialog box. If style is GradientStyle.FromCenter, the Variant argument can only be 1 or 2.

Type: Number

LineFormat.PresetColor property

Returns the gradient preset color for the specified fill. The value of the property is GradientPresetType integer constant.

Type: Number

LineFormat.Texture property

Represents the texture type for the specified fill. The value of the property is TextureType integer constant.

Type: Number

LineFormat.Pattern property

Represents an area’s display pattern. The value of the property is FillPattern integer constant.

Type: Number

LineFormat.PictureFormatType property

Gets and sets the picture format type. The value of the property is FillPictureType integer constant.

Type: Number

LineFormat.Scale property

Gets and sets the picture format scale.

Type: Number

LineFormat.ImageData property

Gets and sets the picture image data. If the fill format is not custom texture format, returns null.

Type: byte[]

hashCode()

Gets the hash code.

equals(obj)

Determines whether this instance has the same value as another specified LineFormat object.

ParameterTypeDescription
objObjectThe LineFormat object to compare with this instance.

Returns: true if the value of the obj parameter is the same as the value of this instance; otherwise, false. If obj is null, this method returns false.

setOneColorGradient(color, degree, style, variant)

Sets the specified fill to a one-color gradient. Only applies for Excel 2007.

ParameterTypeDescription
colorColorOne gradient color.
degreeNumberThe gradient degree. Can be a value from 0.0 (dark) through 1.0 (light).
styleNumberA GradientStyleType value. Gradient shading style.
variantNumberThe gradient variant. Can be a value from 1 through 4, corresponding to one of the four variants on the Gradient tab in the Fill Effects dialog box. If style is GradientStyle.FromCenter, the Variant argument can only be 1 or 2.

setTwoColorGradient(color1, color2, style, variant) (1 of 2)

Sets the specified fill to a two-color gradient. Only applies for Excel 2007.

ParameterTypeDescription
color1ColorOne gradient color.
color2ColorTwo gradient color.
styleNumberA GradientStyleType value. Gradient shading style.
variantNumberThe gradient variant. Can be a value from 1 through 4, corresponding to one of the four variants on the Gradient tab in the Fill Effects dialog box. If style is GradientStyle.FromCenter, the Variant argument can only be 1 or 2.

setTwoColorGradient(color1, transparency1, color2, transparency2, style, variant) (2 of 2)

Sets the specified fill to a two-color gradient. Only applies for Excel 2007.

ParameterTypeDescription
color1ColorOne gradient color.
transparency1NumberThe degree of transparency of the color1 as a value from 0.0 (opaque) through 1.0 (clear).
color2ColorTwo gradient color.
transparency2NumberThe degree of transparency of the color2 as a value from 0.0 (opaque) through 1.0 (clear).
styleNumberA GradientStyleType value. Gradient shading style.
variantNumberThe gradient variant. Can be a value from 1 through 4, corresponding to one of the four variants on the Gradient tab in the Fill Effects dialog box. If style is GradientStyle.FromCenter, the Variant argument can only be 1 or 2.

setPresetColorGradient(presetColor, style, variant)

Sets the specified fill to a preset-color gradient. Only applies for Excel 2007.

ParameterTypeDescription
presetColorNumberA GradientPresetType value. Preset color type
styleNumberA GradientStyleType value. Gradient shading style.
variantNumberThe gradient variant. Can be a value from 1 through 4, corresponding to one of the four variants on the Gradient tab in the Fill Effects dialog box. If style is GradientStyle.FromCenter, the Variant argument can only be 1 or 2.