aboutsummaryrefslogtreecommitdiffstats
path: root/config.def.h
diff options
context:
space:
mode:
Diffstat (limited to 'config.def.h')
-rw-r--r--config.def.h74
1 files changed, 67 insertions, 7 deletions
diff --git a/config.def.h b/config.def.h
index 1edb647..4f06346 100644
--- a/config.def.h
+++ b/config.def.h
@@ -1,23 +1,83 @@
+#ifdef _laptop
+#define laptop(...) __VA_ARGS__
+#define komputer(...)
+#endif
+
+#ifdef _komputer
+#define komputer(...) __VA_ARGS__
+#define laptop(...)
+#endif
+
/* See LICENSE file for copyright and license details. */
/* Default settings; can be overriden by command line. */
static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */
+static int draw_input = 1; /* -noi option; if 0, the input will not be drawn by default */
+static int centered = 0; /* -c option; centers dmenu on screen */
+static int min_width = 500; /* minimum width when centered */
+static const float menu_height_ratio = 4.0f; /* This is the ratio used in the original calculation */
+static const unsigned int alpha = 0xee; /* Amount of opacity. 0xff is opaque */
/* -fn option overrides fonts[0]; default X11 font or font set */
+static char font[] = "JetBrains Mono Nerd Font Propo:size=10";
static const char *fonts[] = {
- "monospace:size=10"
+ font,
+ "JetBrains Mono Nerd Font Propo:size=10"
};
-static const char *prompt = NULL; /* -p option; prompt to the left of input field */
-static const char *colors[SchemeLast][2] = {
+static char *prompt = NULL; /* -p option; prompt to the left of input field */
+
+static char normfgcolor[] = "#bbbbbb";
+static char normbgcolor[] = "#222222";
+static char selfgcolor[] = "#eeeeee";
+komputer(static char selbgcolor[] = "#005577";)
+laptop(static char selbgcolor[] = "#b20701";)
+static char *colors[SchemeLast][2] = {
/* fg bg */
- [SchemeNorm] = { "#bbbbbb", "#222222" },
- [SchemeSel] = { "#eeeeee", "#005577" },
- [SchemeOut] = { "#000000", "#00ffff" },
+ [SchemeNorm] = { normfgcolor, normbgcolor },
+ [SchemeSel] = { selfgcolor, selbgcolor },
+ [SchemeOut] = { "#000000", "#00ffff" },
+
};
-/* -l option; if nonzero, dmenu uses vertical list with given number of lines */
+
+static const unsigned int alphas[SchemeLast][2] = {
+ [SchemeNorm] = { OPAQUE, alpha },
+ [SchemeSel] = { OPAQUE, alpha },
+ [SchemeOut] = { OPAQUE, alpha },
+};
+/* -l and -g options; controls number of lines and columns in grid if > 0 */
static unsigned int lines = 0;
+static unsigned int columns = 0;
/*
* Characters not considered part of a word while deleting words
* for example: " /?\"&[]"
*/
static const char worddelimiters[] = " ";
+
+/*
+ * Xresources preferences to load at startup
+ */
+ResourcePref resources[] = {
+ { "font", STRING, &font },
+ { "normfgcolor", STRING, &normfgcolor },
+ { "normbgcolor", STRING, &normbgcolor },
+ { "selfgcolor", STRING, &selfgcolor },
+ { "selbgcolor", STRING, &selbgcolor },
+ { "prompt", STRING, &prompt },
+};
+
+
+/* Size of the window border */
+laptop (static unsigned int border_width = 2;)
+komputer (static unsigned int border_width = 0;)
+
+/*
+ * -vi option; if nonzero, vi mode is always enabled and can be
+ * accessed with the global_esc keysym + mod mask
+ */
+static unsigned int vi_mode = 1;
+static unsigned int start_mode = 0; /* mode to use when -vi is passed. 0 = insert mode, 1 = normal mode */
+static Key global_esc = { XK_n, Mod1Mask }; /* escape key when vi mode is not enabled explicitly */
+static Key quit_keys[] = {
+ /* keysym modifier */
+ { XK_q, 0 }
+};