-
Notifications
You must be signed in to change notification settings - Fork 728
/
base16.rb
134 lines (111 loc) · 3.46 KB
/
base16.rb
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
# -*- coding: utf-8 -*- #
# frozen_string_literal: true
module Rouge
module Themes
# default base16 theme
# by Chris Kempson (http://chriskempson.com)
class Base16 < CSSTheme
name 'base16'
palette base00: "#151515"
palette base01: "#202020"
palette base02: "#303030"
palette base03: "#505050"
palette base04: "#b0b0b0"
palette base05: "#d0d0d0"
palette base06: "#e0e0e0"
palette base07: "#f5f5f5"
palette base08: "#ac4142"
palette base09: "#d28445"
palette base0A: "#f4bf75"
palette base0B: "#90a959"
palette base0C: "#75b5aa"
palette base0D: "#6a9fb5"
palette base0E: "#aa759f"
palette base0F: "#8f5536"
extend HasModes
def self.light!
mode :dark # indicate that there is a dark variant
mode! :light
end
def self.dark!
mode :light # indicate that there is a light variant
mode! :dark
end
def self.make_dark!
style Text, :fg => :base05, :bg => :base00
end
def self.make_light!
style Text, :fg => :base02
end
light!
style Error, :fg => :base00, :bg => :base08
style Comment, :fg => :base03
style Operator,
Punctuation, :fg => :base05
style Generic::Deleted,
Name, :fg => :base08
style Keyword::Constant,
Keyword::Declaration,
Keyword::Type,
Literal::Number, :fg => :base09
style Comment::Preproc,
Name::Class,
Name::Constant,
Name::Namespace,
Name::Tag, :fg => :base0A
style Generic::Inserted,
Literal::String,
Literal::String::Symbol, :fg => :base0B
style Literal::String::Regex, :fg => :base0C
style Name::Attribute,
Name::Function, :fg => :base0D
style Generic::Heading, :fg => :base0D, :bg => :base00, :bold => true
style Keyword,
Literal::String::Affix, :fg => :base0E
style Literal::String::Escape,
Literal::String::Interpol, :fg => :base0F
class Solarized < Base16
name 'base16.solarized'
light!
# author "Ethan Schoonover (http://ethanschoonover.com/solarized)"
palette base00: "#002b36"
palette base01: "#073642"
palette base02: "#586e75"
palette base03: "#657b83"
palette base04: "#839496"
palette base05: "#93a1a1"
palette base06: "#eee8d5"
palette base07: "#fdf6e3"
palette base08: "#dc322f"
palette base09: "#cb4b16"
palette base0A: "#b58900"
palette base0B: "#859900"
palette base0C: "#2aa198"
palette base0D: "#268bd2"
palette base0E: "#6c71c4"
palette base0F: "#d33682"
end
class Monokai < Base16
name 'base16.monokai'
dark!
# author "Wimer Hazenberg (http://www.monokai.nl)"
palette base00: "#272822"
palette base01: "#383830"
palette base02: "#49483e"
palette base03: "#75715e"
palette base04: "#a59f85"
palette base05: "#f8f8f2"
palette base06: "#f5f4f1"
palette base07: "#f9f8f5"
palette base08: "#f92672"
palette base09: "#fd971f"
palette base0A: "#f4bf75"
palette base0B: "#a6e22e"
palette base0C: "#a1efe4"
palette base0D: "#66d9ef"
palette base0E: "#ae81ff"
palette base0F: "#cc6633"
end
end
end
end