printrn 0.1.5

A macro to replace `println!()`, that will replace all `\n` with `\r\n`, e.g. for crossterm or other raw terminal work.
Documentation
  • Coverage
  • 57.14%
    4 out of 7 items documented0 out of 0 items with examples
  • Size
  • Source code size: 12.35 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.12 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 12s Average build duration of successful builds.
  • all releases: 12s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • crabdancing

printrn

A macro to replace println!(), that will replace all \n with \r\n.

This is useful when working with raw terminals, such as via crossterm or tui. In raw terminal mode, \n will only move the current line one down, and keep printing from there, like so:

APPLE
     BOOK
         CHERRY

Which is where \r (short for carriage Return) comes in. By replacing all \n with \r\n, you can get the more expected behavior:

APPLE
BOOK
CHERRY