Skip to content

How to set the window in the middle of the desktop? #1058

Answered by hecrj
push-and-pop asked this question in Q&A
Discussion options

You must be logged in to vote

If you rely on master, you should be able to use the position field in window::Settings:

/// The initial position of the window.
pub position: Position,

And set it to Position::Centered:

/// The window is completely centered on the screen.
Centered,

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by hecrj
Comment options

You must be logged in to vote
2 replies
@hecrj
Comment options

@push-and-pop
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Further information is requested
2 participants
Converted from issue

This discussion was converted from issue #1054 on September 27, 2021 07:03.