From 2189c1b1ac91ed838818632e7ca3b03930562b1c Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Sat, 20 Feb 2021 11:41:57 -0500 Subject: [PATCH] Fix --- commands/edit-image/font.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/commands/edit-image/font.js b/commands/edit-image/font.js index 5bdd5230..cbb7998e 100644 --- a/commands/edit-image/font.js +++ b/commands/edit-image/font.js @@ -43,12 +43,12 @@ module.exports = class FontCommand extends Command { const canvas = createCanvas(Math.min(len.width + 50, 500), 50 + (75 * lines.length)); const ctx = canvas.getContext('2d'); ctx.font = this.client.fonts.get(font.filename).toCanvasString(75); - ctx.textBaseline = 'middle'; + ctx.textBaseline = 'top'; ctx.textAlign = 'center'; ctx.fillStyle = 'white'; ctx.fillRect(0, 0, canvas.width, canvas.height); ctx.fillStyle = 'black'; - ctx.fillText(lines.join('\n'), canvas.width / 2, canvas.height / 2); + ctx.fillText(lines.join('\n'), canvas.width / 2, 25); return canvas.toBuffer(); } };