Center window in game_of_life example
This commit is contained in:
parent
72b3bf95de
commit
39b8f7de50
1 changed files with 5 additions and 0 deletions
|
|
@ -9,6 +9,7 @@ use iced::executor;
|
|||
use iced::pick_list::{self, PickList};
|
||||
use iced::slider::{self, Slider};
|
||||
use iced::time;
|
||||
use iced::window;
|
||||
use iced::{
|
||||
Align, Application, Checkbox, Clipboard, Column, Command, Container,
|
||||
Element, Length, Row, Settings, Subscription, Text,
|
||||
|
|
@ -19,6 +20,10 @@ use std::time::{Duration, Instant};
|
|||
pub fn main() -> iced::Result {
|
||||
GameOfLife::run(Settings {
|
||||
antialiasing: true,
|
||||
window: window::Settings {
|
||||
position: window::Position::Centered,
|
||||
..window::Settings::default()
|
||||
},
|
||||
..Settings::default()
|
||||
})
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue