Solarized Dark curated dark
readability46/100dark96%bg#002b36fg#839496bg hue192°fg hue186°mean lightness48%saturation59%warmth+0.14mean hue74° yellowhue variation110°distinct hues7avg contrast5.0fg contrast4.7text on bgwhiteachromatic0
Colors
base03
base02
base01
base00
base0
base1
base2
base3
yellow
orange
red
magenta
violet
blue
cyan
green
roygcbpb
Ramp is sorted by WCAG relative luminance; the strip maps the 8 ANSI roles (base08–base0F).
Code sample
package main
import "fmt"
const (
Version = "1.2.0" // release
MaxTries = 3
)
type Server struct {
Host string
Port int
}
func (s *Server) start(tls bool) error {
addr := fmt.Sprintf("%s:%d", s.Host, s.Port)
if tls {
return listen(addr, 443)
}
return listen(addr, 80)
}
#!/usr/bin/env python3
# syntax sample: hex to hsl
import math
def hex_to_hsl(hex_code):
r = int(hex_code[1:3], 16) / 255
g = int(hex_code[3:5], 16) / 255
b = int(hex_code[5:7], 16) / 255
mx = max(r, g, b)
mn = min(r, g, b)
l = (mx + mn) / 2
return round(l * 100)
#!/bin/sh
# build the project and run tests
set -e
PREFIX="$HOME/.local"
VERSION="1.2.0"
for pkg in gcc make git; do
if ! command -v "$pkg" >/dev/null 2>&1; then
echo "missing dependency: $pkg"
fi
done
echo "building v$VERSION"
make -j4 && make test
Analysis
WCAG contrast matrix
| vs | base03 | base02 | base01 | base00 | base0 | base1 | base2 | base3 | yellow | orange | red | magenta | violet | blue | cyan | green |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| base03 | · | 1.2 | 2.8 | 3.4 | 4.7 | 5.6 | 12.3 | 13.9 | 4.7 | 3.3 | 3.2 | 3.3 | 3.4 | 4.1 | 4.8 | 4.7 |
| base02 | 1.2 | · | 2.4 | 2.9 | 4.1 | 4.9 | 10.6 | 12.1 | 4.1 | 2.8 | 2.8 | 2.9 | 3.0 | 3.5 | 4.1 | 4.1 |
| base01 | 2.8 | 2.4 | · | 1.2 | 1.7 | 2.0 | 4.4 | 5.0 | 1.7 | 1.2 | 1.2 | 1.2 | 1.2 |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1.2 | 1.4 | 3.0 | 3.4 | 1.1 | 1.3 | 1.3 | 1.2 | 1.2 | · | 1.2 | 1.1 |
| cyan | 4.8 | 4.1 | 1.7 | 1.4 | 1.0 | 1.2 | 2.6 | 2.9 | 1.0 | 1.5 | 1.5 | 1.4 | 1.4 | 1.2 | · | 1.0 |
| green | 4.7 | 4.1 | 1.7 | 1.4 | 1.0 | 1.2 | 2.6 | 3.0 | 1.0 | 1.4 | 1.4 | 1.4 | 1.4 | 1.1 | 1.0 | · |
Each cell is the WCAG contrast ratio between the row color and the column color (darker cell = higher ratio). ≥4.5 passes AA for normal text, ≥7 passes AAA.
Terminal
user@host:~/dev/scheme$ ls -la -rw-r--r-- 8.9K user main.go -rw-r--r-- 5.8K user preview.go -rwxr-xr-x 9.9M user colorexplorer drwxr-xr-x 4096 user cache/ lrwxrwxrwx 11 user site -> public -rw-r--r-- 2400 user bundle.zip user@host:~/dev/scheme$ git diff --stat diff --git a/main.go b/main.go --- a/main.go +++ b/main.go @@ -12,7 +12,8 @@ - addr := ":8080" + addr := ":9090"