summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--config.h46
1 files changed, 46 insertions, 0 deletions
diff --git a/config.h b/config.h
new file mode 100644
index 0000000..9406e48
--- /dev/null
+++ b/config.h
@@ -0,0 +1,46 @@
+/* modifier 0 means no modifier */
+static Key searchbar_keys[] = {
+ /* modifier keyval function arg stop event */
+ { 0, GDK_Escape, hidesearch, {0}, TRUE },
+ { 0, GDK_Return, searchtext, {.b = TRUE}, TRUE },
+ { GDK_SHIFT_MASK, GDK_Return, searchtext, {.b = FALSE}, TRUE },
+ { GDK_SHIFT_MASK, GDK_Left, NULL, {0}, FALSE },
+ { GDK_SHIFT_MASK, GDK_Right, NULL, {0}, FALSE },
+};
+
+static Key urlbar_keys[] = {
+ /* modifier keyval function arg stop event */
+ { 0, GDK_Escape, hideurl, {0}, TRUE },
+ /* able to "chain" commands; by setting stop event to FALSE */
+ { 0, GDK_Return, loaduri, {.v = NULL}, FALSE },
+ { 0, GDK_Return, hideurl, {0}, TRUE },
+ { GDK_SHIFT_MASK, GDK_Left, NULL, {0}, FALSE },
+ { GDK_SHIFT_MASK, GDK_Right, NULL, {0}, FALSE },
+};
+
+static Key general_keys[] = {
+ /* modifier keyval function arg stop event */
+ { GDK_CONTROL_MASK, GDK_p, clipboard, {.b = TRUE }, TRUE },
+ { GDK_CONTROL_MASK, GDK_y, clipboard, {.b = FALSE}, TRUE },
+ { GDK_CONTROL_MASK, GDK_R, reload, {.b = TRUE}, TRUE },
+ { GDK_CONTROL_MASK, GDK_r, reload, {.b = FALSE}, TRUE },
+ { GDK_CONTROL_MASK, GDK_b, NULL, {0}, TRUE },
+ { GDK_CONTROL_MASK, GDK_g, showurl, {0}, TRUE },
+ { GDK_CONTROL_MASK, GDK_slash, showsearch, {0}, TRUE },
+ { GDK_CONTROL_MASK, GDK_plus, zoompage, {0}, TRUE },
+ { GDK_CONTROL_MASK, GDK_minus, zoompage, {.f = -1.0 }, TRUE },
+ { GDK_CONTROL_MASK, GDK_0, zoompage, {.f = +1.0 }, TRUE },
+ { GDK_CONTROL_MASK, GDK_n, searchtext, {.b = TRUE}, TRUE },
+ { GDK_CONTROL_MASK, GDK_N, searchtext, {.b = FALSE}, TRUE },
+ { GDK_CONTROL_MASK, GDK_Right, navigate, {.b = TRUE}, TRUE },
+ { GDK_CONTROL_MASK, GDK_Left, navigate, {.b = FALSE}, TRUE },
+ { 0, GDK_Escape, stop, {0}, TRUE },
+};
+
+/* Sequence of Keys to match against a keypress */
+static KeySet keysets[] = {
+ /* keyset (Key[]) numkeys focusedwidget/mode */
+ { searchbar_keys, LENGTH(searchbar_keys), SEARCHBAR },
+ { urlbar_keys, LENGTH(urlbar_keys), URLBAR },
+ { general_keys, LENGTH(general_keys), NONE },
+};
This is the style how it was before the big Xft change. The colors were inverted, this was not the case before the change. Reported by "zvz" on #suckless IRC, thanks! 2015-06-27Use libdraw: add Xft and fallback-fonts support to graphics libGravatar Hiltjo Posthuma 11-316/+684 - libdraw, util: add drw.{c,h}, util.{c,h} and update code. - libdraw: fix drw_rect(): use w and h parameter. - libdraw: print errstr if last character in string was ":" (sbase). - libdraw: drw_clr_free() allow valid free(NULL). - config.def.h: set default font to monospace. - cleanup() on exit. - LICENSE: update license string for dmenu -v to 2015. - LICENSE: add myself to LICENSE 2014-09-17applied Hiltjo's patch as suggested on the ml to fix ControlMask for C-j and C-mGravatar Anselm R Garbe 2-2/+5 2014-07-30fix crash with ctrl-enter as inputGravatar Hiltjo Posthuma 1-1/+2 reproduce: ./dmenu; send EOF; press ctrl+enter. 2014-05-29updated copyright notices in LICENSE and dmenu.c fileGravatar Anselm R Garbe 2-2/+2 2013-08-13applied Martin Kühl's inverse matching flag to stestGravatar Anselm R Garbe 2-4/+7 2013-08-02applied Martti Kühne's dmenu monitor patchGravatar Anselm R Garbe 3-4/+14 https://gist.github.com/mar77i/3349298/raw/f6581ca96627f4c71c0bd1faf531daaf2a613b95/monarg.patch becomes upstream now 2013-06-28accepted vi'is exit approach ^[ (suggested by Arkaduisz)Gravatar Anselm R Garbe 1-0/+2