-
Notifications
You must be signed in to change notification settings - Fork 80
Description
An issue came up in GraphPlot.jl that turns out to actually be an issue in Compose.jl (JuliaGraphs/GraphPlot.jl#156)
MWE:
Make a plot with many red circles
n = 10
g = compose(
context(),
Compose.circle(rand(n),rand(n),rand(n)/100),
fill([colorant"red" for i in 1:n]),
Compose.stroke(nothing)
)The saving g (e.g., to PDF) or just displaying it on an IDE, looks the same as snapshot above.
However, if you increase the number of circles to 100:
You get the correct plot on an IDE, but when saving it to PDF or redisplaying g, the color is lost.
Inital plot with 100 circles:

Calling g in the REPL again or saving as say PDF, the red color switches over to black:

However, if the stroke is replaced with a Vector of the same size as the fill, the color is not lost when saving or redisplaying the figure.
n=100
g=compose(
context(),
Compose.circle(rand(n),rand(n),rand(n)/100),
fill([colorant"red" for i in 1:n]),
Compose.stroke([nothing for i in 1:n])
)There seems to be a glich when vectors are used in some functions, but not in others. But this only occurs when the size of the vectors is large. This behavior is observed with other functions such as fontsize and linewidth.
