Convert T2T to PNG
Turn T2T files into PNG files. Typeset in Libertinus Serif with code in DejaVu Sans Mono on A4 pages unless page_size says letter, with headings, lists, tables, links and footnotes.
Converted in an isolated sandbox on our serversDeleted after 24 hours
Drop T2T files on the dialor turn it to pick what to do
Typeset pages from a txt2tags file.Each page of the document becomes one PNG, laid out on A4 by default.
What you get
The document is typeset in Libertinus Serif, with code in DejaVu Sans Mono. Headings, lists, tables, links and footnotes are kept. Each page becomes one PNG, so a long document gives you several files.
Pages are drawn at 150 dpi unless you set Resolution (dpi) or Width (px). Page size is A4 unless you set it to Letter, or to auto so each page takes the size of its own content.
What changes or is dropped
The three header lines become the title, author and date. They also stay as the first paragraph. Settings and comments are dropped.
The %%date macro prints 1970-01-01. A bare e-mail address becomes a broken link that shows mailto: before it. Images stay as links.
Options
Set Resolution (dpi) between 36 and 600. Higher is sharper and makes a bigger file, and 300 is the usual choice for print. Set Width (px) to give the exact width of the result in pixels. The height follows the aspect ratio unless you also give it, in which case the picture can be stretched.
Set Pages to convert only some pages, such as 1-3,7. Every page is read when it is left out.
To change the size of a PNG afterward, see resize PNG.
T2T and PNG.What each format is, and the options this conversion takes.
- 01 · dpi
Resolution (dpi)
How many pixels each inch of the page becomes when it is drawn as a picture. Higher is sharper and makes a bigger file. Around 150 reads well on screen, and 300 is the usual choice for print.
36 to 600 default 150 - 02 · page_size
Page size
The size of the pages written. A4 is the standard in most of the world and Letter in North America.
a4210 × 297 mm.letter8.5 × 11 in.autoEach page takes the size of its own content.
- 03 · pages
Pages
Converts only some pages. Write single pages and ranges separated by commas, such as 1-3,7. Every page is read when it is left out.
- 04 · width
Width (px)
The exact width of the result in pixels. The height follows the aspect ratio unless it is also given, in which case the picture can be stretched.
1 to 20000
The formats
txt2tags
txt2tags documents, plain text with light markup that the txt2tags tool turns into many formats.
- Extensions
- .t2t
- MIME type
- text
/x -txt2tags - Kind
- Text and data
PNG
Lossless raster images with an alpha channel. Screenshots, icons and graphics with sharp edges.
- Extensions
- .png
- MIME type
- image
/png - Kind
- Images
In your code.The same T2T to PNG conversion through the API, for your app or your agent.
$ cv convert report.t2t report/ --to png$ cv convert report.t2t report/ --to pngQuestions.What people ask about T2T to PNG.
Yes. Each page becomes one PNG, so the result is one or more files.
The %%date macro prints 1970-01-01 in the output.
Yes. Set Page size to Letter. Choose auto to let each page take the size of its own content.
They are dropped. Only the document content is typeset.