Fix documentation and behavior for 1.13 release
This commit is contained in:
+19
-10
@@ -102,8 +102,15 @@ local function create_user_directory()
|
||||
end
|
||||
for _, dirname in ipairs(subdirs) do
|
||||
dirname_create = dirname_create .. '/' .. dirname
|
||||
local success_mkdir = system.mkdir(dirname_create)
|
||||
if not success_mkdir then error("cannot create directory: \"" .. dirname_create .. "\"") end
|
||||
if not system.mkdir(dirname_create) then
|
||||
error("cannot create directory: \"" .. dirname_create .. "\"")
|
||||
end
|
||||
end
|
||||
for _, modname in ipairs(['plugins', 'colors']) do
|
||||
local subdirname = dirname_create .. '/' .. modname
|
||||
if not system.mkdir(subdirname) then
|
||||
error("cannot create directory: \"" .. subdirname .. "\"")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -242,14 +249,16 @@ end
|
||||
|
||||
function core.load_plugins()
|
||||
local no_errors = true
|
||||
local files = system.list_dir(DATADIR .. "/plugins")
|
||||
for _, filename in ipairs(files) do
|
||||
local modname = "plugins." .. filename:gsub(".lua$", "")
|
||||
local ok = core.try(require, modname)
|
||||
if ok then
|
||||
core.log_quiet("Loaded plugin %q", modname)
|
||||
else
|
||||
no_errors = false
|
||||
for _, root_dir in ipairs([DATADIR, USERDIR]) do
|
||||
local files = system.list_dir(root_dir .. "/plugins")
|
||||
for _, filename in ipairs(files) do
|
||||
local modname = "plugins." .. filename:gsub(".lua$", "")
|
||||
local ok = core.try(require, modname)
|
||||
if ok then
|
||||
core.log_quiet("Loaded plugin %q", modname)
|
||||
else
|
||||
no_errors = false
|
||||
end
|
||||
end
|
||||
end
|
||||
return no_errors
|
||||
|
||||
+4
-4
@@ -13,14 +13,14 @@ style.tab_width = common.round(170 * SCALE)
|
||||
-- {antialiasing= "grayscale", hinting = "full"}
|
||||
--
|
||||
-- The possible values for each option are:
|
||||
-- - for antialiang: grayscale, subpixel
|
||||
-- - for antialiasing: grayscale, subpixel
|
||||
-- - for hinting: none, slight, full
|
||||
--
|
||||
-- The defaults values are antialiang subpixel and hinting slight for optimal visualization
|
||||
-- The defaults values are antialiasing subpixel and hinting slight for optimal visualization
|
||||
-- on ordinary LCD monitor with RGB patterns.
|
||||
--
|
||||
-- On High DPI monitor or non RGB monitor you may consider using antialiang grayscale instead.
|
||||
-- The antialising grayscale with full hinting is interesting for crisp font rendering.
|
||||
-- On High DPI monitor or non RGB monitor you may consider using antialiasing grayscale instead.
|
||||
-- The antialiasing grayscale with full hinting is interesting for crisp font rendering.
|
||||
style.font = renderer.font.load(DATADIR .. "/fonts/font.ttf", 14 * SCALE)
|
||||
style.big_font = renderer.font.load(DATADIR .. "/fonts/font.ttf", 34 * SCALE)
|
||||
style.icon_font = renderer.font.load(DATADIR .. "/fonts/icons.ttf", 14 * SCALE, {antialiasing="grayscale", hinting="full"})
|
||||
|
||||
Reference in New Issue
Block a user