mirror of
https://github.com/FliegendeWurst/cursive.git
synced 2024-11-13 20:53:07 +00:00
16 lines
349 B
Rust
16 lines
349 B
Rust
extern crate cursive;
|
|
|
|
use cursive::Cursive;
|
|
use cursive::view::{TextView,Dialog};
|
|
|
|
fn main() {
|
|
let mut siv = Cursive::new();
|
|
|
|
// Creates a dialog with a single "Quit" button
|
|
siv.add_layer(Dialog::new(TextView::new("Hello Dialog!"))
|
|
.title("Cursive")
|
|
.button("Quit", |s| s.quit()));
|
|
|
|
siv.run();
|
|
}
|