summaryrefslogtreecommitdiff
path: root/src/ui/color.c
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2021-04-05 12:19:55 +0300
committerJaakko Keränen <jaakko.keranen@iki.fi>2021-04-05 12:19:55 +0300
commit6000db343bb2c1b44bed9eb4b14a179f839f3aa7 (patch)
tree72363eac22ff41977e3336d1786fd0dc383ca2fe /src/ui/color.c
parentee0b5e2c30b68a906f76be388b47fac98a5f9e1f (diff)
Fixed color escapes in link visit date
A color escape may be longer than two characters. `run_Font_()` was not parsing extended color escapes correctly.
Diffstat (limited to 'src/ui/color.c')
-rw-r--r--src/ui/color.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/ui/color.c b/src/ui/color.c
index 79606cd0..d6d68816 100644
--- a/src/ui/color.c
+++ b/src/ui/color.c
@@ -462,6 +462,7 @@ const char *escape_Color(int color) {
462 if (color >= 0 && color < (int) iElemCount(esc)) { 462 if (color >= 0 && color < (int) iElemCount(esc)) {
463 return esc[color]; 463 return esc[color];
464 } 464 }
465 /* TODO: Conflict with format strings! "%" (37) may be used as the color value. */
465 /* Double-\r is used for range extension. */ 466 /* Double-\r is used for range extension. */
466 if (color + asciiBase_ColorEscape > 127) { 467 if (color + asciiBase_ColorEscape > 127) {
467 iAssert(color - asciiExtended_ColorEscape + asciiBase_ColorEscape <= 127); 468 iAssert(color - asciiExtended_ColorEscape + asciiBase_ColorEscape <= 127);