Commit Graph

14 Commits (4048eab424fa2d0ccd5c260df07ddd0a7927029f)

Author SHA1 Message Date
Manos Pitsidianakis b327bee3e4
text_processing: add GlobMatch trait
Move GlobMatch trait from ui::mailcap to text_processing in order to use
it for glob matching folder paths in subscribed_folders field of
account configuration. See next commit.
5 years ago
Manos Pitsidianakis f3c938d8c3
Prevent OOM abort when printing large strings 5 years ago
Manos Pitsidianakis c62c04e1e7
text-processing: small line_break.rs fix 5 years ago
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
5 years ago
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
5 years ago
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.
5 years ago
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.
5 years ago
Manos Pitsidianakis b7edec0274
Bump version to 0.3.2 5 years ago
Manos Pitsidianakis fa121820f7
Bump version to 0.3.1 5 years ago
Manos Pitsidianakis 79212621af
Bump version to 0.3.0 5 years ago
Manos Pitsidianakis fed13816dd
Bump version to all workspace crates 5 years ago
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>
5 years ago
Manos Pitsidianakis 5b679be782
text_processing: implement Unicode line breaking algorithm
Not conforming to the unicode standard yet
5 years ago
Manos Pitsidianakis d84ceca88e
create text_processing crate 5 years ago