cursive/examples/theme.rs

16 lines
377 B
Rust
Raw Normal View History

extern crate cursive;
use cursive::Cursive;
2016-06-26 00:10:18 +00:00
use cursive::view::{Dialog, TextView};
fn main() {
let mut siv = Cursive::new();
siv.load_theme("assets/style.toml");
siv.add_layer(Dialog::new(TextView::new("This application uses a custom theme!"))
2016-06-26 00:10:18 +00:00
.title("Themed dialog")
.button("Quit", |s| s.quit()));
siv.run();
}