From 68b60be0d1da84aa670d29b87b26ab3e3db51b69 Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 15 Oct 2018 12:49:54 +0800 Subject: =?UTF-8?q?*=E5=A2=9E=E5=8A=A0=E9=BB=98=E8=AE=A4=E5=AD=97=E4=BD=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lua/modules/graphics/ttf.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/lua/modules/graphics/ttf.cpp') diff --git a/src/lua/modules/graphics/ttf.cpp b/src/lua/modules/graphics/ttf.cpp index 19e9e92..3d88a62 100644 --- a/src/lua/modules/graphics/ttf.cpp +++ b/src/lua/modules/graphics/ttf.cpp @@ -28,7 +28,7 @@ namespace lua { Proxy* p = (Proxy*)luax_checktype(L, 1, JIN_GRAPHICS_TTF); TTF* ttf = p->getObject(); - int lineheight = luax_checkinteger(L, 3); + int lineheight = luax_optnumber(L, 3, ttf->getFontSize()); int spacing = luax_optnumber(L, 4, 0); Page* page = nullptr; if (luax_isstring(L, 2)) -- cgit v1.1-26-g67d0