Open source
Code themes
Ten themes for code editors and terminals. Eight are the contrast themes from the Zacess reader: Light, Dark, Yellow on Black, Cream, High Contrast Dark, High Contrast Light, Deep Contrast Dark and Deep Contrast Light, with every text and syntax colour at 7:1 or more. Warm Dark and Warm Light are the gentler pair for anyone who finds high contrast too intense: body text at about 12:1 in warm, earthy colours, with every text and syntax colour at 4.5:1 or more.
We build the themes for VS Code, JetBrains IDEs, Obsidian, Neovim, Zed, Sublime Text, Helix, Emacs, Eclipse, Xcode and eight terminals. They are on the VS Code Marketplace, Open VSX, the JetBrains Marketplace and the Eclipse Marketplace and in the Obsidian community directory and the Zed extension store. Neovim installs them from zacess.nvim. The eight contrast themes are in the iTerm2 Color Schemes collection. Sublime Text, Helix, Emacs, Xcode and the terminals install from the releases page or the themes repository. The browser themes are in the Chrome Web Store and on Firefox Add-ons.
Try a theme
Choose a theme and a language. The sample is coloured by the same theme files the editor extensions ship, with the theme's contrast figures underneath.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}Loading
TypeScript
The TypeScript sample from the code themes playground.
Rendered with the Zacess Light editor theme.
- Background
#ffffff- Text
#111111- Lowest on the background
- 8.2:1
- Lowest measured contrast
- 7.1:1
- Target
- 7:1 (WCAG AAA)
- Background
#121212- Text
#f5f5f5- Lowest on the background
- 8.5:1
- Lowest measured contrast
- 7.0:1
- Target
- 7:1 (WCAG AAA)
- Background
#000000- Text
#ffeb3b- Lowest on the background
- 9.7:1
- Lowest measured contrast
- 7.0:1
- Target
- 7:1 (WCAG AAA)
- Background
#fdf6e3- Text
#000000- Lowest on the background
- 8.4:1
- Lowest measured contrast
- 7.3:1
- Target
- 7:1 (WCAG AAA)
- Background
#000000- Text
#ffffff- Lowest on the background
- 9.9:1
- Lowest measured contrast
- 7.1:1
- Target
- 7:1 (WCAG AAA)
- Background
#ffffff- Text
#000000- Lowest on the background
- 8.6:1
- Lowest measured contrast
- 7.1:1
- Target
- 7:1 (WCAG AAA)
- Background
#000000- Text
#ffffff- Lowest on the background
- 9.0:1
- Lowest measured contrast
- 7.0:1
- Target
- 7:1 (WCAG AAA)
- Background
#ffffff- Text
#000000- Lowest on the background
- 7.7:1
- Lowest measured contrast
- 7.0:1
- Target
- 7:1 (WCAG AAA)
- Background
#211b17- Text
#e5d5b6- Lowest on the background
- 8.0:1
- Lowest measured contrast
- 5.7:1
- Target
- 4.5:1 (WCAG AA)
- Background
#f4ead5- Text
#342410- Lowest on the background
- 6.0:1
- Lowest measured contrast
- 5.0:1
- Target
- 4.5:1 (WCAG AA)
All ten themes
The chosen language in every theme, so the ten can be compared side by side. The lowest ratio is measured over the selection, the current line and the diff colours, where text is hardest to read. The lowest code colour on the plain background is shown with each theme above.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}Everyday reading in a bright room. Lowest contrast 7.1:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}Everyday reading in a dim room. Lowest contrast 7.0:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}Low vision. Lowest contrast 7.0:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}Dyslexia friendly reading. Lowest contrast 7.3:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}The highest contrast on a light screen. Lowest contrast 7.1:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
// a reading profile, saved one file per profile
export interface Profile {
name: string;
fontSize: number;
theme: "dark_on_light" | "yellow_on_black";
}
const AAA = 7;
/** WCAG relative luminance of a #rrggbb colour */
function luminance(hex: string): number {
const [r, g, b] = [1, 3, 5].map((i) => parseInt(hex.slice(i, i + 2), 16) / 255);
const lin = (c: number) => (c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4);
return 0.2126 * lin(r) + 0.7152 * lin(g) + 0.0722 * lin(b);
}
export function passes(text: string, background: string): boolean {
const [hi, lo] = [luminance(text), luminance(background)].sort((x, y) => y - x);
const ratio = (hi + 0.05) / (lo + 0.05);
if (ratio < AAA) {
console.warn(`only ${ratio.toFixed(2)}:1`);
}
return ratio >= AAA;
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}Everyday reading in a bright room. Lowest contrast 7.1:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}Everyday reading in a dim room. Lowest contrast 7.0:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}Low vision. Lowest contrast 7.0:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}Dyslexia friendly reading. Lowest contrast 7.3:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}The highest contrast on a light screen. Lowest contrast 7.1:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
// read a page aloud one sentence at a time, highlighting each word
const synth = window.speechSynthesis;
const rate = Number(localStorage.getItem("rate") ?? 1.0);
export async function readAloud(page) {
const sentences = page.text.split(/(?<=[.!?])\s+/);
for (const [index, sentence] of sentences.entries()) {
await speak(sentence, index);
}
}
function speak(sentence, index) {
return new Promise((resolve, reject) => {
const utterance = new SpeechSynthesisUtterance(sentence);
utterance.rate = rate;
utterance.onboundary = (event) => highlight(index, event.charIndex);
utterance.onend = resolve;
utterance.onerror = reject;
synth.speak(utterance);
});
}
class ReadingRuler extends HTMLElement {
static observedAttributes = ["lines"];
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")Everyday reading in a bright room. Lowest contrast 7.1:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")Everyday reading in a dim room. Lowest contrast 7.0:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")Low vision. Lowest contrast 7.0:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")Dyslexia friendly reading. Lowest contrast 7.3:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")The highest contrast on a dark screen. Lowest contrast 7.1:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")The highest contrast on a light screen. Lowest contrast 7.1:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
"""Score OCR output against a known transcript."""
from dataclasses import dataclass
from pathlib import Path
LOW_CONFIDENCE = 0.80
@dataclass
class Word:
text: str
confidence: float
@property
def needs_check(self) -> bool:
return self.confidence < LOW_CONFIDENCE
def flagged(words: list[Word]) -> list[str]:
# a misread number matters more than a misread word
return [w.text for w in words if w.needs_check or w.text.isdigit()]
if __name__ == "__main__":
words = [Word("7:1", 0.62), Word("contrast", 0.97)]
print(f"{len(flagged(words))} words to check in {Path.cwd().name}")A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}Everyday reading in a bright room. Lowest contrast 7.1:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}Everyday reading in a dim room. Lowest contrast 7.0:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}Low vision. Lowest contrast 7.0:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}Dyslexia friendly reading. Lowest contrast 7.3:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}The highest contrast on a light screen. Lowest contrast 7.1:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
use std::fmt;
/// A contrast theme from the reader's profile.
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Contrast {
DarkOnLight,
LightOnDark,
YellowOnBlack,
BlackOnCream,
HighContrastDark,
HighContrastLight,
DeepContrastDark,
DeepContrastLight,
}
impl Contrast {
pub fn colours(self) -> (&'static str, &'static str) {
match self {
Contrast::DarkOnLight => ("#111111", "#ffffff"),
Contrast::LightOnDark => ("#f5f5f5", "#121212"),
Contrast::YellowOnBlack => ("#ffeb3b", "#000000"),
Contrast::BlackOnCream => ("#000000", "#fdf6e3"),
Contrast::HighContrastDark => ("#ffffff", "#000000"),
Contrast::HighContrastLight => ("#000000", "#ffffff"),
Contrast::DeepContrastDark => ("#ffffff", "#000000"),
Contrast::DeepContrastLight => ("#000000", "#ffffff"),
}
}
}
impl fmt::Display for Contrast {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
let (text, background) = self.colours();
write!(f, "{text} on {background}")
}
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}Everyday reading in a bright room. Lowest contrast 7.1:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}Everyday reading in a dim room. Lowest contrast 7.0:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}Low vision. Lowest contrast 7.0:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}Dyslexia friendly reading. Lowest contrast 7.3:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}The highest contrast on a light screen. Lowest contrast 7.1:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
package com.zacess.library;
import java.time.Instant;
import java.util.ArrayList;
import java.util.List;
/** Keeps every saved version of a note so nothing is lost. */
public final class VersionHistory {
private static final int MAX_VERSIONS = 50;
private final List<Version> versions = new ArrayList<>();
public record Version(String text, Instant savedAt) {}
public void save(String text) {
if (text == null || text.isBlank()) {
throw new IllegalArgumentException("empty note");
}
versions.add(new Version(text, Instant.now()));
while (versions.size() > MAX_VERSIONS) {
versions.remove(0);
}
}
public Version latest() {
return versions.get(versions.size() - 1);
}
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}Everyday reading in a bright room. Lowest contrast 7.1:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}Everyday reading in a dim room. Lowest contrast 7.0:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}Low vision. Lowest contrast 7.0:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}Dyslexia friendly reading. Lowest contrast 7.3:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}The highest contrast on a light screen. Lowest contrast 7.1:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
/* the linear value of one sRGB channel, 0 to 255 */
static double channel(unsigned value) {
double c = value / 255.0;
return c <= 0.04045 ? c / 12.92 : pow((c + 0.055) / 1.055, 2.4);
}
static double luminance(unsigned rgb) {
return 0.2126 * channel(rgb >> 16 & 0xff)
+ 0.7152 * channel(rgb >> 8 & 0xff)
+ 0.0722 * channel(rgb & 0xff);
}
int main(int argc, char **argv) {
if (argc != 3) {
fprintf(stderr, "usage: %s text background\n", argv[0]);
return EXIT_FAILURE;
}
double a = luminance(strtoul(argv[1], NULL, 16));
double b = luminance(strtoul(argv[2], NULL, 16));
printf("%.2f:1\n", (fmax(a, b) + 0.05) / (fmin(a, b) + 0.05));
return EXIT_SUCCESS;
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}Everyday reading in a bright room. Lowest contrast 7.1:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}Everyday reading in a dim room. Lowest contrast 7.0:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}Low vision. Lowest contrast 7.0:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}Dyslexia friendly reading. Lowest contrast 7.3:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}The highest contrast on a light screen. Lowest contrast 7.1:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
#include <algorithm>
#include <string>
#include <vector>
namespace zacess {
// one line of a page with the confidence of its weakest word
struct Line {
std::string text;
float confidence = 1.0F;
};
template <typename Range>
auto weakest(const Range& lines, std::size_t count) {
std::vector<Line> sorted(std::begin(lines), std::end(lines));
std::ranges::sort(sorted, {}, &Line::confidence);
sorted.resize(std::min(count, sorted.size()));
return sorted;
}
constexpr auto kReviewBelow = 0.8F;
} // namespace zacess
int main() {
const std::vector<zacess::Line> page{{"Figure 3", 0.55F}, {"Results", 0.98F}};
return zacess::weakest(page, 1).front().confidence < zacess::kReviewBelow ? 1 : 0;
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}Everyday reading in a bright room. Lowest contrast 7.1:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}Everyday reading in a dim room. Lowest contrast 7.0:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}Low vision. Lowest contrast 7.0:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}Dyslexia friendly reading. Lowest contrast 7.3:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}The highest contrast on a light screen. Lowest contrast 7.1:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
using System;
using System.Collections.Generic;
using System.Linq;
namespace Zacess.Study;
/// <summary>A flashcard scheduled by how well it was remembered.</summary>
public sealed record Card(string Front, string Back, DateTime Due);
public static class Scheduler
{
private const double Growth = 2.5;
public static Card Review(Card card, bool remembered, int intervalDays)
{
var next = remembered ? (int)Math.Ceiling(intervalDays * Growth) : 1;
return card with { Due = DateTime.UtcNow.AddDays(next) };
}
public static IEnumerable<Card> DueToday(IEnumerable<Card> deck) =>
deck.Where(c => c.Due <= DateTime.UtcNow)
.OrderBy(c => c.Due);
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}Everyday reading in a bright room. Lowest contrast 7.1:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}Everyday reading in a dim room. Lowest contrast 7.0:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}Low vision. Lowest contrast 7.0:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}Dyslexia friendly reading. Lowest contrast 7.3:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}The highest contrast on a light screen. Lowest contrast 7.1:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
package export
import (
"fmt"
"html"
"strings"
)
// Heading is one entry in a document's outline.
type Heading struct {
Level int
Text string
}
// HTML writes the outline as nested headings, never skipping a level.
func HTML(headings []Heading) (string, error) {
var b strings.Builder
previous := 0
for i, h := range headings {
if h.Level > previous+1 {
return "", fmt.Errorf("heading %d jumps from h%d to h%d", i, previous, h.Level)
}
fmt.Fprintf(&b, "<h%d>%s</h%d>\n", h.Level, html.EscapeString(h.Text), h.Level)
previous = h.Level
}
return b.String(), nil
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}Everyday reading in a bright room. Lowest contrast 7.1:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}Everyday reading in a dim room. Lowest contrast 7.0:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}Low vision. Lowest contrast 7.0:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}Dyslexia friendly reading. Lowest contrast 7.3:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}The highest contrast on a light screen. Lowest contrast 7.1:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
<?php
declare(strict_types=1);
namespace Zacess\Feedback;
use InvalidArgumentException;
/**
* Stores a barrier report without asking for a diagnosis.
*/
final class BarrierReport
{
public function __construct(
public readonly string $whatHappened,
public readonly ?string $assistiveTech = null,
) {
if (trim($whatHappened) === '') {
throw new InvalidArgumentException('Tell us what got in the way.');
}
}
public function summary(int $length = 80): string
{
return mb_strimwidth($this->whatHappened, 0, $length, '...');
}
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endEveryday reading in a bright room. Lowest contrast 7.1:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endEveryday reading in a dim room. Lowest contrast 7.0:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endLow vision. Lowest contrast 7.0:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endDyslexia friendly reading. Lowest contrast 7.3:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endThe highest contrast on a dark screen. Lowest contrast 7.1:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endThe highest contrast on a light screen. Lowest contrast 7.1:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endLow vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endLow vision, with vivid deep colours on white. Lowest contrast 7.0:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endA gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
# frozen_string_literal: true
require "json"
# Imports a reading profile exported from another device.
class ProfileImport
PRESETS = %w[low_vision dyslexia_friendly reduced_clutter screen_reader].freeze
attr_reader :errors
def initialize(path)
@data = JSON.parse(File.read(path), symbolize_names: true)
@errors = []
end
def valid?
errors << "unknown preset" unless PRESETS.include?(@data[:preset])
errors << "size must be 8 to 72" unless (8..72).cover?(@data[:font_size].to_i)
errors.empty?
end
def to_s = "#{@data[:name]} (#{@data[:preset]})"
endA gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}Everyday reading in a bright room. Lowest contrast 7.1:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}Everyday reading in a dim room. Lowest contrast 7.0:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}Low vision. Lowest contrast 7.0:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}Dyslexia friendly reading. Lowest contrast 7.3:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}The highest contrast on a light screen. Lowest contrast 7.1:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
import SwiftUI
/// A page shown in the reader's own profile.
struct ReadingView: View {
let page: Page
@AppStorage("fontSize") private var fontSize = 24.0
@Environment(\.accessibilityReduceMotion) private var reduceMotion
var body: some View {
ScrollView {
Text(page.text)
.font(.custom("Atkinson Hyperlegible", size: fontSize))
.lineSpacing(fontSize * 0.6)
.foregroundStyle(Color(hex: 0xFFEB3B))
.padding()
}
.background(Color.black)
.animation(reduceMotion ? nil : .easeInOut, value: fontSize)
.accessibilityLabel(page.title)
}
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}Everyday reading in a bright room. Lowest contrast 7.1:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}Everyday reading in a dim room. Lowest contrast 7.0:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}Low vision. Lowest contrast 7.0:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}Dyslexia friendly reading. Lowest contrast 7.3:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}The highest contrast on a light screen. Lowest contrast 7.1:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
package com.zacess.capture
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
/** A slide detected in a projector frame, with how sure the detector is. */
data class Slide(val number: Int, val text: String, val confidence: Double)
sealed interface CaptureState {
data object Idle : CaptureState
data class Recording(val seconds: Long) : CaptureState
data class Failed(val reason: String) : CaptureState
}
class SlideTracker(private val threshold: Double = 0.9) {
fun newSlides(frames: Flow<Slide>): Flow<Slide> {
var last: Int? = null
return frames.map { slide ->
if (slide.confidence >= threshold && slide.number != last) {
last = slide.number
}
slide
}
}
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>Everyday reading in a bright room. Lowest contrast 7.1:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>Everyday reading in a dim room. Lowest contrast 7.0:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>Low vision. Lowest contrast 7.0:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>Dyslexia friendly reading. Lowest contrast 7.3:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>The highest contrast on a dark screen. Lowest contrast 7.1:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>The highest contrast on a light screen. Lowest contrast 7.1:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
<!doctype html>
<html lang="en-GB">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Week 4: signals</title>
<link rel="stylesheet" href="/profile.css">
</head>
<body>
<a class="skip" href="#main">Skip to content</a>
<main id="main">
<h1>Week 4: signals</h1>
<!-- low confidence words are marked, never hidden -->
<p>The cut-off frequency is <mark data-confidence="0.62">1.6 kHz</mark>.</p>
<figure>
<img src="bode.png" alt="Bode plot falling 20 dB per decade after 1.6 kHz">
<figcaption>Figure 3: the filter's response</figcaption>
</figure>
<button type="button" aria-pressed="false">Read aloud</button>
</main>
</body>
</html>A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}Everyday reading in a bright room. Lowest contrast 7.1:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}Everyday reading in a dim room. Lowest contrast 7.0:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}Low vision. Lowest contrast 7.0:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}Dyslexia friendly reading. Lowest contrast 7.3:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}The highest contrast on a light screen. Lowest contrast 7.1:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
/* the Low Vision preset: large type, wide spacing and yellow on black */
:root {
--text: #ffeb3b;
--background: #000000;
--measure: 45ch;
}
body {
background: var(--background);
color: var(--text);
font: 400 1.5rem/1.6 "Atkinson Hyperlegible", system-ui, sans-serif;
letter-spacing: 0.02em;
}
main {
max-width: var(--measure);
margin-inline: auto;
}
:focus-visible {
outline: 3px solid currentColor;
outline-offset: 3px;
}
@media (prefers-reduced-motion: reduce) {
* { animation: none !important; transition: none !important; }
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}Everyday reading in a bright room. Lowest contrast 7.1:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}Everyday reading in a dim room. Lowest contrast 7.0:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}Low vision. Lowest contrast 7.0:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}Dyslexia friendly reading. Lowest contrast 7.3:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}The highest contrast on a dark screen. Lowest contrast 7.1:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}The highest contrast on a light screen. Lowest contrast 7.1:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
{
"name": "Low Vision",
"font": "Atkinson Hyperlegible",
"font_size": 24,
"line_spacing": 1.6,
"character_spacing": 0.02,
"column_width": 45,
"contrast": "yellow_on_black",
"cursor_size": "extra_large",
"reading_ruler": {
"enabled": true,
"position": 0.4,
"lines": 1
},
"single_column": true,
"reduce_motion": true,
"hide_decoration": false,
"speech": {
"voice": null,
"rate": 1.0,
"highlight": "word"
}
}A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyEveryday reading in a bright room. Lowest contrast 7.1:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyEveryday reading in a dim room. Lowest contrast 7.0:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyLow vision. Lowest contrast 7.0:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyDyslexia friendly reading. Lowest contrast 7.3:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyThe highest contrast on a dark screen. Lowest contrast 7.1:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyThe highest contrast on a light screen. Lowest contrast 7.1:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyLow vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyLow vision, with vivid deep colours on white. Lowest contrast 7.0:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyA gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
# checks every pull request before it can merge
name: CI
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
contrast:
name: Palette and contrast
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: 24
- run: npm run check
- run: npm run verifyA gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.Everyday reading in a bright room. Lowest contrast 7.1:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.Everyday reading in a dim room. Lowest contrast 7.0:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.Low vision. Lowest contrast 7.0:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.Dyslexia friendly reading. Lowest contrast 7.3:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.The highest contrast on a dark screen. Lowest contrast 7.1:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.The highest contrast on a light screen. Lowest contrast 7.1:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
# Week 4: signals
Lecture notes, imported from the slides and checked by hand.
## Key ideas
- A **low pass** filter keeps the slow parts of a signal.
- The *cut-off frequency* is where the output falls to 70.7% of the input.
- Each extra order adds 20 dB per decade of roll-off.
> [!NOTE]
> The number on slide 12 was misread by OCR and corrected here.
| Order | Roll-off |
| --- | --- |
| 1 | 20 dB per decade |
| 2 | 40 dB per decade |
```python
cutoff = 1 / (2 * pi * r * c)
```
See [the full handout](handout.pdf) for the derivation.A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"Everyday reading in a bright room. Lowest contrast 7.1:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"Everyday reading in a dim room. Lowest contrast 7.0:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"Low vision. Lowest contrast 7.0:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"Dyslexia friendly reading. Lowest contrast 7.3:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"The highest contrast on a dark screen. Lowest contrast 7.1:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"The highest contrast on a light screen. Lowest contrast 7.1:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
#!/usr/bin/env bash
# exports every document in the library as accessible HTML
set -euo pipefail
library="${1:-$HOME/Zacess}"
out="${2:-./export}"
count=0
mkdir -p "$out"
for doc in "$library"/*.zacess; do
[[ -e "$doc" ]] || continue
name="$(basename "$doc" .zacess)"
if zacess export --format html --profile low-vision "$doc" > "$out/$name.html"; then
count=$((count + 1))
else
echo "could not export $name" >&2
fi
done
echo "exported $count documents to $out"A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;Everyday reading in a bright room. Lowest contrast 7.1:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;Everyday reading in a dim room. Lowest contrast 7.0:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;Low vision. Lowest contrast 7.0:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;Dyslexia friendly reading. Lowest contrast 7.3:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;The highest contrast on a dark screen. Lowest contrast 7.1:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;The highest contrast on a light screen. Lowest contrast 7.1:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;Low vision, with deep and fully saturated colours on black. Lowest contrast 7.0:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;Low vision, with vivid deep colours on white. Lowest contrast 7.0:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;A gentler dark theme for anyone who finds high contrast too intense, with cream and earthy colours on warm brown. Lowest contrast 5.7:1.
-- flashcards due today, weakest first
CREATE TABLE IF NOT EXISTS cards (
id INTEGER PRIMARY KEY,
deck_id INTEGER NOT NULL REFERENCES decks (id),
front TEXT NOT NULL,
back TEXT NOT NULL,
stability REAL DEFAULT 1.0,
due_at TEXT NOT NULL
);
SELECT c.id,
c.front,
d.name AS deck,
ROUND(c.stability, 2) AS stability
FROM cards AS c
JOIN decks AS d ON d.id = c.deck_id
WHERE date(c.due_at) <= date('now')
AND d.archived = 0
ORDER BY c.stability ASC, c.due_at
LIMIT 20;A gentler light theme for anyone who finds high contrast too intense, with dark brown and earthy colours on warm paper. Lowest contrast 5.0:1.
The gentler Warm pair
Some people find high contrast too intense: glare, a halo around bright text or eye strain over a long session. Warm Dark and Warm Light are for them. Body text sits at about 12:1 in warm, earthy colours, cream on dark brown and dark brown on warm paper, with amber, rust, olive, teal, muted blue and rose. Every text and syntax colour keeps at least 4.5:1 (WCAG AA) while the other eight themes keep 7:1. Every other check, from the colour vision pairs to the selection, current line and find match, applies to them unchanged.
Always know where you are
Contrast is only half of it. In many themes the selection, the line the cursor is on and the current search match are barely lighter than the background, so they are easy to lose. Every Zacess theme makes them stand out and the build measures each one.
A selection you can see
In terminals and most editors, selected text sits on a solid block in a colour from the theme's own palette, the way a terminal draws it. In the eight contrast themes the block keeps 7.4:1 or more on the background and the text keeps 7.4:1 or more on the block. In Warm Dark and Warm Light both keep 6.5:1 or more.
A visible current line
The line the cursor is on is a calm band at 1.3:1 to 1.4:1 on the background. Plain text, the line number and the cursor keep 7:1 over it and every syntax colour keeps 4.5:1.
Matches by shape as well as colour
The current find match is a strong fill. Other matches, the word under the cursor and a matched bracket are outlined or underlined with no fill, so they never hide a character or pass for a selection. Yellow on Black underlines the word under the cursor with dashes in Neovim and dots in JetBrains IDEs.
Changed lines marked in the gutter
Added, changed and removed lines are marked beside the code in VS Code, Neovim, Zed and Emacs, in colours checked against every other highlight.
In your browser
All ten themes also colour Chrome and Firefox: the tab strip, the toolbar, the address bar and the new tab page. Web pages keep their own colours. Text on each part keeps at least 7:1 contrast (4.5:1 in the Warm pair). Edge installs the Chrome themes once Allow extensions from other stores is turned on.
| Theme | Chrome and Edge | Firefox |
|---|---|---|
| Zacess Light | Chrome Web Store | Firefox Add-ons |
| Zacess Dark | Chrome Web Store | Firefox Add-ons |
| Zacess Yellow on Black | Chrome Web Store | Firefox Add-ons |
| Zacess Cream | Chrome Web Store | Firefox Add-ons |
| Zacess High Contrast Dark | Chrome Web Store | Firefox Add-ons |
| Zacess High Contrast Light | Chrome Web Store | Firefox Add-ons |
| Zacess Deep Contrast Dark | Chrome Web Store | Firefox Add-ons |
| Zacess Deep Contrast Light | Chrome Web Store | Firefox Add-ons |
| Zacess Warm Dark | Chrome Web Store | Firefox Add-ons |
| Zacess Warm Light | Chrome Web Store | Firefox Add-ons |
Install
Packaged files are attached to each release on the releases page. Every editor's files can also be taken straight from the themes repository. The install page lists every editor and terminal with its one step.
VS Code
On the VS Code Marketplace
Search for Zacess Themes in the Extensions view or run code --install-extension zacess.zacess-themes, then pick a theme with Preferences: Color Theme.
Cursor, Windsurf and VSCodium
On Open VSX
Editors built on VS Code that use Open VSX, such as Cursor, Windsurf, VSCodium and Antigravity, find Zacess Themes in their Extensions view.
JetBrains IDEs
On the JetBrains Marketplace
Open Settings, then Plugins, search the Marketplace tab for Zacess Themes and install it, then choose a Zacess theme under Appearance. Needs 2025.3 or later. The plugin zip on each release is there for offline installs.
Obsidian
In the Obsidian community directory
Open Settings, then Appearance, select Manage under Themes and search for Zacess. Zacess Cream, Zacess High Contrast, Zacess Deep Contrast and Zacess Warm are their own themes, each with a light and a dark look that follows Obsidian's Base color scheme setting.
Neovim
Listed in awesome-neovim
Add zacesshq/zacess.nvim with lazy.nvim or any other plugin manager, then run :colorscheme zacess-dark. Needs termguicolors.
Zed
In the Zed extension store
Run zed: extensions from the command palette, search for Zacess Themes and install it, then pick a theme with theme selector: toggle.
Sublime Text
Download from the latest release
Put the .sublime-color-scheme files in your Packages/User folder, then choose one with UI: Select Color Scheme. Needs Sublime Text 4.
Helix
Download from the latest release
Put the theme files in ~/.config/helix/themes, then set theme = "zacess_dark" in config.toml.
Emacs
Download from the latest release
Put the theme files in your custom-theme-directory, then run (load-theme 'zacess-dark t). Needs Emacs 27 or later.
Eclipse
On the Eclipse Marketplace
Install Zacess Themes from Help, Eclipse Marketplace. It also installs from Help, Install New Software with the update site https://zacesshq.github.io/themes/eclipse/. Restart Eclipse, then choose a Zacess theme under Preferences, General, Appearance. Covers the Java and properties editors, the colours every text editor shares, the Terminal view and the Console.
Xcode
Download from the themes repository
Copy the .xccolortheme files into ~/Library/Developer/Xcode/UserData/FontAndColorThemes. In Xcode 27 bring one in with Settings, Themes, Import Classic Theme; in Xcode 26 and earlier choose it in Settings, Themes.
Terminals
In the iTerm2 Color Schemes collection
The Zacess themes are in the iTerm2 Color Schemes collection, which Ghostty, WezTerm, Windows Terminal and other terminals draw their theme lists from. The repository has files for iTerm2, Terminal.app, Ghostty, kitty, WezTerm, Warp, Alacritty and Windows Terminal. Run install.sh in any of them (install.ps1 for Windows Terminal): it finds the terminal, copies all ten themes to the folder it reads and prints the one step that turns one on. It never edits a settings file.
Chrome, Edge and Firefox
In the Chrome Web Store and on Firefox Add-ons
Each of the ten themes colours the browser's tab strip, toolbar, address bar and new tab page. Web pages keep their own colours. Edge Add-ons takes no themes, so Edge installs the Chrome ones once Allow extensions from other stores is turned on.
Zacess themes in the Chrome Web Store
Something hard to read?
A contrast or readability problem is a bug. Tell us with the readability form on GitHub or email contact@zacess.com. You never need to share a diagnosis.