Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Which apps? Not that it makes a difference for this conversation, but I'm interested in keeping up to date with what the "killer apps" are that keep people from switching.


If you're talking about Windows apps that keep me from switching to Linux, I have an oddball one: it's a keyboard re-mapper that I wrote back in Windows 3.1 and still use. It does the same re-mapping in every application (except for some reason in Microsoft Edge). It's not a simple 1-for-1 mapper, which I think is readily available in Linux.

At the simplest level, it re-maps ^H to the left cursor arrow, ^N to PageDown, etc.

But it gets more complicated: ^D maps to seven down cursor arrows (i.e. it moves the cursor down seven lines), ^U in the opposite direction. ^C usually (more details below) maps to ^Left (i.e. go to the beginning of the word), Shift-^Right (select to end of word), and ^C (copy selected text). (Notice the final ^C does not cause recursion!)

^A once goes to the beginning of the line, ^A twice goes to top of screen (I forget the exact keystrokes it emits, but this works with most apps), and ^A thrice goes to the beginning of the file. Analogously for ^E, but end.

Finally, it has two modes. In the normal mode, all the cursor control keys do their normal cursor movement thing. But type ^Q, and the cursor keys are now in select mode: ^H outputs Shift-Left, i.e. selects the character to the left, etc. Drop out of select mode with ^C (copy selection--different from what I described above!), ^X (cut selection), or ^Q again (do nothing with the selection).

I'd love to be able to reproduce this kind of behavior in Linux. I'm sure it's possible, but I don't know enough about keyboard re-mapping, or keyboard drivers, to do it.


That sounds pretty similar to the QMK firmware that runs on my keyboard (an Ergodox-EZ).

It's been a blast to play around with. Best part is that it travels with the keyboard rather than the OS, so I can plug into a different computer and retain the same layout without needing to install anything.

I've been slowly resetting all my OS hotkeys/shortcuts to their defaults, and customizing the position of those keys on my keyboard instead. Current layout, for reference: https://configure.zsa.io/ergodox-ez/layouts/xbzAL/latest/0


Might be a good solution, if it can output multiple keys with a single keystroke, but unfortunately my keyboard can't travel with me. In particular I can't plug it into my work computer.


If you use Xorg you can use XInput2 and XIGrabKeycode[0] to grab specific key combinations and get notified (via event messages, they happen asynchronously) when they are pressed. Then you can use XTest and XTestFakeKeyEvent[1] to send the event you want.

XInput2 and XIGrabKeycode should provide the highest priority grabbing under Xorg so that even applications that do server-wide grabs (e.g. games) will be bypassed.

XTest was meant for automated UI testing but can be used for all sorts of automated behaviors.

For the first part i wrote a simple program[2] years a go that uses xkill to kill the toplevel window with Ctrl+Alt+K (mainly for games that grab the input and hang) which can be used as a quick example. I haven't tried to use XTestFakeKeyEvent but there seems to be a lot of code out there which can be used as an example, e.g. this one[2] (see the send_key function near the top).

[0] https://linux.die.net/man/3/xigrabkeycode

[1] https://linux.die.net/man/3/xtestfakekeyevent

[2] http://runtimeterror.com/tools/xkeyller/

[3] http://git.yoctoproject.org/cgit.cgi/matchbox-history/plain/...


Hmm, looks like the sendkey.c thing might work. Although the documentation on XTestFakeKeyEvent() specifically says "This extension is not intended to support general journaling and playback of user actions", which is what (I think) I want. I wonder why the disclaimer.


I haven't tried it yet, but I recently learned about this tool and have it on my list to test drive:

https://github.com/rvaiya/keyd


For me there are a couple areas that just have a tough time in linux: VR Development, Digital audio workstations and niche utilities. It is getting better but still has a ways to go in these areas imo.

Specifically: VR Development - Unity now has a linux version which is great but there is no oculus runtime which means no oculus testing (SteamVR works but has some hiccups)

Digital audio workstations - Looking primarily at FL Studio, yes you can wine it but for me the audio delay makes it very difficult to use. I'd love to find solutions around this but haven't thus far.

Niche utilities - For game dev I've got a ton of old utilities for visualizing or converting old 3d object files to newer formats, sdks for old games that I occasionally need to pop into and all of them struggle or require a lot of setup to work properly on linux. For these I find myself booting over to windows, grabbing what I need and popping back to linux.


I just recently switch from windows to linux. Was planning to do some 3D printing tomorrow, but saw that Fusion360 had poor Wine support. So I probably need to learn a new software or setup a VM or something.


Fusion360 is the only thing I run a VM for. There’s a repo out there that sets up wine and installs it but it just doesn’t work very well at all. I’m using VMWare Player and set up the virtual disk to boot from the Windows drive and run it that way. It works really well. Other 3D printing stuff like PrusaSlicer works great on Linux. I’d love to have a native version of Fusion though. Maybe someday.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: