From 74b70fc0393c59acf7b9fa4a87041c5f06eb4638 Mon Sep 17 00:00:00 2001 From: t-bltg <13423344+t-bltg@users.noreply.github.com> Date: Fri, 30 Jul 2021 13:09:59 +0200 Subject: [PATCH] Gaston: handle multiple colors --- src/backends/gaston.jl | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/backends/gaston.jl b/src/backends/gaston.jl index f2789a1a..59b24bf0 100644 --- a/src/backends/gaston.jl +++ b/src/backends/gaston.jl @@ -434,9 +434,13 @@ function gaston_marker(marker) end function gaston_color(color, alpha=0.) - col = single_color(color) # in case of gradients - col = alphacolor(col, alpha == nothing ? 0. : alpha) # add a default alpha if non existent - return "rgb \"#$(hex(col, :aarrggbb))\"" + if isvector(color) + return gaston_color.(color) + else + col = single_color(color) # in case of gradients + col = alphacolor(col, alpha == nothing ? 0. : alpha) # add a default alpha if non existent + return "rgb \"#$(hex(col, :aarrggbb))\"" + end end function gaston_linestyle(style)