24 lines
541 B
Rust
24 lines
541 B
Rust
use amane::*;
|
|
|
|
fn main() {
|
|
App::new().window(view).run();
|
|
}
|
|
|
|
fn view() -> LayerWindow {
|
|
LayerWindow::new()
|
|
.width(Full)
|
|
.height(20.0)
|
|
.anchor_vertical(Vertical::Top)
|
|
.layer(Layer::Top)
|
|
.child(
|
|
Rectangle::new()
|
|
.width(Parent)
|
|
.height(Parent)
|
|
.fill(Color::BLUE)
|
|
.align_child(End, Center)
|
|
.child(
|
|
Text::new("hello world").size(20.0).color(Color::WHITE)
|
|
),
|
|
)
|
|
}
|