Documentation

overlineElement
Question mark

Adds a line over text.

Example

#overline[A line over text.]
Preview

Parameters
Question mark

stroke
auto or length or color or gradient or stroke or tiling or dictionary
Settable
Question mark

How to stroke the line.

If set to auto, takes on the text's color and a thickness defined in the current font.

View example
#set text(fill: olive)
#overline(
  stroke: green.darken(20%),
  offset: -12pt,
  [The Forest Theme],
)
Preview

Default: auto

offset
auto or length
Settable
Question mark

The position of the line relative to the baseline. Read from the font tables if auto.

View example
#overline(offset: -1.2em)[
  The Tale Of A Faraway Line II
]
Preview

Default: auto

extent
length
Settable
Question mark

The amount by which to extend the line beyond (or within if negative) the content.

View example
#set overline(extent: 4pt)
#set underline(extent: 4pt)
#overline(underline[Typography Today])
Preview

Default: 0pt

evade
bool
Settable
Question mark

Whether the line skips sections in which it would collide with the glyphs.

View example
#overline(
  evade: false,
  offset: -7.5pt,
  stroke: 1pt,
  extent: 3pt,
  [Temple],
)
Preview

Default: true

background
bool
Settable
Question mark

Whether the line is placed behind the content it overlines.

View example
#set overline(stroke: (thickness: 1em, paint: maroon, cap: "round"))
#overline(background: true)[This is stylized.] \
#overline(background: false)[This is partially hidden.]
Preview

Default: false

body
content
Required Positional
Question mark

The content to add a line over.