Browse Source

Rewrite scheme

June 2 months ago
parent
commit
05fa4de3e5
Signed by: Curtis McEnroe <june@causal.agency> GPG Key ID: CEA2F97ADCFCD77C
4 changed files with 172 additions and 179 deletions
  1. 7
    13
      bin/fbatt.c
  2. 5
    6
      bin/fbclock.c
  3. 10
    2
      bin/man/scheme.1
  4. 150
    158
      bin/scheme.c

+ 7
- 13
bin/fbatt.c View File

@@ -35,12 +35,6 @@ static const uint32_t Right  = 5 * 8 + 1; // fbclock width.
35 35
 static const uint32_t Width  = 8;
36 36
 static const uint32_t Height = 16;
37 37
 
38
-static const uint32_t BG     = Scheme.darkBlack;
39
-static const uint32_t Border = Scheme.darkWhite;
40
-static const uint32_t Gray   = Scheme.lightBlack;
41
-static const uint32_t Yellow = Scheme.darkYellow;
42
-static const uint32_t Red    = Scheme.darkRed;
43
-
44 38
 int main() {
45 39
 	int error;
46 40
 
@@ -108,20 +102,20 @@ int main() {
108 102
 			uint32_t left = info.xres - Right - Width;
109 103
 
110 104
 			for (uint32_t y = 0; y <= Height; ++y) {
111
-				buf[y * info.xres + left - 1] = Border;
112
-				buf[y * info.xres + left + Width] = Border;
105
+				buf[y * info.xres + left - 1] = DarkWhite;
106
+				buf[y * info.xres + left + Width] = DarkWhite;
113 107
 			}
114 108
 			for (uint32_t x = left; x < left + Width; ++x) {
115
-				buf[Height * info.xres + x] = Border;
109
+				buf[Height * info.xres + x] = DarkWhite;
116 110
 			}
117 111
 
118 112
 			for (uint32_t y = 0; y < Height; ++y) {
119 113
 				for (uint32_t x = left; x < left + Width; ++x) {
120 114
 					buf[y * info.xres + x] =
121
-						(Height - 1 - y > height) ? BG
122
-						: (percent <= 10) ? Red
123
-						: (percent <= 30) ? Yellow
124
-						: Gray;
115
+						(Height - 1 - y > height) ? DarkBlack
116
+						: (percent <= 10) ? DarkRed
117
+						: (percent <= 30) ? DarkYellow
118
+						: LightBlack;
125 119
 				}
126 120
 			}
127 121
 		}

+ 5
- 6
bin/fbclock.c View File

@@ -42,9 +42,6 @@ struct PSF2Header {
42 42
 	uint32_t glyphWidth;
43 43
 };
44 44
 
45
-static const uint32_t BG = Scheme.darkBlack;
46
-static const uint32_t FG = Scheme.darkWhite;
47
-
48 45
 int main() {
49 46
 	size_t len;
50 47
 
@@ -110,10 +107,10 @@ int main() {
110 107
 			uint32_t bottom = header.glyphHeight;
111 108
 
112 109
 			for (uint32_t y = 0; y < bottom; ++y) {
113
-				buf[y * info.xres + left - 1] = FG;
110
+				buf[y * info.xres + left - 1] = DarkWhite;
114 111
 			}
115 112
 			for (uint32_t x = left - 1; x < info.xres; ++x) {
116
-				buf[bottom * info.xres + x] = FG;
113
+				buf[bottom * info.xres + x] = DarkWhite;
117 114
 			}
118 115
 
119 116
 			for (const char *s = str; *s; ++s) {
@@ -123,7 +120,9 @@ int main() {
123 120
 					for (uint32_t x = 0; x < header.glyphWidth; ++x) {
124 121
 						uint8_t bits = glyph[y * stride + x / 8];
125 122
 						uint8_t bit = bits >> (7 - x % 8) & 1;
126
-						buf[y * info.xres + left + x] = bit ? FG : BG;
123
+						buf[y * info.xres + left + x] = bit
124
+							? DarkWhite
125
+							: DarkBlack;
127 126
 					}
128 127
 				}
129 128
 				left += header.glyphWidth;

+ 10
- 2
bin/man/scheme.1 View File

@@ -9,6 +9,7 @@
9 9
 .Sh SYNOPSIS
10 10
 .Nm
11 11
 .Op Fl acghilmtx
12
+.Op Fl p Ar n
12 13
 .
13 14
 .Sh DESCRIPTION
14 15
 .Nm
@@ -20,9 +21,10 @@ The arguments are as follows:
20 21
 .Bl -tag -width Ds
21 22
 .It Fl a
22 23
 Output only the 16 ANSI colors.
24
+This is the default.
23 25
 .
24 26
 .It Fl c
25
-Output a C header file.
27
+Output a C enum.
26 28
 .
27 29
 .It Fl g
28 30
 Output a swatch PNG.
@@ -40,11 +42,17 @@ Output Linux console OSC sequences.
40 42
 Output a
41 43
 .Xr mintty 1
42 44
 theme.
45
+Should be used with
46
+.Fl t .
47
+.
48
+.It Fl p Ar n
49
+Only output the color
50
+.Ar n .
43 51
 .
44 52
 .It Fl t
45 53
 Additionally output terminal
46 54
 background,
47
-text,
55
+foreground,
48 56
 bold,
49 57
 selection
50 58
 and cursor

+ 150
- 158
bin/scheme.c View File

@@ -21,12 +21,11 @@
21 21
 #include <stdio.h>
22 22
 #include <stdlib.h>
23 23
 #include <string.h>
24
-#include <stdbool.h>
25 24
 #include <sysexits.h>
26 25
 #include <unistd.h>
27 26
 #include <zlib.h>
28 27
 
29
-static const struct Hsv { double h, s, v; }
28
+static const struct HSV { double h, s, v; }
30 29
 	R = {   0.0, 1.0, 1.0 },
31 30
 	Y = {  60.0, 1.0, 1.0 },
32 31
 	G = { 120.0, 1.0, 1.0 },
@@ -34,17 +33,7 @@ static const struct Hsv { double h, s, v; }
34 33
 	B = { 240.0, 1.0, 1.0 },
35 34
 	M = { 300.0, 1.0, 1.0 };
36 35
 
37
-static struct Hsv x(struct Hsv o, double hd, double sf, double vf) {
38
-	return (struct Hsv) {
39
-		fmod(o.h + hd, 360.0),
40
-		fmin(o.s * sf, 1.0),
41
-		fmin(o.v * vf, 1.0),
42
-	};
43
-}
44
-
45
-static struct Rgb {
46
-	uint8_t r, g, b;
47
-} toRgb(struct Hsv hsv) {
36
+static struct RGB { uint8_t r, g, b; } toRGB(struct HSV hsv) {
48 37
 	double c = hsv.v * hsv.s;
49 38
 	double h = hsv.h / 60.0;
50 39
 	double x = c * (1.0 - fabs(fmod(h, 2.0) - 1.0));
@@ -56,155 +45,144 @@ static struct Rgb {
56 45
 	else if (h <= 4.0) { g += x; b += c; }
57 46
 	else if (h <= 5.0) { r += x; b += c; }
58 47
 	else if (h <= 6.0) { r += c; b += x; }
59
-	return (struct Rgb) { r * 255.0, g * 255.0, b * 255.0 };
48
+	return (struct RGB) { r * 255.0, g * 255.0, b * 255.0 };
60 49
 }
61 50
 
62
-enum { Black, Red, Green, Yellow, Blue, Magenta, Cyan, White };
63
-static struct {
64
-	struct Hsv dark[8];
65
-	struct Hsv light[8];
66
-	struct Hsv background, text, bold, selection, cursor;
67
-} scheme;
51
+static struct HSV x(struct HSV o, double hd, double sf, double vf) {
52
+	return (struct HSV) {
53
+		fmod(o.h + hd, 360.0),
54
+		fmin(o.s * sf, 1.0),
55
+		fmin(o.v * vf, 1.0),
56
+	};
57
+}
58
+
59
+enum {
60
+	Black,
61
+	Red,
62
+	Green,
63
+	Yellow,
64
+	Blue,
65
+	Magenta,
66
+	Cyan,
67
+	White,
68
+	Dark = 0,
69
+	Light = 8,
70
+	Background = 16,
71
+	Foreground,
72
+	Bold,
73
+	Selection,
74
+	Cursor,
75
+	SchemeLen,
76
+};
77
+static struct HSV scheme[SchemeLen];
68 78
 
69 79
 static void generate(void) {
70
-	scheme.light[Black]   = x(R, +45.0, 0.3, 0.3);
71
-	scheme.light[Red]     = x(R, +10.0, 0.9, 0.8);
72
-	scheme.light[Green]   = x(G, -55.0, 0.8, 0.6);
73
-	scheme.light[Yellow]  = x(Y, -20.0, 0.8, 0.8);
74
-	scheme.light[Blue]    = x(B, -55.0, 0.4, 0.5);
75
-	scheme.light[Magenta] = x(M, +45.0, 0.4, 0.6);
76
-	scheme.light[Cyan]    = x(C, -60.0, 0.3, 0.6);
77
-	scheme.light[White]   = x(R, +45.0, 0.3, 0.8);
80
+	scheme[Light + Black]   = x(R, +45.0, 0.3, 0.3);
81
+	scheme[Light + Red]     = x(R, +10.0, 0.9, 0.8);
82
+	scheme[Light + Green]   = x(G, -55.0, 0.8, 0.6);
83
+	scheme[Light + Yellow]  = x(Y, -20.0, 0.8, 0.8);
84
+	scheme[Light + Blue]    = x(B, -55.0, 0.4, 0.5);
85
+	scheme[Light + Magenta] = x(M, +45.0, 0.4, 0.6);
86
+	scheme[Light + Cyan]    = x(C, -60.0, 0.3, 0.6);
87
+	scheme[Light + White]   = x(R, +45.0, 0.3, 0.8);
78 88
 
79
-	scheme.dark[Black] = x(scheme.light[Black], 0.0, 1.0, 0.3);
80
-	scheme.dark[White] = x(scheme.light[White], 0.0, 1.0, 0.6);
89
+	scheme[Dark + Black] = x(scheme[Light + Black], 0.0, 1.0, 0.3);
90
+	scheme[Dark + White] = x(scheme[Light + White], 0.0, 1.0, 0.6);
81 91
 	for (int i = Red; i < White; ++i) {
82
-		scheme.dark[i] = x(scheme.light[i], 0.0, 1.0, 0.8);
92
+		scheme[Dark + i] = x(scheme[Light + i], 0.0, 1.0, 0.8);
83 93
 	}
84 94
 
85
-	scheme.background = x(scheme.dark[Black],    0.0, 1.0, 0.9);
86
-	scheme.text       = x(scheme.light[White],   0.0, 1.0, 0.9);
87
-	scheme.bold       = x(scheme.light[White],   0.0, 1.0, 1.0);
88
-	scheme.selection  = x(scheme.light[Red],   +10.0, 1.0, 0.8);
89
-	scheme.cursor     = x(scheme.dark[White],    0.0, 1.0, 0.8);
95
+	scheme[Background] = x(scheme[Dark + Black],    0.0, 1.0, 0.9);
96
+	scheme[Foreground] = x(scheme[Light + White],   0.0, 1.0, 0.9);
97
+	scheme[Bold]       = x(scheme[Light + White],   0.0, 1.0, 1.0);
98
+	scheme[Selection]  = x(scheme[Light + Red],   +10.0, 1.0, 0.8);
99
+	scheme[Cursor]     = x(scheme[Dark + White],    0.0, 1.0, 0.8);
90 100
 }
91 101
 
92
-static void swap(struct Hsv *a, struct Hsv *b) {
93
-	struct Hsv t;
94
-	t = *a;
95
-	*a = *b;
96
-	*b = t;
102
+static void swap(int a, int b) {
103
+	struct HSV t = scheme[a];
104
+	scheme[a] = scheme[b];
105
+	scheme[b] = t;
97 106
 }
98 107
 
99 108
 static void invert(void) {
100
-	swap(&scheme.dark[Black], &scheme.light[White]);
101
-	swap(&scheme.light[Black], &scheme.dark[White]);
109
+	swap(Dark + Black, Light + White);
110
+	swap(Light + Black, Dark + White);
102 111
 }
103 112
 
104
-static void printHsv(struct Hsv hsv) {
105
-	printf("%g,%g,%g\n", hsv.h, hsv.s, hsv.v);
106
-}
107
-static void hsv(bool ansi) {
108
-	for (int i = Black; i <= White; ++i) {
109
-		printHsv(scheme.dark[i]);
110
-	}
111
-	for (int i = Black; i <= White; ++i) {
112
-		printHsv(scheme.light[i]);
113
-	}
114
-	if (ansi) return;
115
-	printHsv(scheme.background);
116
-	printHsv(scheme.text);
117
-	printHsv(scheme.bold);
118
-	printHsv(scheme.selection);
119
-	printHsv(scheme.cursor);
113
+static void printHSV(int n) {
114
+	printf("%g,%g,%g\n", scheme[n].h, scheme[n].s, scheme[n].v);
120 115
 }
121 116
 
122
-static void printHex(struct Hsv hsv) {
123
-	struct Rgb rgb = toRgb(hsv);
117
+static void printRGB(int n) {
118
+	struct RGB rgb = toRGB(scheme[n]);
124 119
 	printf("%02X%02X%02X\n", rgb.r, rgb.g, rgb.b);
125 120
 }
126
-static void hex(bool ansi) {
127
-	for (int i = Black; i <= White; ++i) {
128
-		printHex(scheme.dark[i]);
129
-	}
130
-	for (int i = Black; i <= White; ++i) {
131
-		printHex(scheme.light[i]);
132
-	}
133
-	if (ansi) return;
134
-	printHex(scheme.background);
135
-	printHex(scheme.text);
136
-	printHex(scheme.bold);
137
-	printHex(scheme.selection);
138
-	printHex(scheme.cursor);
139
-}
140 121
 
141
-static void printC(struct Hsv hsv) {
142
-	struct Rgb rgb = toRgb(hsv);
143
-	printf("\t0x%02X%02X%02X,\n", rgb.r, rgb.g, rgb.b);
122
+static const char *CNames[SchemeLen] = {
123
+	[Dark + Black]    = "DarkBlack",
124
+	[Dark + Red]      = "DarkRed",
125
+	[Dark + Green]    = "DarkGreen",
126
+	[Dark + Yellow]   = "DarkYellow",
127
+	[Dark + Blue]     = "DarkBlue",
128
+	[Dark + Magenta]  = "DarkMagenta",
129
+	[Dark + Cyan]     = "DarkCyan",
130
+	[Dark + White]    = "DarkWhite",
131
+	[Light + Black]   = "LightBlack",
132
+	[Light + Red]     = "LightRed",
133
+	[Light + Green]   = "LightGreen",
134
+	[Light + Yellow]  = "LightYellow",
135
+	[Light + Blue]    = "LightBlue",
136
+	[Light + Magenta] = "LightMagenta",
137
+	[Light + Cyan]    = "LightCyan",
138
+	[Light + White]   = "LightWhite",
139
+	[Background]      = "Background",
140
+	[Foreground]      = "Foreground",
141
+	[Bold]            = "Bold",
142
+	[Selection]       = "Selection",
143
+	[Cursor]          = "Cursor",
144
+};
145
+static void printCHead(void) {
146
+	printf("enum {\n");
144 147
 }
145
-static void header(void) {
146
-	printf(
147
-		"// This file is generated by scheme -c.\n\n"
148
-		"#include <stdint.h>\n\n"
149
-		"const struct {\n"
150
-		"\tuint32_t darkBlack, darkRed, darkGreen, darkYellow;\n"
151
-		"\tuint32_t darkBlue, darkMagenta, darkCyan, darkWhite;\n"
152
-		"\tuint32_t lightBlack, lightRed, lightGreen, lightYellow;\n"
153
-		"\tuint32_t lightBlue, lightMagenta, lightCyan, lightWhite;\n"
154
-		"\tuint32_t background, text, bold, selection, cursor;\n"
155
-		"} Scheme = {\n"
156
-	);
157
-	for (int i = Black; i <= White; ++i) {
158
-		printC(scheme.dark[i]);
159
-	}
160
-	for (int i = Black; i <= White; ++i) {
161
-		printC(scheme.light[i]);
162
-	}
163
-	printC(scheme.background);
164
-	printC(scheme.text);
165
-	printC(scheme.bold);
166
-	printC(scheme.selection);
167
-	printC(scheme.cursor);
168
-	printf("};\n");
148
+static void printC(int n) {
149
+	struct RGB rgb = toRGB(scheme[n]);
150
+	printf("\t%s = 0x%02X%02X%02X,\n", CNames[n], rgb.r, rgb.g, rgb.b);
169 151
 }
170
-
171
-static void console(void) {
172
-	for (int i = Black; i <= White; ++i) {
173
-		struct Rgb rgb = toRgb(scheme.dark[i]);
174
-		printf("\x1B]P%X%02X%02X%02X", i, rgb.r, rgb.g, rgb.b);
175
-	}
176
-	for (int i = Black; i <= White; ++i) {
177
-		struct Rgb rgb = toRgb(scheme.dark[i]);
178
-		printf("\x1B]P%X%02X%02X%02X", 8 + i, rgb.r, rgb.g, rgb.b);
179
-	}
152
+static void printCTail(void) {
153
+	printf("};\n");
180 154
 }
181 155
 
182
-static void printMintty(const char *key, struct Hsv hsv) {
183
-	struct Rgb rgb = toRgb(hsv);
184
-	printf("%s=%d,%d,%d\n", key, rgb.r, rgb.g, rgb.b);
156
+static void printLinux(int n) {
157
+	struct RGB rgb = toRGB(scheme[n]);
158
+	printf("\x1B]P%X%02X%02X%02X", n, rgb.r, rgb.g, rgb.b);
185 159
 }
186
-static void mintty(void) {
187
-	printMintty("Black", scheme.dark[Black]);
188
-	printMintty("Red", scheme.dark[Red]);
189
-	printMintty("Green", scheme.dark[Green]);
190
-	printMintty("Yellow", scheme.dark[Yellow]);
191
-	printMintty("Blue", scheme.dark[Blue]);
192
-	printMintty("Magenta", scheme.dark[Magenta]);
193
-	printMintty("Cyan", scheme.dark[Cyan]);
194
-	printMintty("White", scheme.dark[White]);
195 160
 
196
-	printMintty("BoldBlack", scheme.light[Black]);
197
-	printMintty("BoldRed", scheme.light[Red]);
198
-	printMintty("BoldGreen", scheme.light[Green]);
199
-	printMintty("BoldYellow", scheme.light[Yellow]);
200
-	printMintty("BoldBlue", scheme.light[Blue]);
201
-	printMintty("BoldMagenta", scheme.light[Magenta]);
202
-	printMintty("BoldCyan", scheme.light[Cyan]);
203
-	printMintty("BoldWhite", scheme.light[White]);
204
-
205
-	printMintty("BackgroundColour", scheme.background);
206
-	printMintty("ForegroundColour", scheme.text);
207
-	printMintty("CursorColour", scheme.cursor);
161
+static const char *MinttyNames[SchemeLen] = {
162
+	[Dark + Black]    = "Black",
163
+	[Dark + Red]      = "Red",
164
+	[Dark + Green]    = "Green",
165
+	[Dark + Yellow]   = "Yellow",
166
+	[Dark + Blue]     = "Blue",
167
+	[Dark + Magenta]  = "Magenta",
168
+	[Dark + Cyan]     = "Cyan",
169
+	[Dark + White]    = "White",
170
+	[Light + Black]   = "BoldBlack",
171
+	[Light + Red]     = "BoldRed",
172
+	[Light + Green]   = "BoldGreen",
173
+	[Light + Yellow]  = "BoldYellow",
174
+	[Light + Blue]    = "BoldBlue",
175
+	[Light + Magenta] = "BoldMagenta",
176
+	[Light + Cyan]    = "BoldCyan",
177
+	[Light + White]   = "BoldWhite",
178
+	[Background]      = "BackgroundColour",
179
+	[Foreground]      = "ForegroundColour",
180
+	[Cursor]          = "CursorColour",
181
+};
182
+static void printMintty(int n) {
183
+	if (!MinttyNames[n]) return;
184
+	struct RGB rgb = toRGB(scheme[n]);
185
+	printf("%s=%d,%d,%d\n", MinttyNames[n], rgb.r, rgb.g, rgb.b);
208 186
 }
209 187
 
210 188
 static uint32_t crc;
@@ -223,13 +201,15 @@ static void pngChunk(const char *type, uint32_t size) {
223 201
 	pngWrite(type, 4);
224 202
 }
225 203
 
226
-static void png(const struct Hsv *hsv, size_t len) {
227
-	if (len > 256) len = 256;
204
+static void png(int at, int to) {
205
+	if (to - at > 256) to = at + 256;
206
+
207
+	uint32_t len = to - at;
228 208
 	uint32_t swatchWidth = 64;
229 209
 	uint32_t swatchHeight = 64;
230
-	uint32_t columns = 8;
231
-	uint32_t rows = (len + columns - 1) / columns;
232
-	uint32_t width = swatchWidth * columns;
210
+	uint32_t cols = 8;
211
+	uint32_t rows = (len + cols - 1) / cols;
212
+	uint32_t width = swatchWidth * cols;
233 213
 	uint32_t height = swatchHeight * rows;
234 214
 
235 215
 	pngWrite("\x89PNG\r\n\x1A\n", 8);
@@ -237,12 +217,12 @@ static void png(const struct Hsv *hsv, size_t len) {
237 217
 	pngChunk("IHDR", 13);
238 218
 	pngInt(width);
239 219
 	pngInt(height);
240
-	pngWrite("\x08\x03\0\0\0", 5);
220
+	pngWrite("\x08\x03\x00\x00\x00", 5);
241 221
 	pngInt(crc);
242 222
 
243 223
 	pngChunk("PLTE", 3 * len);
244
-	for (size_t i = 0; i < len; ++i) {
245
-		struct Rgb rgb = toRgb(hsv[i]);
224
+	for (int i = at; i < to; ++i) {
225
+		struct RGB rgb = toRGB(scheme[i]);
246 226
 		pngWrite(&rgb, 3);
247 227
 	}
248 228
 	pngInt(crc);
@@ -253,10 +233,11 @@ static void png(const struct Hsv *hsv, size_t len) {
253 233
 		enum { None, Sub, Up, Average, Paeth };
254 234
 		data[y][0] = (y % swatchHeight) ? Up : Sub;
255 235
 	}
256
-	for (size_t i = 0; i < len; ++i) {
257
-		uint32_t y = swatchHeight * (i / columns);
258
-		uint32_t x = swatchWidth * (i % columns);
259
-		data[y][1 + x] = x ? 1 : i;
236
+	for (int i = at; i < to; ++i) {
237
+		int p = i - at;
238
+		uint32_t y = swatchHeight * (p / cols);
239
+		uint32_t x = swatchWidth * (p % cols);
240
+		data[y][1 + x] = x ? 1 : p;
260 241
 	}
261 242
 
262 243
 	uLong size = compressBound(sizeof(data));
@@ -272,27 +253,38 @@ static void png(const struct Hsv *hsv, size_t len) {
272 253
 	pngInt(crc);
273 254
 }
274 255
 
256
+static void print(void (*fn)(int), int at, int to) {
257
+	for (int i = at; i < to; ++i) {
258
+		fn(i);
259
+	}
260
+}
261
+
275 262
 int main(int argc, char *argv[]) {
276 263
 	generate();
277
-	bool ansi = true;
264
+	int at = 0;
265
+	int to = Background;
278 266
 	char out = 'x';
267
+
279 268
 	int opt;
280
-	while (0 < (opt = getopt(argc, argv, "acghilmtx"))) {
269
+	while (0 < (opt = getopt(argc, argv, "acghilmp:tx"))) {
281 270
 		switch (opt) {
282
-			break; case 'a': ansi = true;
271
+			break; case 'a': to = Background;
283 272
 			break; case 'i': invert();
284
-			break; case 't': ansi = false;
273
+			break; case 'p': at = strtoul(optarg, NULL, 0); to = at + 1;
274
+			break; case 't': to = SchemeLen;
285 275
 			break; case '?': return EX_USAGE;
286 276
 			break; default: out = opt;
287 277
 		}
288 278
 	}
279
+
289 280
 	switch (out) {
290
-		break; case 'c': header();
291
-		break; case 'g': png((struct Hsv *)&scheme, (ansi ? 16 : 21));
292
-		break; case 'h': hsv(ansi);
293
-		break; case 'l': console();
294
-		break; case 'm': mintty();
295
-		break; case 'x': hex(ansi);
281
+		break; case 'c': printCHead(); print(printC, at, to); printCTail();
282
+		break; case 'g': png(at, to);
283
+		break; case 'h': print(printHSV, at, to);
284
+		break; case 'l': print(printLinux, at, to);
285
+		break; case 'm': print(printMintty, at, to);
286
+		break; case 'x': print(printRGB, at, to);
296 287
 	}
288
+
297 289
 	return EX_OK;
298 290
 }

Loading…
Cancel
Save