LineFormat
LineFormat class
Represents all setting of the line.
class LineFormat extends FillFormat;
Constructors
Name | Description |
---|---|
constructor(FillFormat) | Constructs from a parent object convertible to this. |
Methods
Method | Description |
---|---|
getCompoundType() | Specifies the line compound type. |
setCompoundType(MsoLineStyle) | Specifies the line compound type. |
getDashStyle() | Specifies the line dash type. |
setDashStyle(MsoLineDashStyle) | Specifies the line dash type. |
getCapType() | Specifies the ending caps. |
setCapType(LineCapType) | Specifies the ending caps. |
getJoinType() | Specifies the line join type. |
setJoinType(LineJoinType) | Specifies the line join type. |
getBeginArrowheadStyle() | Gets and sets the begin arrow type of the line. |
setBeginArrowheadStyle(MsoArrowheadStyle) | Gets and sets the begin arrow type of the line. |
getBeginArrowheadWidth() | Gets and sets the begin arrow width type of the line. |
setBeginArrowheadWidth(MsoArrowheadWidth) | Gets and sets the begin arrow width type of the line. |
getBeginArrowheadLength() | Gets and sets the begin arrow length type of the line. |
setBeginArrowheadLength(MsoArrowheadLength) | Gets and sets the begin arrow length type of the line. |
getEndArrowheadStyle() | Gets and sets the end arrow type of the line. |
setEndArrowheadStyle(MsoArrowheadStyle) | Gets and sets the end arrow type of the line. |
getEndArrowheadWidth() | Gets and sets the end arrow width type of the line. |
setEndArrowheadWidth(MsoArrowheadWidth) | Gets and sets the end arrow width type of the line. |
getEndArrowheadLength() | Gets and sets the end arrow length type of the line. |
setEndArrowheadLength(MsoArrowheadLength) | Gets and sets the end arrow length type of the line. |
getWeight() | Gets or sets the weight of the line in unit of points. |
setWeight(number) | Gets or sets the weight of the line in unit of points. |
getHashCode() | Gets the hash code. |
equals(object) | Determines whether this instance has the same value as another specified LineFormat object. |
isNull() | Checks whether the implementation object is null. |
getFillType() | Gets and sets fill type |
setFillType(FillType) | Gets and sets fill type |
getTransparency() | Returns or sets the degree of transparency of the area as a value from 0.0 (opaque) through 1.0 (clear). |
setTransparency(number) | Returns or sets the degree of transparency of the area as a value from 0.0 (opaque) through 1.0 (clear). |
getGradientFill() | Gets GradientFill object. |
getTextureFill() | Gets TextureFill object. |
getSolidFill() | Gets SolidFill object. |
getPatternFill() | Gets PatternFill object. |
getGradientColorType() | Returns the gradient color type for the specified fill. |
getGradientStyle() | Returns the gradient style for the specified fill. |
getGradientColor1() | Returns the gradient color 1 for the specified fill. |
getGradientColor2() | Returns the gradient color 2 for the specified fill. |
getGradientDegree() | Returns the gradient degree for the specified fill. Only applies for Excel 2007. |
getGradientVariant() | Returns the gradient variant for the specified fill. Only applies for Excel 2007. |
getPresetColor() | Returns the gradient preset color for the specified fill. |
getTexture() | Represents the texture type for the specified fill. |
setTexture(TextureType) | Represents the texture type for the specified fill. |
getPattern() | Represents an area’s display pattern. |
setPattern(FillPattern) | Represents an area’s display pattern. |
getPictureFormatType() | Gets and sets the picture format type. |
setPictureFormatType(FillPictureType) | Gets and sets the picture format type. |
getScale() | Gets and sets the picture format scale. |
setScale(number) | Gets and sets the picture format scale. |
getImageData() | Gets and sets the picture image data. |
setImageData(number[]) | Gets and sets the picture image data. |
setOneColorGradient(Color, number, GradientStyleType, number) | Sets the specified fill to a one-color gradient. Only applies for Excel 2007. |
setTwoColorGradient(Color, Color, GradientStyleType, number) | Sets the specified fill to a two-color gradient. Only applies for Excel 2007. |
setTwoColorGradient(Color, number, Color, number, GradientStyleType, number) | Sets the specified fill to a two-color gradient. Only applies for Excel 2007. |
setPresetColorGradient(GradientPresetType, GradientStyleType, number) | Sets the specified fill to a preset-color gradient. Only applies for Excel 2007. |
constructor(FillFormat)
Constructs from a parent object convertible to this.
constructor(obj: FillFormat);
Parameters:
Parameter | Type | Description |
---|---|---|
obj | FillFormat | The parent object. |
getCompoundType()
Specifies the line compound type.
getCompoundType() : MsoLineStyle;
Returns
setCompoundType(MsoLineStyle)
Specifies the line compound type.
setCompoundType(value: MsoLineStyle) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoLineStyle | The value to set. |
getDashStyle()
Specifies the line dash type.
getDashStyle() : MsoLineDashStyle;
Returns
setDashStyle(MsoLineDashStyle)
Specifies the line dash type.
setDashStyle(value: MsoLineDashStyle) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoLineDashStyle | The value to set. |
getCapType()
Specifies the ending caps.
getCapType() : LineCapType;
Returns
setCapType(LineCapType)
Specifies the ending caps.
setCapType(value: LineCapType) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | LineCapType | The value to set. |
getJoinType()
Specifies the line join type.
getJoinType() : LineJoinType;
Returns
setJoinType(LineJoinType)
Specifies the line join type.
setJoinType(value: LineJoinType) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | LineJoinType | The value to set. |
getBeginArrowheadStyle()
Gets and sets the begin arrow type of the line.
getBeginArrowheadStyle() : MsoArrowheadStyle;
Returns
setBeginArrowheadStyle(MsoArrowheadStyle)
Gets and sets the begin arrow type of the line.
setBeginArrowheadStyle(value: MsoArrowheadStyle) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoArrowheadStyle | The value to set. |
getBeginArrowheadWidth()
Gets and sets the begin arrow width type of the line.
getBeginArrowheadWidth() : MsoArrowheadWidth;
Returns
setBeginArrowheadWidth(MsoArrowheadWidth)
Gets and sets the begin arrow width type of the line.
setBeginArrowheadWidth(value: MsoArrowheadWidth) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoArrowheadWidth | The value to set. |
getBeginArrowheadLength()
Gets and sets the begin arrow length type of the line.
getBeginArrowheadLength() : MsoArrowheadLength;
Returns
setBeginArrowheadLength(MsoArrowheadLength)
Gets and sets the begin arrow length type of the line.
setBeginArrowheadLength(value: MsoArrowheadLength) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoArrowheadLength | The value to set. |
getEndArrowheadStyle()
Gets and sets the end arrow type of the line.
getEndArrowheadStyle() : MsoArrowheadStyle;
Returns
setEndArrowheadStyle(MsoArrowheadStyle)
Gets and sets the end arrow type of the line.
setEndArrowheadStyle(value: MsoArrowheadStyle) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoArrowheadStyle | The value to set. |
getEndArrowheadWidth()
Gets and sets the end arrow width type of the line.
getEndArrowheadWidth() : MsoArrowheadWidth;
Returns
setEndArrowheadWidth(MsoArrowheadWidth)
Gets and sets the end arrow width type of the line.
setEndArrowheadWidth(value: MsoArrowheadWidth) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoArrowheadWidth | The value to set. |
getEndArrowheadLength()
Gets and sets the end arrow length type of the line.
getEndArrowheadLength() : MsoArrowheadLength;
Returns
setEndArrowheadLength(MsoArrowheadLength)
Gets and sets the end arrow length type of the line.
setEndArrowheadLength(value: MsoArrowheadLength) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | MsoArrowheadLength | The value to set. |
getWeight()
Gets or sets the weight of the line in unit of points.
getWeight() : number;
setWeight(number)
Gets or sets the weight of the line in unit of points.
setWeight(value: number) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | number | The value to set. |
getHashCode()
Gets the hash code.
getHashCode() : number;
equals(object)
Determines whether this instance has the same value as another specified LineFormat object.
equals(obj: object) : boolean;
Parameters:
Parameter | Type | Description |
---|---|---|
obj | object | The 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.
isNull()
Checks whether the implementation object is null.
isNull() : boolean;
getFillType()
Gets and sets fill type
getFillType() : FillType;
Returns
setFillType(FillType)
Gets and sets fill type
setFillType(value: FillType) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | FillType | The value to set. |
getTransparency()
Returns or sets the degree of transparency of the area as a value from 0.0 (opaque) through 1.0 (clear).
getTransparency() : number;
setTransparency(number)
Returns or sets the degree of transparency of the area as a value from 0.0 (opaque) through 1.0 (clear).
setTransparency(value: number) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | number | The value to set. |
getGradientFill()
Gets GradientFill object.
getGradientFill() : GradientFill;
Returns
getTextureFill()
Gets TextureFill object.
getTextureFill() : TextureFill;
Returns
getSolidFill()
Gets SolidFill object.
getSolidFill() : SolidFill;
Returns
getPatternFill()
Gets PatternFill object.
getPatternFill() : PatternFill;
Returns
getGradientColorType()
Returns the gradient color type for the specified fill.
getGradientColorType() : GradientColorType;
Returns
getGradientStyle()
Returns the gradient style for the specified fill.
getGradientStyle() : GradientStyleType;
Returns
getGradientColor1()
Returns the gradient color 1 for the specified fill.
getGradientColor1() : Color;
Returns
getGradientColor2()
Returns the gradient color 2 for the specified fill.
getGradientColor2() : Color;
Returns
Remarks
Only when the gradient color type is GradientColorType.TwoColors, this property is meaningful.
getGradientDegree()
Returns the gradient degree for the specified fill. Only applies for Excel 2007.
getGradientDegree() : number;
Remarks
Can only be a value from 0.0 (dark) through 1.0 (light).
getGradientVariant()
Returns the gradient variant for the specified fill. Only applies for Excel 2007.
getGradientVariant() : number;
Remarks
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.
getPresetColor()
Returns the gradient preset color for the specified fill.
getPresetColor() : GradientPresetType;
Returns
getTexture()
Represents the texture type for the specified fill.
getTexture() : TextureType;
Returns
setTexture(TextureType)
Represents the texture type for the specified fill.
setTexture(value: TextureType) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | TextureType | The value to set. |
getPattern()
Represents an area’s display pattern.
getPattern() : FillPattern;
Returns
setPattern(FillPattern)
Represents an area’s display pattern.
setPattern(value: FillPattern) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | FillPattern | The value to set. |
getPictureFormatType()
Gets and sets the picture format type.
getPictureFormatType() : FillPictureType;
Returns
setPictureFormatType(FillPictureType)
Gets and sets the picture format type.
setPictureFormatType(value: FillPictureType) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | FillPictureType | The value to set. |
getScale()
Gets and sets the picture format scale.
getScale() : number;
setScale(number)
Gets and sets the picture format scale.
setScale(value: number) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | number | The value to set. |
getImageData()
Gets and sets the picture image data.
getImageData() : number[];
Returns
number[]
Remarks
If the fill format is not custom texture format, returns null.
setImageData(number[])
Gets and sets the picture image data.
setImageData(value: number[]) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
value | number[] | The value to set. |
Remarks
If the fill format is not custom texture format, returns null.
setOneColorGradient(Color, number, GradientStyleType, number)
Sets the specified fill to a one-color gradient. Only applies for Excel 2007.
setOneColorGradient(color: Color, degree: number, style: GradientStyleType, variant: number) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
color | Color | One gradient color. |
degree | number | The gradient degree. Can be a value from 0.0 (dark) through 1.0 (light). |
style | GradientStyleType | Gradient shading style. |
variant | number | The 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(Color, Color, GradientStyleType, number)
Sets the specified fill to a two-color gradient. Only applies for Excel 2007.
setTwoColorGradient(color1: Color, color2: Color, style: GradientStyleType, variant: number) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
color1 | Color | One gradient color. |
color2 | Color | Two gradient color. |
style | GradientStyleType | Gradient shading style. |
variant | number | The 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(Color, number, Color, number, GradientStyleType, number)
Sets the specified fill to a two-color gradient. Only applies for Excel 2007.
setTwoColorGradient(color1: Color, transparency1: number, color2: Color, transparency2: number, style: GradientStyleType, variant: number) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
color1 | Color | One gradient color. |
transparency1 | number | The degree of transparency of the color1 as a value from 0.0 (opaque) through 1.0 (clear). |
color2 | Color | Two gradient color. |
transparency2 | number | The degree of transparency of the color2 as a value from 0.0 (opaque) through 1.0 (clear). |
style | GradientStyleType | Gradient shading style. |
variant | number | The 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(GradientPresetType, GradientStyleType, number)
Sets the specified fill to a preset-color gradient. Only applies for Excel 2007.
setPresetColorGradient(presetColor: GradientPresetType, style: GradientStyleType, variant: number) : void;
Parameters:
Parameter | Type | Description |
---|---|---|
presetColor | GradientPresetType | Preset color type |
style | GradientStyleType | Gradient shading style. |
variant | number | The 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. |