simplified line width

This commit is contained in:
nek0 2016-12-11 00:09:57 +01:00
parent 4cc55e32e7
commit 93dd045f27

View file

@ -28,11 +28,9 @@ drawRect buf color dt rect@G.GeglRectangle{..} =
let col = colorize pc color let col = colorize pc color
in in
G.Pixel px py col G.Pixel px py col
Line width -> Line size ->
if (px >= rectangleX && px <= (rectangleX + width) || if not ((px >= (rectangleX + size) && px < (rectangleX + rectangleWidth - size)) &&
px <= (rectangleX + rectangleWidth) && px >= (rectangleX + rectangleWidth - width)) && (py >= (rectangleY + size) && py < (rectangleY + rectangleHeight - size)))
(py >= rectangleY && py <= (rectangleY + width) ||
py <= (rectangleY + rectangleHeight) && py >= (rectangleY + rectangleHeight - width))
then then
let col = colorize pc color let col = colorize pc color
in G.Pixel px py col in G.Pixel px py col