You are not logged in.
I just came along this thread, because I'm searching for a way to swap mouse buttons only within windows of a certain application. Is this somehow doable with sxhkd? Swapping middle and right mouse would be fine then. Or do you have another idea how to achieve this?
Last edited by t.ask (2015-03-23 16:31:46)
Offline
I just came along this thread, and I was wondering if there was a way to kill a focused window that is a subprocess. Like say I have chrome and hangouts open, but I want to specifically kill hangouts.
Offline
I just came along this thread, and I was wondering if there was a way to kill a focused window that is a subprocess. Like say I have chrome and hangouts open, but I want to specifically kill hangouts.
Is Hangouts a native app, or webapp? If it's the former, xkill should be ok.
Offline
It's a webapp. I know that some wm's (xmonand, dwm) can do it. But how can I do kill sub-processes.
Last edited by mtello17 (2015-05-22 19:54:01)
Offline
It's a webapp. I know that some wm's (xmonand, dwm) can do it. But how can I do kill sub-processes.
If it's a webapp, then it's probably beyond the WM manager's control.
There's no way to close a single tab from a WM perspective. It's not a window, and it's pretty hard to for the WM to determine which process is associated with that browser tab.
Offline
Oh, too bad
Thanks.
Offline
not sure what I a dong wrong here
why does this command work from terminal rofi-show run
but not with sxhkd binding as:
alt + r
rofi -show run
You can like linux without becoming a fanatic!
Offline
not sure what I a dong wrong here
why does this command work from terminal rofi-show run
but not with sxhkd binding as:
alt + r
rofi -show run
this works for me, although when I first installed rofi to test it i commented out dmenu_run and put rofi -show run under the comment. this didn't work, felt silly but eventually figured out that it had to be before the comment.
Offline
Hi!
Thanks for this awesome app!
I was wondering if you have implemented the context aware keybindings (detecting clicks on rootwindow):
chneukirchen wrote:This seems to work on any click, not just on the root window.
Hotkeys are, by definition, global.
I wanted this fuctionality for stuff like resizing wondows by grapping them from window gap and so on, so I wrote (with great amount of help) this bash/awk wrapper to xev to do that:
https://bbs.archlinux.org/viewtopic.php?id=204039
But now I heard that sxhkd might do this after all, which I would would prefer as it is lighter and cleaner than my solution.
So did it get implemented at some point?
Last edited by Chrysostomus (2015-10-21 01:24:28)
The difference between reality and fiction is that fiction has to make sense.
Offline
hi i dint find anything on google so im posting here
im trying to make a hotkey for when caps-lock is on
but if i use Caps_Lock + q the caps-lock is ignored and it triggers when i press the q
Offline
Can someone help me with a key-chain, that includes some terminal ssh-calls:
example:
super + t ; { t, r, a, b, c }
{ uxterm \
, uxterm -e su - \
, uxterm ssh -p 12345 -e user@a.org \
, uxterm ssh -p 23456 -e root@b.net \
, uxterm ssh -p 111111 -e admin@c.info \
}
First ssh command works - the following calls fail.
Doesn't matter, which server is in first place.
Supposing, that the @ is the bad, I tried
-e '...'
-e "..."
\@
@@
plus some more strange things...
Anyone, who knows the trick?
Offline
Are you chaining ssh calls using a hotkey daemon? Why not use ProxyCommand or similar?
Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.
Offline
I want to start different coloured uxterms running ssh-shells on different servers.
As I don't need all the servers at once, but sometimes fast, I tried to implement that with the formidable sxhkd.
But your post gave me the idea, that I could do that the one-comand-per-call way...
Offline
I am looking for a way to execute a command before entering the variable keys of a chord chain (no matter which variable key that is provided).
Kind of like this:
mod3 + m : {l, s}
echo "BSPWM mode active" > /tmp/bspwm_mode; \
bspwm_menu {lock, suspend}
In this example, the echo-command is executed _after_ pressing one of the variable keys (l and s), and then the bspwm_menu-command is executed.
I would like to know if there is a way to run echo command directly after pressing mod3+m and _before_ entering either of the variable keys.
Does anyone know?
Thanks in advance,
wololos
Last edited by wololos (2020-04-04 16:27:21)
Offline
I am looking for a way to execute a command before entering the variable keys of a chord chain (no matter which variable key that is provided).
Kind of like this:
mod3 + m : {l, s} echo "BSPWM mode active" > /tmp/bspwm_mode; \ bspwm_menu {lock, suspend}
In this example, the echo-command is executed _after_ pressing one of the variable keys (l and s), and then the bspwm_menu-command is executed.
I would like to know if there is a way to run echo command directly after pressing mod3+m and _before_ entering either of the variable keys.
Does anyone know?
Thanks in advance,
wololos
I was looking for this too. Here is the answer, using sxhkd's status fifo (which is poorly documented outside of an example in the repo, but does exactly what we want).
Create a file `sxhkd_status_mon.sh` with the following content:
#! /bin/sh
[ $# -ne 1 ] && exit 1
status_fifo=$1
{ while read -r line ; do
msg=${line#?}
prefix=${line:0:1}
# See https://github.com/baskerville/sxhkd/blob/fe241b0d2d70c9c483b23cf3cd14f1383f0953a2/src/sxhkd.h#L38-L42 for all prefixes.
case $prefix in
B) # Begin chain
echo "BSPWM mode active" > /tmp/bspwm_mode
# bspc config focused_border_color "#$manage_border_color"
;;
E) # End chain
rm /tmp/bspwm_mode
# bspc config focused_border_color "#$focused_border_color"
;;
esac
done } < "$status_fifo"
Run this script and sxhkd like this:
SXHKD_STATUS_FIFO="/run/user/$UID/sxhkd.fifo"
if [ ! -f "${SXHKD_STATUS_FIFO}" ]; then
mkfifo "${SXHKD_STATUS_FIFO}"
fi
pgrep sxhkd || \
sxhkd -m -1 -s "${SXHKD_STATUS_FIFO}" &
# Monitor sxhkd status
sxhkd_status_mon.sh "${SXHKD_STATUS_FIFO}" &
Last edited by bluedrink9 (2021-04-22 22:35:29)
Offline
may i swap mouse clicks to keystroke? include pressed and release events. thanks for reply
Offline