literate-dotfiles/docs/sxhkd.html

438 lines
15 KiB
HTML
Raw Permalink Normal View History

2020-01-11 22:04:45 +01:00
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
2022-05-09 10:05:23 +02:00
<!-- 2022-05-09 lun. 10:04 -->
2020-01-11 22:04:45 +01:00
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<title>Simple X Hotkey Daemon</title>
<meta name="author" content="Dehaeze Thomas" />
2021-04-25 19:10:57 +02:00
<meta name="generator" content="Org Mode" />
2021-01-01 20:12:34 +01:00
<link rel="stylesheet" type="text/css" href="./dist/style.css"/>
<script type="text/javascript" src="./dist/script.js"></script>
2020-01-11 22:04:45 +01:00
</head>
<body>
<div id="org-div-home-and-up">
<a accesskey="h" href="./index.html"> UP </a>
|
<a accesskey="H" href="./index.html"> HOME </a>
2022-05-09 10:05:23 +02:00
</div><div id="content" class="content">
2020-01-11 22:04:45 +01:00
<h1 class="title">Simple X Hotkey Daemon</h1>
2022-05-09 10:05:23 +02:00
<div id="table-of-contents" role="doc-toc">
2020-01-11 22:04:45 +01:00
<h2>Table of Contents</h2>
2022-05-09 10:05:23 +02:00
<div id="text-table-of-contents" role="doc-toc">
2020-01-11 22:04:45 +01:00
<ul>
2022-05-09 10:05:23 +02:00
<li><a href="#org4624078">Basic</a></li>
<li><a href="#org90f8a1b">Multimedia keys</a>
2020-01-11 22:04:45 +01:00
<ul>
2022-05-09 10:05:23 +02:00
<li><a href="#org99f76b9">Sound</a></li>
<li><a href="#org34c6f17">Backlight</a></li>
<li><a href="#orgb243371">Change Tracks</a></li>
<li><a href="#org7030418">Print Screen</a></li>
<li><a href="#orgbf3ca39">Other</a></li>
2020-01-11 22:04:45 +01:00
</ul>
</li>
2022-05-09 10:05:23 +02:00
<li><a href="#org4f74836"><code>Super + key</code> - Start Applications</a></li>
<li><a href="#org95c65ac"><code>Super + Shift</code> - Managing Applications</a></li>
<li><a href="#orgd3fdbc1"><code>Super + Space</code> - Command Mode</a></li>
<li><a href="#orga3d4227">I3 related</a>
2020-01-11 22:04:45 +01:00
<ul>
2022-05-09 10:05:23 +02:00
<li><a href="#orgdbe9d37">Kill Window</a></li>
<li><a href="#org1423ca3">Set the window State</a></li>
<li><a href="#org69184b8">focus/swap</a></li>
<li><a href="#orgc5f1368">Preselect</a></li>
<li><a href="#org57e5904">Resize</a></li>
2020-03-01 22:51:16 +01:00
</ul>
</li>
2020-01-11 22:04:45 +01:00
</ul>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org4624078" class="outline-2">
<h2 id="org4624078">Basic</h2>
<div class="outline-text-2" id="text-org4624078">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Kill Windows</span>
super + ctrl + x
2020-01-11 22:04:45 +01:00
xkill
</pre>
</div>
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">make sxhkd reload its configuration files:</span>
2020-01-11 22:04:45 +01:00
super + Escape
2021-01-01 20:12:34 +01:00
pkill -usr1 -x sxhkd; notify-send <span class="org-string">'sxhkd'</span> <span class="org-string">'Reloaded config'</span>
2020-01-11 22:04:45 +01:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Update Polybar</span>
super + shift + r
polybar-msg cmd restart
2020-01-11 22:04:45 +01:00
</pre>
</div>
2020-01-12 17:28:30 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Exit Screen</span>
XF86PowerOff
2020-05-26 08:40:15 +02:00
i3exit
2020-01-11 22:04:45 +01:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Exit Screen</span>
super + <span class="org-highlight-numbers-number">0</span>
i3exit
2020-01-11 22:04:45 +01:00
</pre>
</div>
2021-01-01 20:12:34 +01:00
<p>
Change Keyboard Layout:
</p>
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Change keyboard to US-International layout</span>
super + ctrl + d
setxkbmap -layout us -variant intl -option caps:escape
2020-01-11 22:04:45 +01:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Change keyboard to US layout</span>
super + shift + d
setxkbmap -layout us -option caps:escape
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org90f8a1b" class="outline-2">
<h2 id="org90f8a1b">Multimedia keys</h2>
<div class="outline-text-2" id="text-org90f8a1b">
2020-01-11 22:04:45 +01:00
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org99f76b9" class="outline-3">
<h3 id="org99f76b9">Sound</h3>
<div class="outline-text-3" id="text-org99f76b9">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Mute/Unmute</span>
XF86AudioMute
2020-01-11 22:04:45 +01:00
amixer -D pulse sset Master toggle
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Increase Volume</span>
2020-01-11 22:04:45 +01:00
XF86AudioRaiseVolume
amixer -D pulse sset Master 2%+
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Decrease Volume</span>
2020-01-11 22:04:45 +01:00
XF86AudioLowerVolume
amixer -D pulse sset Master 2%-
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org34c6f17" class="outline-3">
<h3 id="org34c6f17">Backlight</h3>
<div class="outline-text-3" id="text-org34c6f17">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Increase Backlight</span>
XF86MonBrightnessUp
xbacklight -inc <span class="org-highlight-numbers-number">10</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">Descrease Backlight</span>
2020-01-11 22:04:45 +01:00
XF86MonBrightnessDown
2021-01-01 20:12:34 +01:00
xbacklight -dec <span class="org-highlight-numbers-number">10</span>
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-orgb243371" class="outline-3">
<h3 id="orgb243371">Change Tracks</h3>
<div class="outline-text-3" id="text-orgb243371">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Play/Pause music</span>
super + period
mpc toggle
<span class="org-comment-delimiter"># </span><span class="org-comment">Previous/Next music</span>
2020-01-11 22:04:45 +01:00
super + {greater,less}
2021-01-01 20:12:34 +01:00
mpc {next,prev}
2020-01-11 22:04:45 +01:00
</pre>
</div>
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Play/Pause music</span>
XF86AudioPlay
mpc toggle
<span class="org-comment-delimiter"># </span><span class="org-comment">Next music</span>
2020-01-11 22:04:45 +01:00
XF86AudioNext
2021-01-01 20:12:34 +01:00
mpc next
<span class="org-comment-delimiter"># </span><span class="org-comment">Previous music</span>
2020-01-11 22:04:45 +01:00
XF86AudioPrev
2021-01-01 20:12:34 +01:00
mpc prev
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org7030418" class="outline-3">
<h3 id="org7030418">Print Screen</h3>
<div class="outline-text-3" id="text-org7030418">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Screenshot script</span>
Print
~/.local/bin/screenshot
<span class="org-comment-delimiter"># </span><span class="org-comment">Switch Windows</span>
2020-01-11 22:04:45 +01:00
XF86Display
2021-01-01 20:12:34 +01:00
rofi -show window
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-orgbf3ca39" class="outline-3">
<h3 id="orgbf3ca39">Other</h3>
<div class="outline-text-3" id="text-orgbf3ca39">
2021-01-01 20:12:34 +01:00
<div class="org-src-container">
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Run Command</span>
XF86Search
rofi -show run
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
2021-01-01 20:12:34 +01:00
</div>
2020-01-11 22:04:45 +01:00
2022-05-09 10:05:23 +02:00
<div id="outline-container-org4f74836" class="outline-2">
<h2 id="org4f74836"><code>Super + key</code> - Start Applications</h2>
<div class="outline-text-2" id="text-org4f74836">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Switch Windows</span>
super + w
rofi -show window
<span class="org-comment-delimiter"># </span><span class="org-comment">program launcher</span>
super + d
2020-01-11 22:04:45 +01:00
rofi -show run
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">categorized menu</span>
super + z
rofi -show drun
2020-01-11 22:04:45 +01:00
</pre>
</div>
2021-01-01 20:12:34 +01:00
<div class="org-src-container">
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Start Terminal</span>
super + Return
$TERMINAL
<span class="org-comment-delimiter"># </span><span class="org-comment">File Manager</span>
super + o
2021-10-25 14:37:10 +02:00
$TERMINAL -e tmux new-session -A -s ranger ranger
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Browser</span>
super + i
qutebrowser
<span class="org-comment-delimiter"># </span><span class="org-comment">Mails with neomutt</span>
super + m
2021-10-25 14:37:10 +02:00
$TERMINAL -e tmux new-session -A -s neomutt neomutt
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Emacs Client</span>
super + e
<span class="org-variable-name">emacsclient -create-frame --alternate-editor</span>=<span class="org-string">""</span>
</pre>
2020-01-11 22:04:45 +01:00
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org95c65ac" class="outline-2">
<h2 id="org95c65ac"><code>Super + Shift</code> - Managing Applications</h2>
<div class="outline-text-2" id="text-org95c65ac">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2022-05-09 10:05:23 +02:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Bluetooth Manager</span>
2021-01-01 20:12:34 +01:00
super + shift + b
blueman-manager
2021-04-25 19:10:57 +02:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Calculator</span>
super + shift + c
rofi-calc
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Sound Manager</span>
super + shift + s
pavucontrol
<span class="org-comment-delimiter"># </span><span class="org-comment">Passwords</span>
super + shift + p
rofi-pass
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-orgd3fdbc1" class="outline-2">
<h2 id="orgd3fdbc1"><code>Super + Space</code> - Command Mode</h2>
<div class="outline-text-2" id="text-orgd3fdbc1">
2021-01-01 20:12:34 +01:00
<div class="org-src-container">
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Command line Calendar Client (khal)</span>
2020-01-11 22:04:45 +01:00
super + space ; c
2021-10-25 14:37:10 +02:00
$TERMINAL --title khal -e ikhal
2020-01-11 22:04:45 +01:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">pcmanfm: GUI file manager</span>
2020-03-01 22:51:16 +01:00
super + space ; o
2022-05-09 10:05:23 +02:00
nautilus;
2020-05-26 08:40:15 +02:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Run another instance of Neomutt in read-only mode</span>
2021-01-08 01:34:53 +01:00
super + space ; m
2021-10-25 14:37:10 +02:00
$TERMINAL -e neomutt -R
2020-01-11 22:04:45 +01:00
2022-05-09 10:05:23 +02:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Music with ncmpcpp</span>
super + space ; w
$TERMINAL -e tmux new-session -A -s gomuks gomuks
2020-01-11 22:04:45 +01:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Music with ncmpcpp</span>
2020-01-11 22:04:45 +01:00
super + space ; p
2021-10-25 14:37:10 +02:00
$TERMINAL -e tmux new-session -A -s ncmpcpp ncmpcpp
2020-01-11 22:04:45 +01:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Default Browser</span>
2020-01-11 22:04:45 +01:00
super + space ; i
2020-03-01 22:51:16 +01:00
$BROWSER;
2020-01-11 22:04:45 +01:00
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Emacs</span>
2020-01-11 22:04:45 +01:00
super + space ; e
2021-01-08 01:34:53 +01:00
<span class="org-variable-name">emacsclient -create-frame --alternate-editor</span>=<span class="org-string">""</span>
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-orga3d4227" class="outline-2">
<h2 id="orga3d4227">I3 related</h2>
<div class="outline-text-2" id="text-orga3d4227">
2020-01-11 22:04:45 +01:00
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-orgdbe9d37" class="outline-3">
<h3 id="orgdbe9d37">Kill Window</h3>
<div class="outline-text-3" id="text-orgdbe9d37">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">close and kill</span>
super + q
i3-msg kill
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org1423ca3" class="outline-3">
<h3 id="org1423ca3">Set the window State</h3>
<div class="outline-text-3" id="text-org1423ca3">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Set the window to full-screen</span>
2020-01-11 22:04:45 +01:00
super + f
2020-05-26 08:40:15 +02:00
i3-msg fullscreen toggle
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Set the window to floating</span>
2020-05-26 08:40:15 +02:00
super + s
i3-msg floating toggle
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Alternate between the tiled and normal layout</span>
2020-05-26 08:40:15 +02:00
super + t
2020-01-11 22:04:45 +01:00
i3-msg layout toggle tabbed split
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Change focus between tiling / floating windows</span>
2020-01-11 22:04:45 +01:00
super + c
i3-msg focus mode_toggle
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Sticky window</span>
2020-05-26 08:40:15 +02:00
super + y
2020-01-11 22:04:45 +01:00
i3-msg sticky toggle
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org69184b8" class="outline-3">
<h3 id="org69184b8">focus/swap</h3>
<div class="outline-text-3" id="text-org69184b8">
2020-01-11 22:04:45 +01:00
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Focus/swap the node in the given direction</span>
2020-01-11 22:04:45 +01:00
super + {_,shift + }{h,Left}
i3-msg {focus,move} left
super + {_,shift + }{j,Down}
i3-msg {focus,move} down
super + {_,shift + }{k,Up}
i3-msg {focus,move} up
super + {_,shift + }{l,Right}
i3-msg {focus,move} right
</pre>
</div>
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Focus the next/previous desktop in the current monitor</span>
2020-01-11 22:04:45 +01:00
super + {p,n}
i3-msg workspace {prev,next}
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Focus the last Desktop</span>
2020-01-11 22:04:45 +01:00
super + b
i3-msg workspace back_and_forth
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Focus to the given desktop</span>
2020-01-11 22:04:45 +01:00
super + {1-9}
2021-01-01 20:12:34 +01:00
i3-msg workspace <span class="org-string">'{1-9}'</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">Send to the given desktop</span>
2020-01-11 22:04:45 +01:00
super + ctrl + {1-9}
2021-01-01 20:12:34 +01:00
i3-msg move container to workspace <span class="org-string">'{1-9}'</span>
<span class="org-comment-delimiter"># </span><span class="org-comment">Focus and Send to the given desktop</span>
2020-01-11 22:04:45 +01:00
super + shift + {1-9}
2021-01-01 20:12:34 +01:00
<span class="org-variable-name">WP</span>={1-9} &amp;&amp; i3-msg move container to workspace $WP &amp;&amp; i3-msg workspace $WP
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-orgc5f1368" class="outline-3">
<h3 id="orgc5f1368">Preselect</h3>
<div class="outline-text-3" id="text-orgc5f1368">
2020-01-11 22:04:45 +01:00
<p>
Preselect the direction
</p>
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Set Horizontal Layout</span>
super + ctrl + {h,l,Left,Right}
2020-01-11 22:04:45 +01:00
i3-msg split h
2021-01-01 20:12:34 +01:00
<span class="org-comment-delimiter"># </span><span class="org-comment">Set Vertical Layout</span>
2020-01-11 22:04:45 +01:00
super + ctrl + {j,k,Up,Down}
i3-msg split v
</pre>
</div>
</div>
</div>
2022-05-09 10:05:23 +02:00
<div id="outline-container-org57e5904" class="outline-3">
<h3 id="org57e5904">Resize</h3>
<div class="outline-text-3" id="text-org57e5904">
2020-01-11 22:04:45 +01:00
<p>
Expand/Shrink a window
</p>
<div class="org-src-container">
2021-01-01 20:12:34 +01:00
<pre class="src src-conf"><span class="org-comment-delimiter"># </span><span class="org-comment">Horizontal Shrink</span>
super + alt + h
i3-msg resize shrink width <span class="org-highlight-numbers-number">10</span> px or <span class="org-highlight-numbers-number">10</span> ppt
<span class="org-comment-delimiter"># </span><span class="org-comment">Vertical Grow</span>
2020-01-11 22:04:45 +01:00
super + alt + j
2021-01-01 20:12:34 +01:00
i3-msg resize grow height <span class="org-highlight-numbers-number">10</span> px or <span class="org-highlight-numbers-number">10</span> ppt
<span class="org-comment-delimiter"># </span><span class="org-comment">Vertical Shrink</span>
2020-01-11 22:04:45 +01:00
super + alt + k
2021-01-01 20:12:34 +01:00
i3-msg resize shrink height <span class="org-highlight-numbers-number">10</span> px or <span class="org-highlight-numbers-number">10</span> ppt
<span class="org-comment-delimiter"># </span><span class="org-comment">Horizontal Grow</span>
2020-01-11 22:04:45 +01:00
super + alt + l
2021-01-01 20:12:34 +01:00
i3-msg resize grow width <span class="org-highlight-numbers-number">10</span> px or <span class="org-highlight-numbers-number">10</span> ppt
2020-01-11 22:04:45 +01:00
</pre>
</div>
</div>
</div>
</div>
</div>
<div id="postamble" class="status">
<p class="author">Author: Dehaeze Thomas</p>
2022-05-09 10:05:23 +02:00
<p class="date">Created: 2022-05-09 lun. 10:04</p>
2020-01-11 22:04:45 +01:00
</div>
</body>
</html>