From: Michael Tremer Date: Wed, 29 Oct 2025 10:47:29 +0000 (+0000) Subject: graphs: Make it possible to set colors as a non-literal X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f34354df7902b76534c078915e2b5ec2761aeac2;p=oddments%2Fcollecty.git graphs: Make it possible to set colors as a non-literal Signed-off-by: Michael Tremer --- diff --git a/src/daemon/graphs/graph.h b/src/daemon/graphs/graph.h index 43fb7a6..50910e5 100644 --- a/src/daemon/graphs/graph.h +++ b/src/daemon/graphs/graph.h @@ -72,10 +72,10 @@ // Draw a LINE, AREA, etc. #define DRAW(args, what, field, object, color, ...) \ - SCRIPT(args, what ":" FIELD color __VA_ARGS__, FIELD_AND_OBJECT(field, object)) + SCRIPT(args, what ":" FIELD "%s" __VA_ARGS__, FIELD_AND_OBJECT(field, object), color) #define DRAW_WITH_LABEL(args, what, field, object, color, label, ...) \ - SCRIPT(args, what ":" FIELD color ":" LABEL __VA_ARGS__, FIELD_AND_OBJECT(field, object), label) + SCRIPT(args, what ":" FIELD "%s:" LABEL __VA_ARGS__, FIELD_AND_OBJECT(field, object), color, label) // Draw lines #define DRAW_LINE1(args, field, object, color, ...) \