Isaiah Odhner 2019-12-15 13:15:31 -05:00
parent 6b24bc26e1
commit 9948d8f9bb
1 changed files with 5 additions and 6 deletions

View File

@ -527,17 +527,16 @@ function rotate(angle){
function stretch_and_skew(xscale, yscale, hsa, vsa){ function stretch_and_skew(xscale, yscale, hsa, vsa){
apply_image_transformation({ apply_image_transformation({
name: ( name:
(hsa !== 0 || vsa !== 0) ? ( (hsa !== 0 || vsa !== 0) ? (
(xscale !== 1 || yscale !== 1) ? "Stretch/Skew" : "Skew" (xscale !== 1 || yscale !== 1) ? "Stretch/Skew" : "Skew"
) : "Stretch" ) : "Stretch",
),
icon: get_help_folder_icon( icon: get_help_folder_icon(
(hsa !== 0) ? "p_skew_h.png" : (hsa !== 0) ? "p_skew_h.png" :
(vsa !== 0) ? "p_skew_v.png" : (vsa !== 0) ? "p_skew_v.png" :
(xscale !== 1 && yscale !== 1) ? "p_stretch_both.png" : (yscale !== 1) ? (
(yscale !== 1) ? "p_stretch_v.png" : (xscale !== 1) ? "p_stretch_both.png" : "p_stretch_v.png"
"p_stretch_h.png" ) : "p_stretch_h.png"
), ),
}, (original_canvas, original_ctx, new_canvas, new_ctx) => { }, (original_canvas, original_ctx, new_canvas, new_ctx) => {
const w = original_canvas.width * xscale; const w = original_canvas.width * xscale;