Skip to content

HT — Horizontal Tab

Byte0x09
MnemonicHT
Otty support

Description

Advances the cursor to the next tab stop. Default tab stops are every 8 columns. Tab stops are set with HTS (ESC H) and cleared with CSI g.

If the cursor is past the last tab stop on the line, HT moves it to the right margin without wrapping.

Example

bash
printf 'col1\tcol2\tcol3\n'
  • HTS — set a tab stop at the current column.
  • CSI g — clear tab stops (omitted from the index here; rarely used).

Otty