From d6a0708b995b6c0e12ed8890c678c180f859de51 Mon Sep 17 00:00:00 2001 From: Arne Dußin Date: Fri, 20 Nov 2020 20:32:25 +0100 Subject: Change to different GUI style --- src/main.rs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/main.rs') diff --git a/src/main.rs b/src/main.rs index 1ebcbfe..6c9a0ec 100644 --- a/src/main.rs +++ b/src/main.rs @@ -19,9 +19,11 @@ use config::Config; use editor::Editor; use gui::ToolSidebar; use raylib::prelude::*; +use std::ffi::CString; use std::io; use transform::Transform; +pub const GUI_STYLE: &str = "assets/style/cyber.rgs"; pub const CONFIG_FILE: &str = "config.ron"; fn main() { @@ -53,6 +55,11 @@ fn main() { } }; + // Load the preferred gui style + rl.gui_load_style(Some( + &CString::new(GUI_STYLE).expect("Could not create C string from style file name"), + )); + let mut editor = Editor::new(&mut rl, &thread, config); let tool_sidebar = ToolSidebar::new(&mut rl, &thread); -- cgit v1.2.3-70-g09d2