From 66ce05d7ddf067dd8d682c57d2a2dfc8b157cf22 Mon Sep 17 00:00:00 2001 From: Surferlul Date: Fri, 29 Jul 2022 06:31:52 +0200 Subject: [PATCH] Initial commit --- .gitignore | 2 ++ Cargo.toml | 9 +++++++++ src/main.rs | 26 ++++++++++++++++++++++++++ 3 files changed, 37 insertions(+) create mode 100644 Cargo.toml create mode 100644 src/main.rs diff --git a/.gitignore b/.gitignore index 088ba6b..cbed4d7 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,5 @@ Cargo.lock # These are backup files generated by rustfmt **/*.rs.bk + +.idea/ diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 0000000..f3f2691 --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,9 @@ +[package] +name = "native-ui-example" +version = "0.1.0" +edition = "2021" + +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html + +[dependencies] +native-ui-gnome = { git = "https://github.com/Surferlul/native-ui-gnome" } \ No newline at end of file diff --git a/src/main.rs b/src/main.rs new file mode 100644 index 0000000..0c08a31 --- /dev/null +++ b/src/main.rs @@ -0,0 +1,26 @@ +use native_ui_gnome::{ + NativeApplication, + abstracts +}; +// goal is to only replace +// native_ui_gnome:: +// crate for changing the platform to for example +// plasma (qt), windows, or macOS + +fn main() { + let abst_app = abstracts::Application::builder() + .title("native-ui GNOME test") + .add_window( + abstracts::Window::builder() + .title("test title") + .build() + ) + .add_window( + abstracts::Window::builder() + .title("Test Title") + .build() + ) + .build(); + let mut app = NativeApplication::new(abst_app); + app.run(); +}