-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathlightscheme.py
27 lines (26 loc) · 1.32 KB
/
lightscheme.py
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
from visidata import VisiData, Sheet
@Sheet.api
@VisiData.api
def use_light_colors(obj, flag=True):
if flag:
obj.options.color_default = 'black on white' # the default fg and bg colors
obj.options.color_key_col = '20 blue' # color of key columns
obj.options.color_edit_cell = '234 black' # cell color to use when editing cell
obj.options.color_selected_row = '164 magenta' # color of selected rows
obj.options.color_note_row = '164 magenta' # color of row note on left edge
obj.options.color_note_type = '88 red' # color of cell note for non-str types in anytype columns
obj.options.color_warning = '202 11 yellow'
obj.options.color_add_pending = '34 green'
obj.options.color_change_pending = '166 yellow'
obj.options.plot_colors = '20 red magenta black 28 88 94 99 106'
else:
obj.options.unset('color_default')
obj.options.unset('color_key_col')
obj.options.unset('color_edit_cell')
obj.options.unset('color_selected_row')
obj.options.unset('color_note_row')
obj.options.unset('color_note_type')
obj.options.unset('color_warning')
obj.options.unset('color_add_pending')
obj.options.unset('color_change_pending')
obj.options.unset('plot_colors')