Skip to main content

SetEndStyle

Sets a line end style.

Syntax

expression.SetEndStyle(style);

expression - A variable that represents a ApiLineAnnotation class.

Parameters

NameRequired/OptionalData typeDefaultDescription
styleRequiredLineEndStyleNo description provided.

Returns

boolean

Example

This example sets end line style to line annotation.

let doc = Api.GetDocument();
let lineAnnot = Api.CreateLineAnnot([10, 10, 160, 32], {x: 15, y: 15}, {x: 155, y: 30});
lineAnnot.SetEndStyle("slash");
let page = doc.GetPage(0);
page.AddObject(lineAnnot);
console.log(`End style set to: ${lineAnnot.GetEndStyle()}`);