Replies: 10 comments 7 replies
-
Is tcp server needed? In linux xdotool can get the activewindow |
Beta Was this translation helpful? Give feedback.
-
The TCP server is not necessary for this particular feature as you've shown. There can be workarounds that don't involve inter-process communication. However, the TCP server is nice to have for software integrations. |
Beta Was this translation helpful? Give feedback.
-
For ease of discovery:
|
Beta Was this translation helpful? Give feedback.
-
Just a thought. I have been using Espanso as a text expander and noticed they have application aware triggers. |
Beta Was this translation helpful? Give feedback.
-
Yep, that's a good reference to use if one were to implement this in kanata. https://github.com/espanso/espanso/tree/9f82b4e146e6090897c876a02f5eee697b85e979/espanso-info |
Beta Was this translation helpful? Give feedback.
-
espanso offers similar features than autohotkey hotstrings, and similar to ahk hotstrings espanso won't work while kanata is running (at least on windows). But if we could tell espanso to listen to the kanata ouput instead of the real keyboard it should work? |
Beta Was this translation helpful? Give feedback.
-
I quickly put together a rough draft.
Sends a request to change the layer to the current window name. Needs significant improvements, for example switch to the default layer, if current window is not in the list of application-specific layers. Here is the code: https://github.com/veyxov/qanata (sorry for the name 😅) Updates: |
Beta Was this translation helpful? Give feedback.
-
I use SetWinEventHook implemented a simple tool in windows: kanawin. |
Beta Was this translation helpful? Give feedback.
-
Wow, would you believe that timing! I just finished my own daemon to interact with Kanata's TCP server. I guess it's pretty similar to kanawin with a few pros and cons. Cons
Pros
While it's still a work in progress, it's 100% working on my end. I'd love feedback if anyone gives it a try! |
Beta Was this translation helpful? Give feedback.
-
Hey are there any plans for linux application aware layer switching or is xremaps the only solution? |
Beta Was this translation helpful? Give feedback.
-
For Linux, can use https://github.com/k0kubun/xremap for inspiration.
For Windows: https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-getforegroundwindow
Beta Was this translation helpful? Give feedback.
All reactions