aboutsummaryrefslogtreecommitdiff
path: root/config.def.h
diff options
context:
space:
mode:
authorBert Münnich <ber.t@posteo.de>2013-11-14 14:47:36 +0100
committerBert Münnich <ber.t@posteo.de>2013-11-14 14:47:36 +0100
commit2737fc8b81829372d454f407e19733d66d964272 (patch)
tree976ee138e2fdcaba94c3c17073720834c1b45aa6 /config.def.h
parent38bc23405d619a7ba430731f141157104f2267f9 (diff)
parent0353e6eea265f5f6fa53eb75300529d9ffa6d4fa (diff)
Merge remote-tracking branch 'ariand/gamma'
Diffstat (limited to 'config.def.h')
-rw-r--r--config.def.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/config.def.h b/config.def.h
index f5d048a..b877aa1 100644
--- a/config.def.h
+++ b/config.def.h
@@ -46,6 +46,12 @@ enum {
GIF_LOOP = 0 /* endless loop [0/1] */
};
+/* gamma correction: the user-visible ranges [-GAMMA_RANGE, 0] and
+ * (0, GAMMA_RANGE] are mapped to the ranges [0, 1], and (1, GAMMA_MAX].
+ * */
+static const double GAMMA_MAX = 10.0;
+static const int GAMMA_RANGE = 32;
+
#endif
#ifdef _THUMBS_CONFIG
@@ -141,6 +147,11 @@ static const keymap_t keys[] = {
{ false, XK_a, i_toggle_antialias, (arg_t) None },
{ false, XK_A, it_toggle_alpha, (arg_t) None },
+ /* decrease/increase/reset gamma */
+ { false, XK_braceleft, i_change_gamma, (arg_t) -1 },
+ { false, XK_braceright, i_change_gamma, (arg_t) +1 },
+ { true, XK_G, i_change_gamma, (arg_t) 0 },
+
/* open current image with given program: */
{ true, XK_g, it_open_with, (arg_t) "gimp" },