TypstDocumentation

lineShowable
Question mark

A line from one point to another.

Example

#set page(height: 100pt)
#line(end: (50%, 50%))
Preview

Parameters
Question mark

start

The start point of the line. Must be an array of exactly two relative lengths.

end

The end point of the line. Must be an array of exactly two relative lengths.

length

The line's length. Mutually exclusive with end.

angle

The angle at which the line points away from the origin. Mutually exclusive with end.

stroke
lengthcolorstrokeSettable
Question mark

How to stroke the line. This can be:

#line(length: 100%, stroke: 2pt + red)
Preview