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

supersonic window keeps jumping to the middle of the screen #394

Open
llfw opened this issue Jun 2, 2024 · 8 comments
Open

supersonic window keeps jumping to the middle of the screen #394

llfw opened this issue Jun 2, 2024 · 8 comments

Comments

@llfw
Copy link

llfw commented Jun 2, 2024

i'm using supersonic 0.10.1 on Wayland, with Sway 1.9 compositor, on FreeBSD 15.0/amd64. supersonic is in a floating (not tiled) window.

seemingly randomly (sometimes after i click something, but not always) the window will jump to the centre of the screen for no apparent reason. no other application does this, only supersonic.

i appreciate this is a bit of a vague bug report but i'm not really sure how to investigate it -- i'm happy to try any troubleshooting steps.

@dweymouth
Copy link
Owner

Hmm I have no idea why this could be happening, and most likely it's a problem upstream with the Fyne UI toolkit. How are you running Supersonic? (Flatpak or direct installation?) And are you running the X11 build through XWayland, or a -tags wayland build (which is still experimental)?

@llfw
Copy link
Author

llfw commented Jun 2, 2024

i'm running it from a normal compiled binary running natively (no sandboxing). i built the binary using the FreeBSD ports framework from a local repository, so it has whatever other stuff ports adds to the build (but this is mostly just about setting correct paths, etc., not anything that would affect the behaviour of the app).

i wasn't using -tags wayland, but i just tried launching it with that and it made no different -- the same behaviour immediately occurred.

@llfw
Copy link
Author

llfw commented Jun 2, 2024

sorry, i just noticed you said -tags wayland is a build option. could you briefly describe how to enable that? i am not familiar with Go at all.

@dweymouth
Copy link
Owner

go build -tags wayland as opposed to just go build. It is still experimental though and the window won't have any window borders in wayland mode, for example. But if you have another way of managing the window size and position you can give it a try.

@dweymouth
Copy link
Owner

You can follow here fyne-io/fyne#1851 for updates and progress on full Wayland support in the upstream UI toolkit

@llfw
Copy link
Author

llfw commented Jun 2, 2024

thanks! i'm waiting for another build to finish but i'll test this afterwards.

It is still experimental though and the window won't have any window borders in wayland mode

fwiw, it's only GNOME who think Wayland clients should provide their own borders. the vast majority of Wayland compositors (including Sway) are opposed to this position and provide their own borders. so that's absolutely fine.

@llfw
Copy link
Author

llfw commented Jun 7, 2024

i've updated to 0.11.0 and switched to -tags wayland, and this seems to have fixed the problem, thanks!

however, it's also made the font size too small on my 4K display; for X11 i assume it was using Xft.dpi for scaling, is there an equivalent setting (environment variable, etc.) that it uses for scaling on Wayland?

@dweymouth
Copy link
Owner

Sorry I was just checking back on old issues and realized I forgot to reply to this. I don't know what it is reading scale from on Wayland. Officially, building a Wayland binary is still experimental with the UI toolkit. But you can set the FYNE_SCALE environment variable to scale up or down the UI (for all applications written with the Fyne toolkit). It's a multiplier, so FYNE_SCALE=1 would be the same as the default scaling and bigger values like say 1.5 increase it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants