chromakopia 0.1.0

Beautiful terminal string gradients and animations for Rust
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use chromakopia::animate;
use std::time::Duration;

#[tokio::main]
async fn main() {
    animate::Sequence::new("AMSTERDAM  15:42  GATE B7  ON TIME")
        .flap(Duration::from_secs(4))
        .with_fade(Duration::from_secs(1), Duration::ZERO)
        .hold(chromakopia::Color::new(0xff, 0xcc, 0x00), Duration::from_secs(2))
        .with_fade(Duration::ZERO, Duration::from_secs(1))
        .run(1.0)
        .await;
}