autocolors 0.0.6 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/{notes → NOTES.md} +344 -3
- data/TODO.md +11 -0
- data/VERSION +1 -1
- data/autocolors.gemspec +10 -10
- data/fitness.md +27 -0
- data/lib/VERSION +1 -1
- data/lib/autocolors/color.rb +20 -0
- metadata +101 -149
data/{notes → NOTES.md}
RENAMED
@@ -1,3 +1,344 @@
|
|
1
|
+
GOAL / OVERVIEW
|
2
|
+
================
|
3
|
+
|
4
|
+
Maximizing balance + interestingness + information conveyed.
|
5
|
+
|
6
|
+
Balanced:: via principles of composition
|
7
|
+
Interesting:: via uniqueness & primal resonance (color-schemes attuned to human experiences)
|
8
|
+
Informative:: fast comprehension via advanced discovery and correctly applied emphasis and de-emphasis.
|
9
|
+
|
10
|
+
(These things could be tested for pretty easily at some point- for "first-time"
|
11
|
+
theme viewers and after they've gotten accustomed to it)
|
12
|
+
|
13
|
+
THEME ELEMENTS
|
14
|
+
===============
|
15
|
+
|
16
|
+
* Foreground
|
17
|
+
* Type
|
18
|
+
* Fonts
|
19
|
+
1. Mono
|
20
|
+
2. Sans-serif
|
21
|
+
3. Serif
|
22
|
+
4. Hybrid
|
23
|
+
* Weight
|
24
|
+
1. Thin/hairline
|
25
|
+
2. Normal
|
26
|
+
3. Semibold
|
27
|
+
4. Bold
|
28
|
+
* Decoration
|
29
|
+
- Italics?
|
30
|
+
- Underline?
|
31
|
+
- hue/chroma/lightness
|
32
|
+
- Strikethrough?
|
33
|
+
- Squiggly underline?
|
34
|
+
- hue/chroma/lightness
|
35
|
+
- Decorator glyph
|
36
|
+
- Indicator Triangle (folded corner)
|
37
|
+
-
|
38
|
+
- Smallcaps?
|
39
|
+
- Text shadow/glow?
|
40
|
+
- Strength
|
41
|
+
- hue/chroma/lightness/alpha/gradient
|
42
|
+
* Color
|
43
|
+
- Inverse?
|
44
|
+
- Hue/Chroma/Lightness/Alpha/Gradient
|
45
|
+
* Row indicator icon(s)
|
46
|
+
* Line Spacing (?)
|
47
|
+
* Background
|
48
|
+
- Hue/Chroma/Lightness/Alpha/Gradient
|
49
|
+
* Border/outline
|
50
|
+
- Thickness
|
51
|
+
- Hue/Chroma/Lightness/Alpha/Gradient
|
52
|
+
|
53
|
+
|
54
|
+
LAYERS
|
55
|
+
-------
|
56
|
+
* Other languages / embedded languages
|
57
|
+
* Interactive State
|
58
|
+
* Cursor:
|
59
|
+
* Current Row (cursor line)
|
60
|
+
* Under cursor
|
61
|
+
* Cursor Column
|
62
|
+
* Under cursor insert mode
|
63
|
+
* Matching
|
64
|
+
* Highlighted match
|
65
|
+
* IncSearch match
|
66
|
+
* Matching delimiter
|
67
|
+
* Blocks
|
68
|
+
* Normal
|
69
|
+
* Visual-mode
|
70
|
+
* Autowrap-block
|
71
|
+
* Runtime/debug State
|
72
|
+
* Set Breakpoint
|
73
|
+
* Current breakpoint
|
74
|
+
* Never-reached
|
75
|
+
* Ran
|
76
|
+
* Current paused line
|
77
|
+
* Diff
|
78
|
+
* Added
|
79
|
+
* Deleted
|
80
|
+
* Changed
|
81
|
+
* Static Analysis
|
82
|
+
* Spelling
|
83
|
+
* Bad spelling / error-construct
|
84
|
+
* Rare spelling / warning-construct
|
85
|
+
* Misc. spelling (grammar/caps...)
|
86
|
+
* Profiled
|
87
|
+
...
|
88
|
+
|
89
|
+
|
90
|
+
Question: can vim colorschemes be slightly more procedural? e.g., could you
|
91
|
+
have the background color different depending on a neighboring element?...
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
|
96
|
+
APPENDIX: COMPOSITION OVERVIEW
|
97
|
+
=======================
|
98
|
+
|
99
|
+
Mosly from http://www.etsimo.uniovi.es/hypgraph/design/composition/composition_main_page.htm
|
100
|
+
|
101
|
+
Unity / Harmony
|
102
|
+
---------------
|
103
|
+
* The mind tends to group objects that are close together into larger objects.
|
104
|
+
Especially if they share more attributes: size, shape, color, or value.
|
105
|
+
* Negative spaces also grouped.
|
106
|
+
* Interrupted objects perceived as if they were whole - mind fills in the gaps
|
107
|
+
so it's familiar in other contexts. (closure)
|
108
|
+
|
109
|
+
Methods of Emphasis
|
110
|
+
--------------------
|
111
|
+
* Through contrast
|
112
|
+
* Through tangents / different angle
|
113
|
+
* Through isolation
|
114
|
+
* Through drawing the eye to it w/ angles (see under balance)
|
115
|
+
* Through shape
|
116
|
+
* Through recognition
|
117
|
+
* Through motion
|
118
|
+
|
119
|
+
|
120
|
+
Balance
|
121
|
+
--------------
|
122
|
+
* (Balance around the optical center- usually a point slightly above the geometric
|
123
|
+
center)
|
124
|
+
* Contrast: every high contrast item balanced by larger spaces of lower contrast
|
125
|
+
* Color: small amount of high color balances larger area of dull color. Adjacent
|
126
|
+
complimentary colors weigh more than adjacent similar colors
|
127
|
+
* Shape & texture: small complicated shape can balance a large simple shape. Large
|
128
|
+
uncluttered area can balance small busy area. Complex areas can be put in
|
129
|
+
shadows, big simple shapes can be enhanced w/ bright lighting or broken up with
|
130
|
+
complex shadows / textures.
|
131
|
+
* Position: a small object further from the center balances a larger object
|
132
|
+
closer to the center.
|
133
|
+
* Balance by direction: Balance heavier side by having edges converging toward
|
134
|
+
lighter side to draw the eye in that direction. Also same color on opposite
|
135
|
+
sides can make the eye travel over.
|
136
|
+
* Perceived physical weight: "heavier" objects are more visually interesting than
|
137
|
+
lighter objects of the same size. - heaviness can be simulated by relative
|
138
|
+
density / whitespace rhythm within the object/group.
|
139
|
+
|
140
|
+
* Colors and visual weight:
|
141
|
+
- Hues
|
142
|
+
1. Red
|
143
|
+
2. Blue (possibly tied w/ #1 when all else is equal)
|
144
|
+
3. Green
|
145
|
+
4. Orange
|
146
|
+
5. Yellows
|
147
|
+
(BUT, warm mixes usually heavier than cool mixes)
|
148
|
+
- Dark heavier than light
|
149
|
+
- Saturated heavier than unsaturated
|
150
|
+
|
151
|
+
* Visually heavier: (from http://www.vanseodesign.com/web-design/visual-balance/ )
|
152
|
+
- Larger
|
153
|
+
- Regularly shaped (vs. irregular)
|
154
|
+
- Positive form (vs. negative space)
|
155
|
+
- Isolated
|
156
|
+
- Density
|
157
|
+
- Higher Contrast w/ immediate background
|
158
|
+
- Intrinsically more interesting
|
159
|
+
- Texture (vs. simple texture or none) (Block of text == rough/complex
|
160
|
+
texture)
|
161
|
+
- 3-d (v. 2-d)
|
162
|
+
- Depth of field (sharpness w/ surrounding blurriness)
|
163
|
+
- Perceived physical weight
|
164
|
+
- Distance from center
|
165
|
+
- Upper half heavier than lower half
|
166
|
+
- Right half heavier than left half
|
167
|
+
- Diagonally oriented > vertically oriented > horizontally oriented
|
168
|
+
- Position distance from natural axis' (x,y and 45degree diagonal version)
|
169
|
+
(Arnheim's structural net)
|
170
|
+
|
171
|
+
|
172
|
+
|
173
|
+
Scale and Proportion
|
174
|
+
-----------------------
|
175
|
+
* (Scale = overall size, proportion = relative size)
|
176
|
+
* Larger perceived as closer. Out of scale/proportion perceived heavily. Both
|
177
|
+
perceived as more important.
|
178
|
+
* Centered has little weight/importance. Thirds and golden ratio tend to create
|
179
|
+
interest / importance w/o over-emphasizing.
|
180
|
+
* Golden ratio (etc.) good for position, shadows, etc.
|
181
|
+
|
182
|
+
|
183
|
+
Repetition and Rhythm
|
184
|
+
----------------------
|
185
|
+
(see also unity/harmony - repetition "groups" things - gestalt)
|
186
|
+
* Same shape leads eye from one to the next - even if across the image
|
187
|
+
* Shape can obtain more visual weight by repetition - such as by its shadow.
|
188
|
+
|
189
|
+
Rythm - repetition of groups that are perceived as different but related -
|
190
|
+
usually by adding another attribute that is changing - so that they vary.
|
191
|
+
Curvilinear rhythms can calm and angular lines can stimulate.
|
192
|
+
|
193
|
+
Line and Contour
|
194
|
+
-----------------
|
195
|
+
1. Actual line
|
196
|
+
2. Implied line (via closure)
|
197
|
+
3. Psychic line (mental connection between elements) (such as eyeline)
|
198
|
+
|
199
|
+
Lines that lead to a visual object but don't reach it create tension (which
|
200
|
+
increases importance)
|
201
|
+
|
202
|
+
Horizontal lines imply stability,
|
203
|
+
Vertical lines imply motion,
|
204
|
+
Diagonal lines imply motion and depth.
|
205
|
+
|
206
|
+
Careful placement of lights can help create the lines you want in shadows.
|
207
|
+
|
208
|
+
|
209
|
+
|
210
|
+
|
211
|
+
|
212
|
+
|
213
|
+
GOAL: Maximize global balance and "interestingness" at the same time.
|
214
|
+
(possibly not as measurable) : Convey the most information possible as
|
215
|
+
quickly as possible.
|
216
|
+
|
217
|
+
|
218
|
+
[ASIDE - _what_ information would it be possible to convey?]
|
219
|
+
Usual
|
220
|
+
- syntactic role of groups of symbols
|
221
|
+
- builtin name vs. other names
|
222
|
+
- basic idea of the literal/constant type that the compiler/interpreter is
|
223
|
+
going to treat text as. (i.e., whoops, forgot the end-quote on my string)
|
224
|
+
Not-unheard-of
|
225
|
+
- stylistic concerns
|
226
|
+
- reek / roodi like analysis results
|
227
|
+
Unusual
|
228
|
+
- lint-like analysis results
|
229
|
+
- builtin name vs. other names vs. names defined in that module vs. names
|
230
|
+
defined just above vs. my own name (like in recursion)
|
231
|
+
- type infered to be held in variable
|
232
|
+
|
233
|
+
|
234
|
+
CONTEXTUAL EMPHASIS
|
235
|
+
--------------------
|
236
|
+
(possibly different list of emphasis points depending on-
|
237
|
+
- familiarity w/ code (how much you contributed, how many times you've seen
|
238
|
+
it, how much you've used it in an external context like calls into it)
|
239
|
+
[would, for example, determine how important comments are...]
|
240
|
+
- activity:
|
241
|
+
* understanding
|
242
|
+
* searching
|
243
|
+
* iterating (adding/subtracting/bug-fixing/...)
|
244
|
+
* running (stepping / debugging / runtime exception handling,
|
245
|
+
stacktraces...) (things that might be most important: author,
|
246
|
+
last-updated, error seen before ...)
|
247
|
+
- code-state:
|
248
|
+
* actively edited (in which case you may not want to see
|
249
|
+
trailing-whitespace errors, for example)
|
250
|
+
* age / number of times open/modified here (just like familiarity, but as
|
251
|
+
an indicator of the possible state of the code instead of the possible
|
252
|
+
familiarity of the user).
|
253
|
+
|
254
|
+
|
255
|
+
HIGHLIGHT GROUPS
|
256
|
+
-------------------
|
257
|
+
Highlight group types:
|
258
|
+
* __Plumbing__ - symbols to remove syntactical ambiguities, imports/etc. that
|
259
|
+
are used just to pull together the right dependencies but are too general
|
260
|
+
to give any meaningful insight into the code that follows (esp. if you can
|
261
|
+
require something and then not use it - potentially completely irrelevant
|
262
|
+
then to most activites/familiarities)
|
263
|
+
* __Syntactic discriminators__ - misc. syntactical symbols that are actually
|
264
|
+
important- implied a size/density disproportionate to importance, unlike
|
265
|
+
plumbing.
|
266
|
+
* __Control-flow__
|
267
|
+
- Domination heirarchy
|
268
|
+
- Reachability
|
269
|
+
- Run/branch-probability
|
270
|
+
* __Data-flow__. (?) Possibly redundant w/ or subject to discriminators
|
271
|
+
(showing types etc.) and syntactic discriminators (showing actual transfer
|
272
|
+
of data such as the assignment, dereferencing, or.
|
273
|
+
* __Descriptive__ / Attributive (adjectives such as static etc.)
|
274
|
+
* __Discriminators__ (keywords etc. - syntactically identical but
|
275
|
+
semantically infinitely variable).
|
276
|
+
- _Origin_ Groups: builtin vs. external library vs. internal module vs.
|
277
|
+
defined in this file vs. recursive in current context, etc.
|
278
|
+
- _Utilitarian_ Semantic Groups: could naively by different 'modules' - but
|
279
|
+
"web-related", vs. "math-related" vs. "framework-related" etc.
|
280
|
+
- _Side-effect_ group: (none, external i/o, destructive vs. non-destructive
|
281
|
+
etc.)
|
282
|
+
- _Data_ -flow/type groups: distinguished by the datatype it's infered to be
|
283
|
+
holding at that moment, possibility of null, ...
|
284
|
+
- _Convention_ (semantic) groups: for example - methods ending w/
|
285
|
+
questionmarks have are implemented the same but have different semantic
|
286
|
+
"assumptions."
|
287
|
+
* __Intrinsic__ (symbolic). (?) A name with all-caps is inherently
|
288
|
+
"different" already without syntax highlighting... Some languages use this
|
289
|
+
already to help further differentiate when in code blocks- like ruby and
|
290
|
+
erlang use of beginning-caps.
|
291
|
+
|
292
|
+
|
293
|
+
MECHANICS / IMPLEMENTATION
|
294
|
+
===========================
|
295
|
+
|
296
|
+
create monotone bases
|
297
|
+
+----------+---------------------+-------------------+
|
298
|
+
| name | light-scheme | dark-scheme |
|
299
|
+
+----------+---------------------+-------------------+
|
300
|
+
| light-3 | background | |-\
|
301
|
+
| light-2 | background-emph | | |
|
302
|
+
| light-1 | content-minor | content-emph | |-----
|
303
|
+
| light-0 | | content |--|\
|
304
|
+
| dark--0 | content | |-/ |
|
305
|
+
| dark--1 | content-emph | content-minor | |---
|
306
|
+
| dark--2 | | background-emph | |
|
307
|
+
| dark--3 | | background |---/
|
308
|
+
|
309
|
+
|
310
|
+
Hues
|
311
|
+
----
|
312
|
+
- 0.00: 0 | 0 | 0.000 | Blue
|
313
|
+
- 0.05: 0 | 0 | 0.000 | Blue
|
314
|
+
- 0.10: 0.25| 0.19 | 0.019 | Blue
|
315
|
+
- 0.15: 0.25| 0.19 | 0.038 | Sky blue
|
316
|
+
- 0.20: 0.25| 0.19 | 0.057 | Teal
|
317
|
+
- 0.25: 0.25| 0.19 | 0.076 | Teal
|
318
|
+
- 0.30: 0.3 | 0.23 | 0.099 | Green
|
319
|
+
- 0.35: 0.3 | 0.23 | 0.122 | Green
|
320
|
+
- 0.40: 0.4 | 0.3 | 0.152 | Green (2.0)
|
321
|
+
- 0.45: 1.0 | 0.76 | 0.228 | Puke Green
|
322
|
+
- 0.50: 2.0 | 1.52 | 0.380 | Browns/yellows
|
323
|
+
- 0.55: 2.0 | 1.52 | 0.532 | Orange
|
324
|
+
- 0.60: 1.0 | 0.76 | 0.608 | (Bright) Orange (8.0)
|
325
|
+
- 0.65: 0.6 | 0.45 | 0.653 | Orange / Red
|
326
|
+
- 0.70: 0.6 | 0.45 | 0.698 | Red / Bright Pink
|
327
|
+
- 0.75: 0.4 | 0.3 | 0.728 | Bright Pink / Pink (9.6)
|
328
|
+
- 0.80: 0.3 | 0.23 | 0.751 | Pink (9.9)
|
329
|
+
- 0.85: 0.4 | 0.3 | 0.781 | Dull pink
|
330
|
+
- 0.90: 1.0 | 0.76 | 0.857 | Purple
|
331
|
+
- 0.95: 1.5 | 1.14 | 0.971 | Dark blue (12.8)
|
332
|
+
- 1.00: 0.4 | 0.3 | 1.000 | Blue (13.2)
|
333
|
+
|
334
|
+
|
335
|
+
|
336
|
+
|
337
|
+
|
338
|
+
---------------------------------------------------------------------------------------------------
|
339
|
+
|
340
|
+
Older / Depricated Notes
|
341
|
+
========================
|
1
342
|
|
2
343
|
common approaches:
|
3
344
|
- type distance
|
@@ -6,7 +347,8 @@ common approaches:
|
|
6
347
|
- syntactic distance
|
7
348
|
|
8
349
|
|
9
|
-
- author vs. maintainer vs. reviewer vs. contributor ...
|
350
|
+
- author vs. maintainer vs. reviewer vs. contributor ... [better groups below
|
351
|
+
familiarity times activity]
|
10
352
|
- density / levels of distinction /
|
11
353
|
- structural vs. contextual (likelihood that, for example, you'll find it at the
|
12
354
|
beginning of a line with aligned indentation)
|
@@ -16,7 +358,7 @@ common approaches:
|
|
16
358
|
static function blahblah
|
17
359
|
^ ^ ^
|
18
360
|
| | +- discriminant
|
19
|
-
| +---------- structural
|
361
|
+
| +---------- structural (nix - call it plumbing or attribute below)
|
20
362
|
+----------------- qualifier/attribute
|
21
363
|
|
22
364
|
|
@@ -306,4 +648,3 @@ a hilight-section for each of t_Co in 8 / 16 / 88 / 256 / gui
|
|
306
648
|
hi Normal / and then
|
307
649
|
hi MainPart term=... cterm=... gui=... ctermfg=... ctermbg=... guifg=... guibg=...
|
308
650
|
|
309
|
-
|
data/TODO.md
CHANGED
@@ -1,3 +1,14 @@
|
|
1
|
+
## RELOADED ##
|
2
|
+
|
3
|
+
- [ ] Analyser for highlight group statistics
|
4
|
+
|
5
|
+
- [ ] Fitness criteria defined and designed, local and global
|
6
|
+
|
7
|
+
- [ ]
|
8
|
+
|
9
|
+
|
10
|
+
-----------------------------------
|
11
|
+
|
1
12
|
## Urgent ##
|
2
13
|
- [ ] Fix color spread variety (gets too close on deep syntax elements- not enough variety)
|
3
14
|
- [ ] Fix translation to 256-colorspace
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.7
|
data/autocolors.gemspec
CHANGED
@@ -4,15 +4,14 @@
|
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
|
-
s.name =
|
8
|
-
s.version = "0.0.
|
7
|
+
s.name = "autocolors"
|
8
|
+
s.version = "0.0.7"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Joseph Wecker"]
|
12
|
-
s.date =
|
13
|
-
s.
|
14
|
-
s.
|
15
|
-
s.email = %q{joseph.wecker@gmail.com}
|
12
|
+
s.date = "2011-10-02"
|
13
|
+
s.description = "Inspired by solarized, and lots of work with various colorschemes and syntax highlight files, and driven by a need to have some color variety that doesn't stink. Tries to generate colorschemes with just the right contrast, variety, and coherence."
|
14
|
+
s.email = "joseph.wecker@gmail.com"
|
16
15
|
s.executables = ["autocolors"]
|
17
16
|
s.extra_rdoc_files = [
|
18
17
|
"LICENSE.txt",
|
@@ -67,6 +66,7 @@ Gem::Specification.new do |s|
|
|
67
66
|
"Gemfile",
|
68
67
|
"Gemfile.lock",
|
69
68
|
"LICENSE.txt",
|
69
|
+
"NOTES.md",
|
70
70
|
"README.md",
|
71
71
|
"Rakefile",
|
72
72
|
"TODO.md",
|
@@ -80,6 +80,7 @@ Gem::Specification.new do |s|
|
|
80
80
|
"analysis/vim/statements.list",
|
81
81
|
"autocolors.gemspec",
|
82
82
|
"bin/autocolors",
|
83
|
+
"fitness.md",
|
83
84
|
"lib/VERSION",
|
84
85
|
"lib/autocolors.rb",
|
85
86
|
"lib/autocolors/color.rb",
|
@@ -87,7 +88,6 @@ Gem::Specification.new do |s|
|
|
87
88
|
"lib/autocolors/mapping.rb",
|
88
89
|
"lib/autocolors/mapping.udon",
|
89
90
|
"lib/autocolors/templates/colorscheme.erb.vim",
|
90
|
-
"notes",
|
91
91
|
"quicktest.html",
|
92
92
|
"quicktest_old.html",
|
93
93
|
"quicktest_old2.html",
|
@@ -96,11 +96,11 @@ Gem::Specification.new do |s|
|
|
96
96
|
"test/swatch.erb",
|
97
97
|
"test/test_autocolors.rb"
|
98
98
|
]
|
99
|
-
s.homepage =
|
99
|
+
s.homepage = "http://github.com/josephwecker/autocolors"
|
100
100
|
s.licenses = ["MIT"]
|
101
101
|
s.require_paths = ["lib"]
|
102
|
-
s.rubygems_version =
|
103
|
-
s.summary =
|
102
|
+
s.rubygems_version = "1.8.10"
|
103
|
+
s.summary = "Automatically generates colorschemes (mostly for editors)."
|
104
104
|
|
105
105
|
if s.respond_to? :specification_version then
|
106
106
|
s.specification_version = 3
|
data/fitness.md
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
Goal
|
2
|
+
=======
|
3
|
+
Maximizing balance + interestingness + information conveyed.
|
4
|
+
|
5
|
+
Balanced:: via principles of composition
|
6
|
+
Interesting:: via uniqueness & primal resonance (color-schemes attuned to human experiences)
|
7
|
+
Elucidative:: via correctly applied emphasis and de-emphasis.
|
8
|
+
|
9
|
+
|
10
|
+
Per Group Item
|
11
|
+
----------------
|
12
|
+
- Similarity to parent
|
13
|
+
- Difference from siblings
|
14
|
+
- Contrast w/ background vs. ideal
|
15
|
+
- Coherence with common neighbors
|
16
|
+
|
17
|
+
|
18
|
+
|
19
|
+
--------------------------
|
20
|
+
|
21
|
+
|
22
|
+
Highlight.JS
|
23
|
+
Pygments
|
24
|
+
SyntaxHighlighter
|
25
|
+
|
26
|
+
Ultraviolet (textmate)
|
27
|
+
|
data/lib/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.7
|
data/lib/autocolors/color.rb
CHANGED
@@ -53,6 +53,26 @@ module AutoColors
|
|
53
53
|
def hue; rad2turns(Math.atan2(ca, cb)) end
|
54
54
|
def chroma; Math::sqrt((ca * ca) + (cb * cb)) end
|
55
55
|
|
56
|
+
def hue_index=(v)
|
57
|
+
self.hue = [
|
58
|
+
0.0, # 0 | Blue
|
59
|
+
0.15, # 1 | Cyan
|
60
|
+
0.225, # 2 | Teal
|
61
|
+
0.33, # 3 | Green
|
62
|
+
0.4, # 4 | Forest green
|
63
|
+
0.45, # 5 | Puke green
|
64
|
+
0.5, # 6 | Yellow
|
65
|
+
0.565, # 7 | Orange
|
66
|
+
0.625, # 8 | Orange-red
|
67
|
+
0.6575, # 9 | Red
|
68
|
+
0.75, # 10 | Magenta
|
69
|
+
0.825, # 11 | Fuchsia
|
70
|
+
0.8875, # 12 | Pink
|
71
|
+
0.925, # 13 | Violet
|
72
|
+
0.95 # 14 | Indigo
|
73
|
+
][v.to_i]
|
74
|
+
end
|
75
|
+
|
56
76
|
def hue=(v)
|
57
77
|
r = turns2rad(v.to_f)
|
58
78
|
c = chroma
|
metadata
CHANGED
@@ -1,169 +1,127 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: autocolors
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.7
|
5
5
|
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 0
|
9
|
-
- 6
|
10
|
-
version: 0.0.6
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- Joseph Wecker
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
dependencies:
|
21
|
-
- !ruby/object:Gem::Dependency
|
22
|
-
type: :runtime
|
23
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
24
|
-
none: false
|
25
|
-
requirements:
|
26
|
-
- - ">="
|
27
|
-
- !ruby/object:Gem::Version
|
28
|
-
hash: 3
|
29
|
-
segments:
|
30
|
-
- 0
|
31
|
-
version: "0"
|
12
|
+
date: 2011-10-02 00:00:00.000000000Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
32
15
|
name: webster
|
33
|
-
|
34
|
-
prerelease: false
|
35
|
-
- !ruby/object:Gem::Dependency
|
36
|
-
type: :development
|
37
|
-
requirement: &id002 !ruby/object:Gem::Requirement
|
16
|
+
requirement: &2152367440 !ruby/object:Gem::Requirement
|
38
17
|
none: false
|
39
|
-
requirements:
|
40
|
-
- -
|
41
|
-
- !ruby/object:Gem::Version
|
42
|
-
|
43
|
-
|
44
|
-
- 0
|
45
|
-
version: "0"
|
46
|
-
name: minitest
|
47
|
-
version_requirements: *id002
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '0'
|
22
|
+
type: :runtime
|
48
23
|
prerelease: false
|
49
|
-
|
24
|
+
version_requirements: *2152367440
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: minitest
|
27
|
+
requirement: &2152365800 !ruby/object:Gem::Requirement
|
28
|
+
none: false
|
29
|
+
requirements:
|
30
|
+
- - ! '>='
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '0'
|
50
33
|
type: :development
|
51
|
-
|
34
|
+
prerelease: false
|
35
|
+
version_requirements: *2152365800
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: yard
|
38
|
+
requirement: &2152364040 !ruby/object:Gem::Requirement
|
52
39
|
none: false
|
53
|
-
requirements:
|
40
|
+
requirements:
|
54
41
|
- - ~>
|
55
|
-
- !ruby/object:Gem::Version
|
56
|
-
hash: 7
|
57
|
-
segments:
|
58
|
-
- 0
|
59
|
-
- 6
|
60
|
-
- 0
|
42
|
+
- !ruby/object:Gem::Version
|
61
43
|
version: 0.6.0
|
62
|
-
name: yard
|
63
|
-
version_requirements: *id003
|
64
|
-
prerelease: false
|
65
|
-
- !ruby/object:Gem::Dependency
|
66
44
|
type: :development
|
67
|
-
|
45
|
+
prerelease: false
|
46
|
+
version_requirements: *2152364040
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: bundler
|
49
|
+
requirement: &2152358200 !ruby/object:Gem::Requirement
|
68
50
|
none: false
|
69
|
-
requirements:
|
51
|
+
requirements:
|
70
52
|
- - ~>
|
71
|
-
- !ruby/object:Gem::Version
|
72
|
-
hash: 23
|
73
|
-
segments:
|
74
|
-
- 1
|
75
|
-
- 0
|
76
|
-
- 0
|
53
|
+
- !ruby/object:Gem::Version
|
77
54
|
version: 1.0.0
|
78
|
-
name: bundler
|
79
|
-
version_requirements: *id004
|
80
|
-
prerelease: false
|
81
|
-
- !ruby/object:Gem::Dependency
|
82
55
|
type: :development
|
83
|
-
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: *2152358200
|
58
|
+
- !ruby/object:Gem::Dependency
|
59
|
+
name: jeweler
|
60
|
+
requirement: &2152353680 !ruby/object:Gem::Requirement
|
84
61
|
none: false
|
85
|
-
requirements:
|
62
|
+
requirements:
|
86
63
|
- - ~>
|
87
|
-
- !ruby/object:Gem::Version
|
88
|
-
hash: 7
|
89
|
-
segments:
|
90
|
-
- 1
|
91
|
-
- 6
|
92
|
-
- 4
|
64
|
+
- !ruby/object:Gem::Version
|
93
65
|
version: 1.6.4
|
94
|
-
name: jeweler
|
95
|
-
version_requirements: *id005
|
96
|
-
prerelease: false
|
97
|
-
- !ruby/object:Gem::Dependency
|
98
66
|
type: :development
|
99
|
-
requirement: &id006 !ruby/object:Gem::Requirement
|
100
|
-
none: false
|
101
|
-
requirements:
|
102
|
-
- - ">="
|
103
|
-
- !ruby/object:Gem::Version
|
104
|
-
hash: 3
|
105
|
-
segments:
|
106
|
-
- 0
|
107
|
-
version: "0"
|
108
|
-
name: rcov
|
109
|
-
version_requirements: *id006
|
110
67
|
prerelease: false
|
111
|
-
|
68
|
+
version_requirements: *2152353680
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rcov
|
71
|
+
requirement: &2152348480 !ruby/object:Gem::Requirement
|
72
|
+
none: false
|
73
|
+
requirements:
|
74
|
+
- - ! '>='
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: '0'
|
112
77
|
type: :development
|
113
|
-
|
78
|
+
prerelease: false
|
79
|
+
version_requirements: *2152348480
|
80
|
+
- !ruby/object:Gem::Dependency
|
81
|
+
name: reek
|
82
|
+
requirement: &2152341260 !ruby/object:Gem::Requirement
|
114
83
|
none: false
|
115
|
-
requirements:
|
84
|
+
requirements:
|
116
85
|
- - ~>
|
117
|
-
- !ruby/object:Gem::Version
|
118
|
-
hash: 15
|
119
|
-
segments:
|
120
|
-
- 1
|
121
|
-
- 2
|
122
|
-
- 8
|
86
|
+
- !ruby/object:Gem::Version
|
123
87
|
version: 1.2.8
|
124
|
-
name: reek
|
125
|
-
version_requirements: *id007
|
126
|
-
prerelease: false
|
127
|
-
- !ruby/object:Gem::Dependency
|
128
88
|
type: :development
|
129
|
-
|
89
|
+
prerelease: false
|
90
|
+
version_requirements: *2152341260
|
91
|
+
- !ruby/object:Gem::Dependency
|
92
|
+
name: roodi
|
93
|
+
requirement: &2152338160 !ruby/object:Gem::Requirement
|
130
94
|
none: false
|
131
|
-
requirements:
|
95
|
+
requirements:
|
132
96
|
- - ~>
|
133
|
-
- !ruby/object:Gem::Version
|
134
|
-
hash: 11
|
135
|
-
segments:
|
136
|
-
- 2
|
137
|
-
- 1
|
138
|
-
- 0
|
97
|
+
- !ruby/object:Gem::Version
|
139
98
|
version: 2.1.0
|
140
|
-
name: roodi
|
141
|
-
version_requirements: *id008
|
142
|
-
prerelease: false
|
143
|
-
- !ruby/object:Gem::Dependency
|
144
99
|
type: :development
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
- - ">="
|
149
|
-
- !ruby/object:Gem::Version
|
150
|
-
hash: 3
|
151
|
-
segments:
|
152
|
-
- 0
|
153
|
-
version: "0"
|
100
|
+
prerelease: false
|
101
|
+
version_requirements: *2152338160
|
102
|
+
- !ruby/object:Gem::Dependency
|
154
103
|
name: bluecloth
|
155
|
-
|
104
|
+
requirement: &2152329200 !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ! '>='
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: '0'
|
110
|
+
type: :development
|
156
111
|
prerelease: false
|
157
|
-
|
112
|
+
version_requirements: *2152329200
|
113
|
+
description: Inspired by solarized, and lots of work with various colorschemes and
|
114
|
+
syntax highlight files, and driven by a need to have some color variety that doesn't
|
115
|
+
stink. Tries to generate colorschemes with just the right contrast, variety, and
|
116
|
+
coherence.
|
158
117
|
email: joseph.wecker@gmail.com
|
159
|
-
executables:
|
118
|
+
executables:
|
160
119
|
- autocolors
|
161
120
|
extensions: []
|
162
|
-
|
163
|
-
extra_rdoc_files:
|
121
|
+
extra_rdoc_files:
|
164
122
|
- LICENSE.txt
|
165
123
|
- README.md
|
166
|
-
files:
|
124
|
+
files:
|
167
125
|
- .attic/colors.rb
|
168
126
|
- .attic/colorscheme-v3.old.rb
|
169
127
|
- .attic/colorscheme.rb
|
@@ -212,6 +170,7 @@ files:
|
|
212
170
|
- Gemfile
|
213
171
|
- Gemfile.lock
|
214
172
|
- LICENSE.txt
|
173
|
+
- NOTES.md
|
215
174
|
- README.md
|
216
175
|
- Rakefile
|
217
176
|
- TODO.md
|
@@ -225,6 +184,7 @@ files:
|
|
225
184
|
- analysis/vim/statements.list
|
226
185
|
- autocolors.gemspec
|
227
186
|
- bin/autocolors
|
187
|
+
- fitness.md
|
228
188
|
- lib/VERSION
|
229
189
|
- lib/autocolors.rb
|
230
190
|
- lib/autocolors/color.rb
|
@@ -232,7 +192,6 @@ files:
|
|
232
192
|
- lib/autocolors/mapping.rb
|
233
193
|
- lib/autocolors/mapping.udon
|
234
194
|
- lib/autocolors/templates/colorscheme.erb.vim
|
235
|
-
- notes
|
236
195
|
- quicktest.html
|
237
196
|
- quicktest_old.html
|
238
197
|
- quicktest_old2.html
|
@@ -240,39 +199,32 @@ files:
|
|
240
199
|
- test/helper.rb
|
241
200
|
- test/swatch.erb
|
242
201
|
- test/test_autocolors.rb
|
243
|
-
has_rdoc: true
|
244
202
|
homepage: http://github.com/josephwecker/autocolors
|
245
|
-
licenses:
|
203
|
+
licenses:
|
246
204
|
- MIT
|
247
205
|
post_install_message:
|
248
206
|
rdoc_options: []
|
249
|
-
|
250
|
-
require_paths:
|
207
|
+
require_paths:
|
251
208
|
- lib
|
252
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
209
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
253
210
|
none: false
|
254
|
-
requirements:
|
255
|
-
- -
|
256
|
-
- !ruby/object:Gem::Version
|
257
|
-
|
258
|
-
segments:
|
211
|
+
requirements:
|
212
|
+
- - ! '>='
|
213
|
+
- !ruby/object:Gem::Version
|
214
|
+
version: '0'
|
215
|
+
segments:
|
259
216
|
- 0
|
260
|
-
|
261
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
217
|
+
hash: 718123813266028940
|
218
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
262
219
|
none: false
|
263
|
-
requirements:
|
264
|
-
- -
|
265
|
-
- !ruby/object:Gem::Version
|
266
|
-
|
267
|
-
segments:
|
268
|
-
- 0
|
269
|
-
version: "0"
|
220
|
+
requirements:
|
221
|
+
- - ! '>='
|
222
|
+
- !ruby/object:Gem::Version
|
223
|
+
version: '0'
|
270
224
|
requirements: []
|
271
|
-
|
272
225
|
rubyforge_project:
|
273
|
-
rubygems_version: 1.
|
226
|
+
rubygems_version: 1.8.10
|
274
227
|
signing_key:
|
275
228
|
specification_version: 3
|
276
229
|
summary: Automatically generates colorschemes (mostly for editors).
|
277
230
|
test_files: []
|
278
|
-
|