You are not logged in.

#126 2013-07-03 10:02:26

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

zeltak wrote:

Would it be possible to add some kind of on screen visual clue for button pressed (especially when chaining keys)?

It is now possible via the -s option.

An example script using notify-send is provided in examples/notification.


gh · da · ds

Offline

#127 2013-07-03 10:03:40

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

Supplantr wrote:

The e, w, and m keys are only detected by the love window upon being released.

Fixed.


gh · da · ds

Offline

#128 2013-07-03 19:49:00

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 168

Re: sxhkd — Simple X HotKey Daemon

Thx bloom

"An example script using notify-send is provided in examples/notification."

i cant seem to find that script anywhere, is it on github somewhere?

best

Z

Offline

#129 2013-07-04 03:24:43

Supplantr
Member
From: a state of sunshine
Registered: 2011-12-12
Posts: 149
Website

Re: sxhkd — Simple X HotKey Daemon

bloom wrote:

Fixed.

I can confirm that this is now fixed; thanks!

Is there any way to prevent sxhkd from attempting to expand curly brackets in a command? For instance, I'm trying to use:

bspc alternate_desktop && bspc send_to $(bspc list_desktops --quiet | awk '/~/ {print $1}') --follow

which doesn't work. I guess I could either place the above command in a script or replace awk with grep '~' | cut -d ' ' -f1.


I use linux and I dont understand nothing in this post.

Offline

#130 2013-07-04 03:38:36

Stebalien
Member
Registered: 2010-04-27
Posts: 1,237
Website

Re: sxhkd — Simple X HotKey Daemon

Supplantr wrote:
bloom wrote:

Fixed.

I can confirm that this is now fixed; thanks!

Is there any way to prevent sxhkd from attempting to expand curly brackets in a command? For instance, I'm trying to use:

bspc alternate_desktop && bspc send_to $(bspc list_desktops --quiet | awk '/~/ {print $1}') --follow

which doesn't work. I guess I could either place the above command in a script or replace awk with grep '~' | cut -d ' ' -f1.

You should be able to escape them with backslashes (`\{print $1\}`).


Steven [ web : git ]
GPG:  327B 20CE 21EA 68CF A7748675 7C92 3221 5899 410C
Do not email: honeypot@stebalien.com

Offline

#131 2013-07-04 04:38:07

Supplantr
Member
From: a state of sunshine
Registered: 2011-12-12
Posts: 149
Website

Re: sxhkd — Simple X HotKey Daemon

Stebalien wrote:

You should be able to escape them with backslashes (`\{print $1\}`).

That was too easy. Thanks!


I use linux and I dont understand nothing in this post.

Offline

#132 2013-07-04 09:12:50

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

zeltak wrote:

I cant seem to find that script anywhere, is it on github somewhere?

git clone https://github.com/baskerville/sxhkd.git
cd sxhkd/examples/notification

gh · da · ds

Offline

#133 2013-07-06 01:46:45

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 168

Re: sxhkd — Simple X HotKey Daemon

hi again bloom

im aware im an idiot but i cant get it to work (the visual cue). i dl the sample script and start sxhkd with -s PATH to script but i cant get anything to show up? what am i doing wrong

sorry for being slow

Z

Offline

#134 2013-07-06 05:28:07

Stebalien
Member
Registered: 2010-04-27
Posts: 1,237
Website

Re: sxhkd — Simple X HotKey Daemon

zeltak wrote:

hi again bloom

im aware im an idiot but i cant get it to work (the visual cue). i dl the sample script and start sxhkd with -s PATH to script but i cant get anything to show up? what am i doing wrong

sorry for being slow

Z

Everything. tongue

sxhkd writes to the socket specified by '-s' and the script reads from this socket.

# Make the socket
mkfifo /path/to/sxhkd_socket
# Start the notifier
sxhkd_notify /path/to/sxhkd_socket &
# Start sxhkd
sxhkd -s /path/to/sxhkd_socket

Steven [ web : git ]
GPG:  327B 20CE 21EA 68CF A7748675 7C92 3221 5899 410C
Do not email: honeypot@stebalien.com

Offline

#135 2013-07-06 06:35:31

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 19,739

Re: sxhkd — Simple X HotKey Daemon

ModeraorModerator comment

zeltak wrote:

im aware im an idiot but i cant get it to work (the visual cue). i dl the sample script and start sxhkd with -s PATH to script but i cant get anything to show up? what am i doing wrong

zeltak,

I assume you are not posting from your phone, but even if you are -- These are not SMS based forums.  Please, our community norm is to use complete English sentences with proper punctuation and spelling.  We do, of course, make every accommodation for non-native speakers who try their best.  SMS shorthand does not qualify.

Please see our policy
https://wiki.archlinux.org/index.php/Fo … ow_to_Post

Last edited by ewaller (2013-07-06 15:11:48)


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#136 2013-07-06 10:53:05

Rasi
Member
From: Germany
Registered: 2007-08-14
Posts: 1,914
Website

Re: sxhkd — Simple X HotKey Daemon

ewaller wrote:

Moderaor comment

zeltak wrote:

im aware im an idiot but i cant get it to work (the visual cue). i dl the sample script and start sxhkd with -s PATH to script but i cant get anything to show up? what am i doing wrong

zeltak,

I assume you are not posting from your phone, but even if you are -- These are not SMS based forums.  Please, our community norm is to use complete English sentences with proper punctuation and spelling.  We do, of course, make every accommodation for non-native speakers who try their best.  SMS shorthand does not qualify.

Please see our policy
https://wiki.archlinux.org/index.php/Fo … ow_to_Post

wtf? i see nothing wrong with his post...

*edit* Moderator is written with a "t" (sorry, couldn't resist)

Last edited by Rasi (2013-07-06 10:58:34)


He hoped and prayed that there wasn't an afterlife. Then he realized there was a contradiction involved here and merely hoped that there wasn't an afterlife.

Douglas Adams

Offline

#137 2013-07-06 18:59:32

zeltak
Member
From: New England
Registered: 2010-08-07
Posts: 168

Re: sxhkd — Simple X HotKey Daemon

thx Stebalien

worked like a charm

Z

Offline

#138 2013-07-06 19:39:10

Rasi
Member
From: Germany
Registered: 2007-08-14
Posts: 1,914
Website

Re: sxhkd — Simple X HotKey Daemon

zeltak wrote:

thx Stebalien

worked like a charm

Z

oh-oh, sms talk detected (thx instead of thank you)!


but what i really wanted to say: thanks bloom, this is a neat little tool.

Last edited by Rasi (2013-07-06 19:39:55)


He hoped and prayed that there wasn't an afterlife. Then he realized there was a contradiction involved here and merely hoped that there wasn't an afterlife.

Douglas Adams

Offline

#139 2013-08-27 16:35:16

Supplantr
Member
From: a state of sunshine
Registered: 2011-12-12
Posts: 149
Website

Re: sxhkd — Simple X HotKey Daemon

Would it be possible to implement i3-esque "modes"? Syntactically, perhaps something similar to:

super + r : {h,j,k,l}

which would bind the {h,j,k,l} keys until the "mode" is exited.


I use linux and I dont understand nothing in this post.

Offline

#140 2013-08-28 21:01:25

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

Supplantr wrote:

Would it be possible to implement i3-esque "modes"? Syntactically, perhaps something similar to:

super + r : {h,j,k,l}

which would bind the {h,j,k,l} keys until the "mode" is exited.

Brought by a4c9908.

A mode can be exited via the Escape key.

The replay event character prefix is now ~.


gh · da · ds

Offline

#141 2013-08-29 23:15:06

Supplantr
Member
From: a state of sunshine
Registered: 2011-12-12
Posts: 149
Website

Re: sxhkd — Simple X HotKey Daemon

bloom wrote:

Brought by a4c9908.

Thanks, this is awesome. It still times out if no keys are pressed; is this supposed to happen?


I use linux and I dont understand nothing in this post.

Offline

#142 2013-08-29 23:33:12

progandy
Member
Registered: 2012-05-17
Posts: 5,184

Re: sxhkd — Simple X HotKey Daemon

Supplantr wrote:
bloom wrote:

Brought by a4c9908.

Thanks, this is awesome. It still times out if no keys are pressed; is this supposed to happen?

Seems that way. Either set all timeouts to 0 or modify types.c:

    if (chained && !locked && timeout > 0)
        alarm(timeout);

| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

#143 2013-08-30 09:10:39

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

progandy wrote:
Supplantr wrote:
bloom wrote:

Brought by a4c9908.

It still times out if no keys are pressed; is this supposed to happen?

Seems that way.

And since it seems unexpected, I've applied the suggested patch.


gh · da · ds

Offline

#144 2013-09-12 13:01:05

Iao
Member
Registered: 2012-11-09
Posts: 20

Re: sxhkd — Simple X HotKey Daemon

You might like the idea of press durations. For example, if I hold the key down for X seconds the command will be executed.

Also, in extension to that, press duration intervals. For example, when I press the key the command is executed and if keep the key held down it will execute the command every X seconds.

With both features used for the same binding, there's the press duration at the beginning with the intervals starting after the initial execution.

These features would be pretty useful for numbered controls (volume, brightness, window gaps), power management (suspend on key held down for 5 seconds), etc. Thanks in advance for consideration!

Edit: If you do implement these features, you may want to disable repeating commands on key press hold for normal binds.

Last edited by Iao (2013-09-12 13:14:56)

Offline

#145 2013-09-16 17:42:55

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

Sirsurthur wrote:

I am trying to use sxhkd with bspwm and had one question. Is there a way to make sxhkd aware of azerty keyboards ? Actually, as an example, my w and z keys are mixed when used in sxhkd.

It should be fixed by 2d484d0.


gh · da · ds

Offline

#146 2013-09-20 16:04:53

Supplantr
Member
From: a state of sunshine
Registered: 2011-12-12
Posts: 149
Website

Re: sxhkd — Simple X HotKey Daemon

Commit f013d17 seems to render sxhkd unusable. It builds and runs without issue but doesn't respond to keypresses while running. As I was typing, the pull request was submitted that should fix this.

Unrelated to the above, and perhaps unrelated to sxhkd all together: if a tabbed instance containing any embedded windows is the only window on its bspwm desktop when it's closed, sxhkd becomes unresponsive. This doesn't happen if another window immediately receives focus or if tabbed has nothing embedded when closed.
I'm able to remedy this by switching to a different tty and executing:

DISPLAY=:0 bspc desktop -f \^3
or
DISPLAY=:0 st &

at which point sxhkd begins responding to keypresses again.

Also, @Nindwen asked in the bspwm thread: "is there a way to easily use one key to cycle through multiple actions?" and gave the example:

super + something
    { bspc desktop -f pad,
      bspc desktop -f last }

If doable, this might be a useful addition.

Last edited by Supplantr (2013-09-20 16:17:16)


I use linux and I dont understand nothing in this post.

Offline

#147 2013-09-20 16:32:14

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

Supplantr wrote:

Unrelated to the above, and perhaps unrelated to sxhkd all together: if a tabbed instance containing any embedded windows is the only window on its bspwm desktop when it's closed, sxhkd becomes unresponsive. This doesn't happen if another window immediately receives focus or if tabbed has nothing embedded when closed.

Could you provide further instructions on how to reproduce?

Supplantr wrote:

Also, @Nindwen asked in the bspwm thread: "is there a way to easily use one key to cycle through multiple actions?"
If doable, this might be a useful addition.

Agreed.


gh · da · ds

Offline

#148 2013-09-20 16:44:07

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: sxhkd — Simple X HotKey Daemon

@ bloom, you might want to fix your email on the sxhkd github page. Lavabit is gone ...

Offline

#149 2013-09-20 17:04:52

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

x33a wrote:

@ bloom, you might want to fix your email on the sxhkd github page. Lavabit is gone ...

Fixed. Thanks.


gh · da · ds

Offline

#150 2013-09-20 17:34:24

bloom
Member
Registered: 2010-08-18
Posts: 749
Website

Re: sxhkd — Simple X HotKey Daemon

@Supplantr:
I can, in fact, reproduce.


gh · da · ds

Offline

Board footer

Powered by FluxBB