Commit Graph

12 Commits (05d9ca6e0d10fc805c99e494d66bc9b7b5f0e319)

Author SHA1 Message Date
Manos Pitsidianakis c62c04e1e7
text-processing: small line_break.rs fix 2019-11-21 15:39:56 +02:00
Manos Pitsidianakis 41d039992c
text-processing: add catch-all line splitting
By using Reflow::All, lines are split when overflowing the screen's
width, and start with a special symbol
2019-11-21 15:37:50 +02:00
Manos Pitsidianakis b01b9ffbcb
text_processing: add reflow method() and enum to TextProcessing trait
Add
 split_lines_reflow(&self, reflow: Reflow, width: Option<usize>) -> Vec<String>
method that, according to reflow (No reflow, FormatFlowed
or All) reflows the text.

FormatFlowed follows the rfc3676 - The Text/Plain Format and DelSp Parameters
https://tools.ietf.org/html/rfc3676
2019-11-16 20:19:02 +02:00
Manos Pitsidianakis 321be8555f
Cleanup startup error exit paths
Make startup methods return Results so that the main binary can exit
cleanly instead of using std::process::exit from arbitrary positions,
which exits the process immediately and doesn't run destructors.
2019-11-16 00:33:22 +02:00
Manos Pitsidianakis e600b0252f
text_processing: add line_break method
In preparation for format=flowed support, add a line_break method in the
text_processing Trait, now renamed from Graphemes to TextProcessing.
2019-11-09 17:44:22 +02:00
Manos Pitsidianakis b7edec0274
Bump version to 0.3.2 2019-09-28 12:25:44 +03:00
Manos Pitsidianakis fa121820f7
Bump version to 0.3.1 2019-09-26 14:11:24 +03:00
Manos Pitsidianakis 79212621af
Bump version to 0.3.0 2019-09-16 16:44:04 +03:00
Manos Pitsidianakis fed13816dd
Bump version to all workspace crates 2019-08-03 23:59:49 +03:00
Matthias Beyer abcd68e789
Make function pub
As this file was written (according to the top-level comment) for this
function, it should be pub.

This fixes an "unused function" warning.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
2019-08-02 01:00:53 +03:00
Manos Pitsidianakis 5b679be782
text_processing: implement Unicode line breaking algorithm
Not conforming to the unicode standard yet
2019-07-27 01:56:07 +03:00
Manos Pitsidianakis d84ceca88e
create text_processing crate 2019-07-27 01:41:04 +03:00