-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpentadactylrc
58 lines (47 loc) · 1.52 KB
/
pentadactylrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
set runtimepath=/home/spenser/.pentadactyl
set scroll=80
"Use letters instead of numbers for hints
set hintkeys=asdfghjkl
set hlfind
set incfind
set defsearch=duckduckgo
set editor='xterm -e nvim -f +<line> +"sil! call cursor(0, <column>)" <file>'
colorscheme gruvbox-dark
" Move 5 units up or down
map -b j 5j
map -b k 5k
" Previous and next tab
map K <C-n>
map J <C-p>
highlight Hint font-family: sans-serif; font-size: 13px; font-weight: normal; color: black; background-color: #fffcc8 !important; border: 1px solid black; padding: 2px; line-height: 13px; text-transform: none;
highlight HintActive background-color: rgba(0,0,0,0) !important;
highlight HintElem background-color: rgba(0,0,0,0) !important;
imap -builtin <C-i> -javascript editExternallyWithFiletype()
style -name ublick * #nav-bar * { visibility: visible; }
javascript <<EOF
function editExternallyWithFiletype() {
var save_editor = options["editor"];
var filetype = editExternallyFiletype();
if (filetype) {
options["editor"] += " \"+setf " + filetype + "\"";
}
editor.editFieldExternally();
options["editor"] = save_editor;
}
EOF
javascript <<EOF
function editExternallyFiletype() {
var host = buffer.URL.host
switch(host.replace(/^www\./, "")) {
case "github.com":
if (! buffer.URL.path.match("/wiki/"))
return "markdown";
case "reddit.com":
return "markdown";
case "stackoverflow.com":
return "markdown";
}
if (host.match(/.*\.wikia\.com$/) || host.match(/.*\.wikipedia\.org$/))
return "mediawiki";
}
EOF