Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

epi & egui_glium: Add maximized property to NativeOptions #649

Merged
merged 1 commit into from
Aug 25, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions egui_glium/src/backend.rs
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ fn create_display(
) -> glium::Display {
let mut window_builder = glutin::window::WindowBuilder::new()
.with_always_on_top(native_options.always_on_top)
.with_maximized(native_options.maximized)
.with_decorations(native_options.decorated)
.with_resizable(native_options.resizable)
.with_title(app.name())
Expand Down
4 changes: 4 additions & 0 deletions epi/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,9 @@ pub struct NativeOptions {
/// Sets whether or not the window will always be on top of other windows.
pub always_on_top: bool,

/// Show window in maximized mode
pub maximized: bool,

/// On desktop: add window decorations (i.e. a frame around your app)?
/// If false it will be difficult to move and resize the app.
pub decorated: bool,
Expand Down Expand Up @@ -191,6 +194,7 @@ impl Default for NativeOptions {
fn default() -> Self {
Self {
always_on_top: false,
maximized: false,
decorated: true,
drag_and_drop_support: false,
icon_data: None,
Expand Down