From f025cd2b5ad6c3d06d118175192eac04e229024d Mon Sep 17 00:00:00 2001 From: Jongmin Kim Date: Thu, 5 Sep 2019 01:26:57 -0700 Subject: [PATCH] Add Latin characters --- examples/all.html | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/examples/all.html b/examples/all.html index 5023769..8eb0625 100644 --- a/examples/all.html +++ b/examples/all.html @@ -54,7 +54,7 @@ }; leon = new LeonSans({ - text: 'abcdefghijklmn\nopqrstuvwxyz\nABCDEFGHIJK\nLMNOPQRST\nUVWXYZ\n0123456789\n?!$^&*(){}[]<>~\n:;,.\'"+=-_@#%', + text: 'abcdefghijklmn\nopqrstuvwxyz\nABCDEFGHIJK\nLMNOPQRST\nUVWXYZ\n0123456789\n?!$^&*(){}[]<>~\n:;,.\'"+=-_@#%\nÀÁÂÃÄÅàáâãäå\nÈÉÊËèéêëÑñÝýÿ\nÌÍÎÏìíîïÙÚÛÜùúûü\nÒÓÔÕÖØòóôõöø\nĈĜĤĴŜŬâĉĝĥĵŝŭ', color: ['#342f2e'], size: getSize(90), weight: 200, @@ -83,7 +83,8 @@ ctx.clearRect(0, 0, sw, sh); const x = (sw - leon.rect.w) / 2; - const y = (sh - leon.rect.h) / 2; + let y = (sh - leon.rect.h) / 2; + if (y < 0) y = 0; leon.position(x + moveX, y + moveY); ctx.save();