TextWrap.jl

Julia package for wrapping text into paragraphs.
Author carlobaldassi
Popularity
7 Stars
Updated Last
7 Months Ago
Started In
November 2012

TextWrap.jl

Documentation Build Status

This Julia package allows to wrap long lines of text to fit within a given width.

Quick example

julia> text = "This text is going to be wrapped around in lines no longer than 20 characters.";

julia> println_wrapped(text, width=20)
This text is going
to be wrapped around
in lines no longer
than 20 characters.

The other exported functions are wrap (returns a string) and print_wrapped. See the documentation for more advanced settings.

Installation

To install the module, use Julia's package manager: start pkg mode by pressing ] and then enter:

(v1.3) pkg> add TextWrap

Dependencies will be installed automatically. The module can then be loaded like any other Julia module:

julia> using TextWrap

Documentation

  • STABLEmost recently tagged version of the documentation.
  • DEVin-development version of the documentation.

Changes in release 1.0.1

  • Improve recognition of ANSI escape codes
  • Fixes for the replace_whitespace=true case

Changes in release 1.0.0

  • Drop support for Julia versions v0.6/v0.7
  • Recognize ANSI escape codes and by default don't count them in the width computations

Required Packages

No packages found.