From 927fefd4694837429f8c6e4d3a86be4538856142 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Sat, 4 Jul 2020 23:12:00 -0400 Subject: [PATCH] Fix --- commands/edit-image/gandhi-quote.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/commands/edit-image/gandhi-quote.js b/commands/edit-image/gandhi-quote.js index fa38217f..704107c9 100644 --- a/commands/edit-image/gandhi-quote.js +++ b/commands/edit-image/gandhi-quote.js @@ -4,7 +4,7 @@ const path = require('path'); const { wrapText } = require('../../util/Canvas'); registerFont(path.join(__dirname, '..', '..', 'assets', 'fonts', 'lmroman10-italic.otf'), { family: 'Latin Modern Roman', - weight: 'italic' + style: 'italic' }); module.exports = class GandhiQuoteCommand extends Command { @@ -51,7 +51,7 @@ module.exports = class GandhiQuoteCommand extends Command { ctx.drawImage(base, 0, 0); ctx.textAlign = 'center'; ctx.textBaseline = 'top'; - ctx.font = 'normal italic 50px Latin Modern Roman'; + ctx.font = 'italic 50px Latin Modern Roman'; let fontSize = 50; while (ctx.measureText(text).width > 1485) { fontSize--;