[feat] add kqueue
[sfm.git] / config.def.h
blobf450eb772d1e302a39ffd1cf329d71e9c3d7ccf8
1 /* See LICENSE file for copyright and license details.*/
3 #ifndef CONFIG_H
4 #define CONFIG_H
6 #include "termbox.h"
8 /* colors fg, bg */
9 static const Cpair cdir = { 33, TB_DEFAULT };
10 static const Cpair cerr = { 124, TB_DEFAULT };
11 static const Cpair cexec = { 2, TB_DEFAULT };
12 static const Cpair cfile = { TB_DEFAULT, TB_DEFAULT };
13 static const Cpair cframe = { TB_DEFAULT, TB_DEFAULT };
14 static const Cpair cother = { 3, TB_DEFAULT };
15 static const Cpair cpanell = { 166, TB_DEFAULT };
16 static const Cpair cpanelr = { 5, TB_DEFAULT };
17 static const Cpair cprompt = { 33, TB_DEFAULT };
18 static const Cpair csearch = { 255, TB_DEFAULT };
19 static const Cpair cstatus = { TB_DEFAULT, TB_DEFAULT };
21 /* bookmarks */
22 static Bookmark bmarks[] = {
23 {'\\', "/root"},
26 /* openwith */
27 static const char *images[] = { "bmp", "jpg", "jpeg", "png", "gif", "xpm" };
28 static const char *web[] = { "htm", "html" };
29 static const char *pdf[] = { "epub", "pdf" };
30 static const char *arts[] = { "xcf" };
31 static const char *videos[] = { "avi", "flv", "wav", "webm", "wma", "wmv",
32 "m2v", "m4a", "m4v", "mkv", "mov", "mp3", "mp4", "mpeg", "mpg" };
33 static const char *documents[] = { "odt", "doc", "docx", "xls", "xlsx", "odp",
34 "ods", "pptx", "odg" };
36 static Rule rules[] = {
37 {"mpv", videos, LEN(videos) },
38 {"sxiv", images, LEN(images) },
39 {"firefox", web, LEN(web) },
40 {"mupdf", pdf, LEN(pdf) },
41 {"libreoffice", documents, LEN(documents) },
42 {"gimp", arts, LEN(arts) },
45 static Key keys[] = {
46 { {.ch = 'j'}, mvdwn },
47 { {.ch = 'k'}, mvup },
48 { {.ch = 'l'}, mvfor },
49 { {.ch = 'h'}, mvbk },
50 { {.ch = 'g'}, mvtop },
51 { {.ch = 'G'}, mvbtm },
52 { {.ch = 'M'}, mvmid },
53 { {.key = TB_KEY_CTRL_U}, scrup },
54 { {.key = TB_KEY_CTRL_D}, scrdwn },
55 { {.ch = 'n'}, crnf },
56 { {.ch = 'N'}, crnd },
57 { {.ch = 'D'}, delfd },
58 { {.ch = 'x'}, calcdir },
59 { {.ch = '/'}, filter },
60 { {.ch = 'q'}, quit },
61 { {.key = TB_KEY_SPACE}, switch_pane },
64 static const mode_t ndir_perm = S_IRWXU | S_IRWXG |S_IROTH | S_IXOTH;
65 static const mode_t nf_perm = S_IRUSR | S_IWUSR;
67 /* scroll */
68 static const size_t scrmv = 10; /* ctrl+u, ctrl+d movement */
69 static const size_t scrsp = 3; /* space before scroll */
71 /* statusbar */
72 static const int show_ug = 1;
73 static const int show_perm = 1;
74 static const int show_dt = 1;
75 static const int show_size = 1;
76 static const char dtfmt[] = "%F %R"; /* date time format */
78 /* unicode chars */
79 static const uint32_t u_cne = 0x2510;
80 static const uint32_t u_cnw = 0x250C;
81 static const uint32_t u_cse = 0x2518;
82 static const uint32_t u_csw = 0x2514;
83 static const uint32_t u_hl = 0x2500;
84 static const uint32_t u_mn = 0x252C;
85 static const uint32_t u_ms = 0x2534;
86 static const uint32_t u_vl = 0x2502;
88 #endif /* CONFIG_H */