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

Window position does not change on startup, regardless of settings #1287

Open
2 tasks done
CodeDead opened this issue Mar 15, 2022 · 1 comment
Open
2 tasks done

Window position does not change on startup, regardless of settings #1287

CodeDead opened this issue Mar 15, 2022 · 1 comment
Labels
bug Something isn't working shell

Comments

@CodeDead
Copy link

Is there an existing issue for this?

  • I have searched the existing issues.

Is this issue related to iced?

  • My hardware is compatible and my graphics drivers are up-to-date.

What happened?

When running a native application and trying to position the initial window in the center, it does not center the window, but instead it opens the window in the top-left corner.

view::ApplicationContext::run(Settings {
        window: window::Settings {
            position: window::Position::Centered,
            ..window::Settings::default()
        },
        ..Default::default()
    })

Relevant system specs:

  • Fedora Linux 35 (fully updated as of 03-16-2022
  • 2 active monitors

What is the expected behavior?

The application window should open in the center of the screen of the active monitor

Version

master

Operative System

Linux

Do you have any log output?

No response

@CodeDead CodeDead added the bug Something isn't working label Mar 15, 2022
@hecrj hecrj added the shell label Mar 17, 2022
@13r0ck
Copy link
Member

13r0ck commented Sep 26, 2022

Related to #1440,
This is not a bug in Iced. Wayland doesn't let windows request position.
This might be possible if Winit were to expose a layer-shell window setting, but first, that would have to be exposed by sctk in a released version. Anyway, this issue is better placed in Winit as iced cannot do anything about it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working shell
Projects
None yet
Development

No branches or pull requests

3 participants