mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-23 18:05:01 +02:00
Fix
This commit is contained in:
@@ -65,6 +65,7 @@ module.exports = class MemeGenModernCommand extends Command {
|
|||||||
const lineBreakLen = text.split('\n').length;
|
const lineBreakLen = text.split('\n').length;
|
||||||
const linesLen = (40 * lines.length) + (40 * (lineBreakLen - 1)) + (9 * lines.length) + (9 * (lineBreakLen - 1));
|
const linesLen = (40 * lines.length) + (40 * (lineBreakLen - 1)) + (9 * lines.length) + (9 * (lineBreakLen - 1));
|
||||||
canvas.height += linesLen;
|
canvas.height += linesLen;
|
||||||
|
ctx.font = '40px Noto';
|
||||||
ctx.textBaseline = 'top';
|
ctx.textBaseline = 'top';
|
||||||
ctx.fillStyle = 'white';
|
ctx.fillStyle = 'white';
|
||||||
ctx.fillRect(0, 0, base.width, linesLen);
|
ctx.fillRect(0, 0, base.width, linesLen);
|
||||||
|
|||||||
Reference in New Issue
Block a user