> For the complete documentation index, see [llms.txt](https://docs.atfinity.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.atfinity.io/document-xml-adx/adx-elements/line.md).

# Line

The `<line>` can be used to display a line in a certain color.

It can be used both within [`<body>`](/document-xml-adx/adx-elements/body.md) (flowable context) and [`<template>`](/document-xml-adx/adx-elements/template.md) (drawable context).

## Examples

```xml
<template ...>
    <line
        x1="80mm"
        x2="215mm"
        y1="330mm"
        y2="270mm"
        color="black"
        width="25"
    />
</template>
```

## Attributes

#### `x1, x2, y1, y2`

Required if in a drawable context, e.g. header or footer. These are the coordinates of the two points to draw the line between.

#### `length`

Required in a flowable context, e.g. the body. Describes the length of the line. Supports %, e.g. `100%`. Defaults to `1`.

#### `width` (optional)

The thickness of the line. Defaults to `0.5`.

#### `color` (optional)

The color of the line. Can be a named color (e.g. `red`) or an RGB value. Defaults to `black`.

#### `align` (optional)

Alignment of the line in a flowable context: `left`, `right`, or `center`.

#### `class` (optional)

The style class to apply to the line.

#### `spaceBefore` (optional)

Space before the line in pt, mm or cm. Only applies in `<body>` context.

#### `spaceAfter` (optional)

Space after the line in pt, mm or cm. Only applies in `<body>` context.

<details>

<summary></summary>

</details>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.atfinity.io/document-xml-adx/adx-elements/line.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
