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

On WSL2: Cannot clickthrough example hud #19

Open
twilwa opened this issue Sep 11, 2023 · 1 comment
Open

On WSL2: Cannot clickthrough example hud #19

twilwa opened this issue Sep 11, 2023 · 1 comment

Comments

@twilwa
Copy link

twilwa commented Sep 11, 2023

expected behavior: i should be able to click on stuff through the hud

actual behavior: clicking on things underneath the hud doesn't function. I can click-drag to highlight text displayed on the HUD, however. after a few minutes, or so, a window for "Web Inspector" appears, although it doesn't appear to be clickable, after which the HUD transparent window can be click-dragged off of the screen. there's no associated terminal output, as far as i can tell.

i suspect it may either be an issue with wsl, or an issue with my package manager, tea (tea.xyz), which sometimes messes with PATHs and such.

steps to reproduce: ./run.sh as per the readme, window key to show taskbar, left click to browser window.

environment: Ubuntu 23.04 via WSL2

image

@anko
Copy link
Owner

anko commented Mar 4, 2024

Perhaps the issue is related to Windows not supporting GTK's input_shape_combine_region function, which hudkit uses to make the window click-through ("transparent" to mouse clicks);

On the Win32 platform, this functionality is not present and the function does nothing.


A possible workaround using AutoHotkey, from forum user dangerdogL2121 in 2015: It appears an AutoHotkey script can make windows click-through (archive link), using some Windows-specific window attribute. The crucial lines:

WinTitle = Calculator ;or whatever you want
SetTitleMatchMode, 2
WinSet, ExStyle, +0x20, % WinTitle ; 0x20 = WS_EX_CLICKTHROUGH

Hudkit's window title is hudkit overlay window.

If you try this, let me know! If it works, we could detect WSL and replicate that trick.

@anko anko changed the title cannot clickthrough example hud On WSL2: Cannot clickthrough example hud Apr 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants