1
0
Fork 0
mirror of https://github.com/ctruLua/ctruLua.git synced 2025-10-27 16:39:29 +00:00

Renamed item.fileSize to item.size in fs.list() return value, enabled 3D in the editor, added a lot of missing documentation

For the return values, I followed this rule: if the fuction returns true on success, it should return false, error on error; for every other case it should return nil, error on error.

Also, who doesn't want to edit code in 3D ? The line depth depends on the indentation level.
This commit is contained in:
Reuh 2016-04-22 13:42:59 +02:00
parent 2b7d37304d
commit 358b68c643
13 changed files with 143 additions and 72 deletions

View file

@ -1,5 +1,5 @@
/***
The `font` module
The `gfx.font` module
@module ctr.gfx.font
@usage local font = require("ctr.gfx.font")
*/
@ -21,7 +21,9 @@ u32 textSize = 9;
Load a TTF font.
@function load
@tparam string path path to the file
@treturn font the loaded font.
@treturn[1] font the loaded font.
@treturn[2] nil if an error occurred
@treturn[2] string error message
*/
static int font_load(lua_State *L) {
const char *path = luaL_checkstring(L, 1);