diff options
author | Colin Okay <colin@cicadas.surf> | 2022-07-20 10:04:59 -0500 |
---|---|---|
committer | Colin Okay <colin@cicadas.surf> | 2022-07-20 10:04:59 -0500 |
commit | 613f3381583537033e03285ab3f9242bbfbeba65 (patch) | |
tree | edea9934e89bd5288d6de5d899b2514f52394e8a /src/canvas-language.lisp | |
parent | fdd4275c181fbf86c9cac01eb651fb6885cdf371 (diff) |
[modify] how apply-pen-at handles pen width
Diffstat (limited to 'src/canvas-language.lisp')
-rw-r--r-- | src/canvas-language.lisp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/canvas-language.lisp b/src/canvas-language.lisp index 05cddfd..83e510f 100644 --- a/src/canvas-language.lisp +++ b/src/canvas-language.lisp @@ -109,14 +109,14 @@ saved by WITH-PEN-STATE" (defun apply-pen-at (x y) (let ((w - (max 0 (floor (* 0.5 *current-pen-width*))))) + (max 0 (1- *current-pen-width*)))) (destructuring-bind (cr cg cb ca) (etypecase *current-pen-color* (null (list 0 0 0 255)) (list *current-pen-color*) (function (funcall *current-pen-color* x y))) - (with-grid-rect (rx ry) ((- x w) (- y w) (+ x w) (+ y w)) + (with-grid-rect (rx ry) (x y (+ x w) (+ y w)) (when (can-fill-canvas-at-p rx ry) (with-pixel (r g b a) (pixel *current-canvas* rx ry) (setf r cr g cg b cb a ca))))))) |