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

Keyboard Input under Wayland #2565

Open
davidscherf opened this issue Oct 17, 2023 · 0 comments
Open

Keyboard Input under Wayland #2565

davidscherf opened this issue Oct 17, 2023 · 0 comments

Comments

@davidscherf
Copy link

davidscherf commented Oct 17, 2023

I am getting keys from the keyboard using the event KeyUp of the window

This works fine on x11.
But on Wayland the console that I started the test on types the letters, but the event gets nothing

Expected Behavior

Event KeyUp KeyDown gets the key pressed

Actual Behavior

Event is not fired

Steps to Reproduce the Problem

  1. Hook the event KeyUp to a method
  2. Run the code on a Wayland system
  3. Get no key input

Code that Demonstrates the Problem

private void MainWindow_KeyUp(object sender, KeyEventArgs e)
{
        Console.WriteLine("Key press");
}

Specifications

  • Version: 2.8
  • Platform(s): Gtk
  • Operating System(s): Linux arm64 Raspberry Pi OS 5

More information

Seems this issue affects running under sudo

error: XDG_RUNTIME_DIR is invalid or not set in the environment.

And since my app needs to run under sudo, I do not have a workaround, I tried setting XDG_RUNTIME_DIR to the same path as the logged in user but no luck.

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

1 participant