Skip to content
This repository was archived by the owner on Jul 13, 2021. It is now read-only.

Commit dd2fa78

Browse files
committed
add todos
1 parent 4c7f87e commit dd2fa78

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/basic_recipes/basic_recipes.jl

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1152,18 +1152,22 @@ function plot!(p::Spy)
11521152
ye = extrema(y)
11531153
FRect2D((xe[1], ye[1]), (xe[2] - xe[1], ye[2] - ye[1]))
11541154
end
1155+
# TODO FastPixel isn't accepting marker size in data coordinates
1156+
# but instead in pixel - so we need to fix that in GLMakie for consistency
1157+
# and make this nicer when redoing unit support
11551158
markersize = lift(p.markersize, rect, p.z) do msize, rect, z
11561159
if msize === automatic
11571160
widths(rect) ./ Vec2f0(size(z))
11581161
else
11591162
msize
11601163
end
11611164
end
1162-
xycol = lift(rect, p.z) do rect, z
1165+
# TODO correctly align marker
1166+
xycol = lift(rect, p.z, markersize) do rect, z, markersize
11631167
x, y, color = SparseArrays.findnz(z)
11641168
points = map(x, y) do x, y
1165-
((Point2f0(x, y) .- 1) ./ Point2f0(size(z) .- 1)) .*
1166-
widths(rect) .+ minimum(rect)
1169+
(((Point2f0(x, y) .- 1) ./ Point2f0(size(z) .- 1)) .*
1170+
widths(rect) .+ minimum(rect))
11671171
end
11681172
points, color
11691173
end

0 commit comments

Comments
 (0)