[Giggle] [PATCH] Avoid using the invalid index as a color for path rendering.
Mikael Hallendal
micke at imendio.com
Fri Feb 8 00:23:35 CET 2008
David Vest skrev:
Hi,
Thanks for the patch, I've committed this.
Cheers,
Micke
> This issue was visible on dark backgrounds since the invalid color
> value isn't used in path rendering.
> ---
> src/giggle-graph-renderer.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/src/giggle-graph-renderer.c b/src/giggle-graph-renderer.c
> index 339728f..30578c4 100644
> --- a/src/giggle-graph-renderer.c
> +++ b/src/giggle-graph-renderer.c
> @@ -31,7 +31,7 @@
> #define PATH_SPACE(font_size) (font_size + 3)
> #define DOT_RADIUS(font_size) (font_size / 2)
> #define LINE_WIDTH(font_size) ((font_size / 6) << 1) /* we want the closest even number <= size/3 */
> -#define NEXT_COLOR(n_color) ((n_color % G_N_ELEMENTS (colors)) + 1)
> +#define NEXT_COLOR(n_color) ((n_color % (G_N_ELEMENTS (colors) - 1)) + 1)
> #define INVALID_COLOR 0
>
> typedef struct GiggleGraphRendererPrivate GiggleGraphRendererPrivate;
More information about the Giggle
mailing list