Skip to content
UniKit

Vertical text layout

Turn horizontal text into classical vertical columns: cells follow East Asian widths (fullwidth = 2 columns, halfwidth = 1 and right-aligned), with configurable characters per column or a fixed column count, punctuation on the top-right or centred, right-to-left or left-to-right column order and optional column dividers. Every output row has the same display width, so a monospaced font lines it up.

Runs in your browserEvery computation happens in your browser — your data never leaves this device.

Horizontal text

Each line break starts a new paragraph: paragraphs are laid out separately with a blank line between them. Inside a paragraph the text is split by characters per column or by a fixed column count, and every column is exactly 2 halfwidth cells wide.

Vertical result

Every row has the same display width (2 halfwidth cells per column, plus separators when enabled) so a monospaced font lines it up; missing cells are padded with spaces.

Enter text to see the vertical result

What this tool does

  • Lay out poems, couplets, signatures or short paragraphs as top-to-bottom, right-to-left vertical text that stays aligned in notes, documents and chat.
  • Prepare vertical copy for calligraphy or classical typesetting: split into columns first, then check that every column has the expected number of characters.
  • Use the result as a layout draft: switch punctuation position, column order and dividers to compare options quickly.

Example

Input

床前明月光,疑是地上霜。举头望明月,低头思故乡。

Output

举床
头前
望明
明月
月光
 , ,
低疑
头是
思地
故上
乡霜
 . .

Rendered with the defaults (12 characters per column, right-to-left, punctuation top-right): the 24 characters form 2 columns and every row is 4 halfwidth cells wide. Top-right punctuation turns fullwidth marks into halfwidth ones aligned to the right, so a Chinese comma appears as a halfwidth comma preceded by a space.

Frequently asked questions

Why are there extra spaces, and why is every row the same length?

One cell equals the width of an East Asian fullwidth character, i.e. 2 halfwidth columns. Ideographs, fullwidth punctuation, kana, Hangul and emoji fill a whole cell; narrow characters such as ASCII take 1 column and are right-aligned inside the cell with a leading space. Missing cells are padded with two spaces, so every row is exactly “columns × 2” halfwidth cells wide (plus one column per divider). A monospaced font lines it up; a proportional font will not.

What does the punctuation position change?

“Top-right” rewrites fullwidth marks as their halfwidth equivalents shifted to the right half of the cell, imitating classical Chinese punctuation that sits high and to the right; “centred” keeps the fullwidth marks filling the cell. Plain text has no vertical positioning, so this is a width-level approximation rather than real glyph placement.

How is right-to-left column order represented in plain text?

Rows are still written top to bottom, but the first column of the text is placed at the rightmost position of each row and later columns follow to the left, so you read right to left. “Left to right” puts the first column at the start of the row instead.

What happens if I set both a fixed column count and characters per column?

The fixed column count wins: the column height becomes ceil(characters ÷ columns) and the characters-per-column field is disabled. A count of 0 hands the decision back to characters per column, which means the last column may be shorter.

How are line breaks, blank lines and surrounding spaces handled?

Every line break starts a paragraph and paragraphs are separated by one blank line; a blank paragraph is just a blank line, so runs of blank lines collapse into one. Surrounding spaces are kept by default (a space is a cell too) — tick “trim each line and drop empty lines” to trim first. CRLF and lone CR are treated as line breaks and the output always uses LF.

Keywords:vertical textvertical layouttategakitxt-col

Related tools