Make "remind -s" respect $DefaultColor

https://dianne.skoll.ca/pipermail/remind-fans/2025/005051.html
This commit is contained in:
Dianne Skoll
2025-04-23 10:15:20 -04:00
parent dc75c8f49b
commit 44b920e080
3 changed files with 11 additions and 1 deletions

View File

@@ -2055,7 +2055,7 @@ static int DoCalRem(ParsePtr p, int col)
if (trig.typ == MSG_TYPE ||
trig.typ == CAL_TYPE ||
trig.typ == MSF_TYPE) {
if (PsCal && is_color) {
if ((PsCal || DoSimpleCalendar) && is_color) {
char cbuf[24];
snprintf(cbuf, sizeof(cbuf), "%d %d %d ", col_r, col_g, col_b);
DBufPuts(&pre_buf, cbuf);

View File

@@ -709,6 +709,12 @@ for i in ../include/lang/??.rem ; do
../src/remind -r -q "-ii=\"$i\"" ../tests/tstlang.rem 1 Feb 2024 13:34 >> ../tests/test.out 2>&1
done
# Fix for $DefaultColor bug with remind -s
../src/remind -s - 1 Feb 2024 >> ../tests/test.out 2>&1 <<'EOF'
SET $DefaultColor "255 0 0"
REM Wed MSG Wookie
EOF
# Make sure all the include files are ok
find ../include -type f -name '*.rem' | while read x; do ../src/remind -n $x 1 Jan 2024 2>>../tests/test.out 1>/dev/null; done
cmp -s ../tests/test.out ../tests/test.cmp

View File

@@ -38252,3 +38252,7 @@ $Thursday is Joi
$Friday is Vineri
$Saturday is Sâmbătă
$Sunday is Duminică
2024/02/07 COLOR * * * 255 0 0 Wookie
2024/02/14 COLOR * * * 255 0 0 Wookie
2024/02/21 COLOR * * * 255 0 0 Wookie
2024/02/28 COLOR * * * 255 0 0 Wookie