How to have first line indent in a new paragraph after a math block?

You’re right, Typst currently only indents successive paragraphs, and doesn’t indent the first paragraph after block content. To work around this, you can use the h function (horizontal space function):

#set par(first-line-indent: 2em)
#lorem(30)
$ A xor B dot.circle C = D^2 mod F^2 $

#h(2em) New paragraph (now with indent)

Second paragraph (Indent appears)

If you only use one block equation at a time and a paragraph always follows a block equation, you can use a show rule to make this change for all paragraphs:

#set par(first-line-indent: 2em)

#show math.equation: it => {
  it
  if it.block {
    h(2em)
  }
}

#lorem(30)
$ A xor B dot.circle C = D^2 mod F^2 $

New paragraph (now with indent, even without `h` in front)

Second paragraph (Indent appears)
1 Like