Macro gstore::application_window[][src]

macro_rules! application_window {
    (
        widget {
             $($widget:tt)*
        }
        $(window {
            $(styles: $styles_path:literal)?
            $(title_bar: $title_bar:expr)?
        })?
    ) => { ... };
}

Creates a new ApplicationWindow.

See Also

Examples

application_window! {
    widget {
        properties {
            default_width: 400
            default_height: 400
        }
        connections {
            (store) connect_destroy: move |_| store.dispatch(Action::Stop)
        }
        children [
            label!(just "Test Label")
        ]
    }
    window {
    // set title bar with `title_bar: ...`
    // load styles here via `styles: "../styles.css"`
    }
};