yuanbohan / rs-figlet Goto Github PK
View Code? Open in Web Editor NEWRust implementation of FIGlet (http://www.figlet.org/) to create ascii art
License: Other
Rust implementation of FIGlet (http://www.figlet.org/) to create ascii art
License: Other
The figlet
command leaves very little space between letters, like this:
__ __
/ /____ _____/ /_
/ __/ _ \/ ___/ __/
/ /_/ __(__ ) /_
\__/\___/____/\__/
This library, however, leaves a lot of space between characters:
______ __
/_ __/ ___ _____ / /_
/ / / _ \ / ___/ / __/
/ / / __/ (__ ) / /_
/_/ \___/ /____/ \__/
It looks like the leftmost character of one letter can only come after the rightmost letter of the one before it.
When I try to use univers I get:
thread 'main' panicked at 'called
Result::unwrap()on an
Errvalue: "one line len can't be less than 2. it is:@"', src/renderer/mod.rs:23:66 note: run with
RUST_BACKTRACE=1environment variable to display a backtrace
(small
from the example in the repo works just fine)
This is also done by pyfiglet.
I'll create a PR today
Hi @yuanbohan,
I'm using this lib in my program as below. But it does not display the banner when I run the program.
How do we display the banner?
use figlet_rs::FIGfont;
fn main() {
let small_font = FIGfont::from_file("resources/small.flf").unwrap();
let figure = small_font.convert("HELLO");
assert!(figure.is_some());
}
Thanks,
Unmesh
Using this as an external crate panics on FIGfont::standard()
because font file is not available at given relative path "resources/standard.flf". Consider packaging font(-s) via include_str!
macro or by any other suitable means.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.