Skip to content

Commit

Permalink
Added scaling capabilities
Browse files Browse the repository at this point in the history
  • Loading branch information
TheCedarPrince committed Sep 28, 2021
1 parent de8f54f commit 7ffc1ba
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/shorthands/JImage.jl
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
function _JImage(pos, img, centering, shapeargs, shape)
function _JImage(pos, img, centering, shapeargs, shape, scaleargs)
if shape != false
shape(shapeargs...)
end
scale(scaleargs)
placeimage(img, pos, centered = centering)
return pos
end

JImage(pos::Point, img, centering = true; shapeargs = (), shape = false) =
JImage(pos::Point, img, centering = true; shapeargs = (), shape = false, scaleargs = 1) =
(
args...;
pos = pos,
img = img,
centering = centering,
shapeargs = shapeargs,
shape = shape,
) -> _JImage(pos, img, centering, shapeargs, shape)
scaleargs = scaleargs,
) -> _JImage(pos, img, centering, shapeargs, shape, scaleargs)

0 comments on commit 7ffc1ba

Please sign in to comment.