aboutsummaryrefslogtreecommitdiff
path: root/config/qutebrowser/config.py
blob: b31dedd120551c067b5c6b6c6007eb61025ba943 (plain)
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
import os

# Keybindings
config.bind('x', 'spawn mpv {url}')
config.bind(',x', 'hint links spawn mpv {hint-url}')

config.bind('<Ctrl-l>', 'spawn --userscript password_fill')

terminal = os.environ['TERMINAL']
if terminal in ["st", "urxvt"]:
    c.editor.command = [terminal, "-e", os.environ['VISUAL'],  "{}"]
else:
    c.editor.command = [terminal, "-e", f"{os.environ['VISUAL']} {{}}"]

c.content.headers.do_not_track = True

# Disable javascript by default
config.set('content.javascript.enabled', False)

# Load autoconfig to enable javascript on trusted domains
config.load_autoconfig()

# Load theme
import theme

# set qutebrowser colors
for setting, color in theme.theme.items():
    config.set(setting, color)

# request dark mode from pages
config.set("colors.webpage.prefers_color_scheme_dark", True)