diff --git a/lcdlib/LICENSE.txt b/lcdlib/LICENSE.txt
new file mode 100644
index 0000000..341c30b
--- /dev/null
+++ b/lcdlib/LICENSE.txt
@@ -0,0 +1,166 @@
+ GNU LESSER GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+
+ This version of the GNU Lesser General Public License incorporates
+the terms and conditions of version 3 of the GNU General Public
+License, supplemented by the additional permissions listed below.
+
+ 0. Additional Definitions.
+
+ As used herein, "this License" refers to version 3 of the GNU Lesser
+General Public License, and the "GNU GPL" refers to version 3 of the GNU
+General Public License.
+
+ "The Library" refers to a covered work governed by this License,
+other than an Application or a Combined Work as defined below.
+
+ An "Application" is any work that makes use of an interface provided
+by the Library, but which is not otherwise based on the Library.
+Defining a subclass of a class defined by the Library is deemed a mode
+of using an interface provided by the Library.
+
+ A "Combined Work" is a work produced by combining or linking an
+Application with the Library. The particular version of the Library
+with which the Combined Work was made is also called the "Linked
+Version".
+
+ The "Minimal Corresponding Source" for a Combined Work means the
+Corresponding Source for the Combined Work, excluding any source code
+for portions of the Combined Work that, considered in isolation, are
+based on the Application, and not on the Linked Version.
+
+ The "Corresponding Application Code" for a Combined Work means the
+object code and/or source code for the Application, including any data
+and utility programs needed for reproducing the Combined Work from the
+Application, but excluding the System Libraries of the Combined Work.
+
+ 1. Exception to Section 3 of the GNU GPL.
+
+ You may convey a covered work under sections 3 and 4 of this License
+without being bound by section 3 of the GNU GPL.
+
+ 2. Conveying Modified Versions.
+
+ If you modify a copy of the Library, and, in your modifications, a
+facility refers to a function or data to be supplied by an Application
+that uses the facility (other than as an argument passed when the
+facility is invoked), then you may convey a copy of the modified
+version:
+
+ a) under this License, provided that you make a good faith effort to
+ ensure that, in the event an Application does not supply the
+ function or data, the facility still operates, and performs
+ whatever part of its purpose remains meaningful, or
+
+ b) under the GNU GPL, with none of the additional permissions of
+ this License applicable to that copy.
+
+ 3. Object Code Incorporating Material from Library Header Files.
+
+ The object code form of an Application may incorporate material from
+a header file that is part of the Library. You may convey such object
+code under terms of your choice, provided that, if the incorporated
+material is not limited to numerical parameters, data structure
+layouts and accessors, or small macros, inline functions and templates
+(ten or fewer lines in length), you do both of the following:
+
+ a) Give prominent notice with each copy of the object code that the
+ Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the object code with a copy of the GNU GPL and this license
+ document.
+
+ 4. Combined Works.
+
+ You may convey a Combined Work under terms of your choice that,
+taken together, effectively do not restrict modification of the
+portions of the Library contained in the Combined Work and reverse
+engineering for debugging such modifications, if you also do each of
+the following:
+
+ a) Give prominent notice with each copy of the Combined Work that
+ the Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the Combined Work with a copy of the GNU GPL and this license
+ document.
+
+ c) For a Combined Work that displays copyright notices during
+ execution, include the copyright notice for the Library among
+ these notices, as well as a reference directing the user to the
+ copies of the GNU GPL and this license document.
+
+ d) Do one of the following:
+
+ 0) Convey the Minimal Corresponding Source under the terms of this
+ License, and the Corresponding Application Code in a form
+ suitable for, and under terms that permit, the user to
+ recombine or relink the Application with a modified version of
+ the Linked Version to produce a modified Combined Work, in the
+ manner specified by section 6 of the GNU GPL for conveying
+ Corresponding Source.
+
+ 1) Use a suitable shared library mechanism for linking with the
+ Library. A suitable mechanism is one that (a) uses at run time
+ a copy of the Library already present on the user's computer
+ system, and (b) will operate properly with a modified version
+ of the Library that is interface-compatible with the Linked
+ Version.
+
+ e) Provide Installation Information, but only if you would otherwise
+ be required to provide such information under section 6 of the
+ GNU GPL, and only to the extent that such information is
+ necessary to install and execute a modified version of the
+ Combined Work produced by recombining or relinking the
+ Application with a modified version of the Linked Version. (If
+ you use option 4d0, the Installation Information must accompany
+ the Minimal Corresponding Source and Corresponding Application
+ Code. If you use option 4d1, you must provide the Installation
+ Information in the manner specified by section 6 of the GNU GPL
+ for conveying Corresponding Source.)
+
+ 5. Combined Libraries.
+
+ You may place library facilities that are a work based on the
+Library side by side in a single library together with other library
+facilities that are not Applications and are not covered by this
+License, and convey such a combined library under terms of your
+choice, if you do both of the following:
+
+ a) Accompany the combined library with a copy of the same work based
+ on the Library, uncombined with any other library facilities,
+ conveyed under the terms of this License.
+
+ b) Give prominent notice with the combined library that part of it
+ is a work based on the Library, and explaining where to find the
+ accompanying uncombined form of the same work.
+
+ 6. Revised Versions of the GNU Lesser General Public License.
+
+ The Free Software Foundation may publish revised and/or new versions
+of the GNU Lesser General Public License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Library as you received it specifies that a certain numbered version
+of the GNU Lesser General Public License "or any later version"
+applies to it, you have the option of following the terms and
+conditions either of that published version or of any later version
+published by the Free Software Foundation. If the Library as you
+received it does not specify a version number of the GNU Lesser
+General Public License, you may choose any version of the GNU Lesser
+General Public License ever published by the Free Software Foundation.
+
+ If the Library as you received it specifies that a proxy can decide
+whether future versions of the GNU Lesser General Public License shall
+apply, that proxy's public statement of acceptance of any version is
+permanent authorization for you to choose that version for the
+Library.
+
diff --git a/lcdlib/README.md b/lcdlib/README.md
new file mode 100644
index 0000000..3f620e3
--- /dev/null
+++ b/lcdlib/README.md
@@ -0,0 +1,13 @@
+# LCD Lib
+
+This LCD Lib is based on Display Lib and Font Lib from Pierre-Yves Rollo
+
+**Dependancies**: default
+
+**License**: LGPL
+
+Code by Pierre-Yves Rollo (pyrollo)
+Textures by Vanessa Ezekowitz (VanessaE).
+(Default font taken from VanessaE's homedecor/signs_lib, originally under WTFPL)
+
+
diff --git a/lcdlib/copyright.txt b/lcdlib/copyright.txt
new file mode 100644
index 0000000..eb0ec6a
--- /dev/null
+++ b/lcdlib/copyright.txt
@@ -0,0 +1,2 @@
+Code by Pierre-Yves Rollo (pyrollo)
+Textures by Vanessa Ezekowitz (VanessaE)
diff --git a/lcdlib/depends.txt b/lcdlib/depends.txt
new file mode 100644
index 0000000..e69de29
diff --git a/lcdlib/display.lua b/lcdlib/display.lua
new file mode 100644
index 0000000..de8689a
--- /dev/null
+++ b/lcdlib/display.lua
@@ -0,0 +1,229 @@
+--[[
+ cldlib based on:
+
+ display_lib mod for Minetest - Library to add dynamic display
+ capabilities to nodes
+ (c) Pierre-Yves Rollo
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+--]]
+
+-- Miscelaneous values depending on wallmounted param2
+local wallmounted_values = {
+ [0]={dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0}, -- Should never be used
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=1}, -- Should never be used
+ {dx=-1, dz=0, rx=0, rz=-1, yaw=-math.pi/2, rotate=5},
+ {dx=1, dz=0, rx=0, rz=1, yaw=math.pi/2, rotate=4},
+ {dx=0, dz=-1, rx=1, rz=0, yaw=0, rotate=2},
+ {dx=0, dz=1, rx=-1, rz=0, yaw=math.pi, rotate=3}
+}
+
+-- Miscelaneous values depending on facedir param2
+local facedir_values = {
+ [0]={dx=0, dz=-1, rx=1, rz=0, yaw=0, rotate=1},
+ {dx=-1, dz=0, rx=0, rz=-1, yaw=-math.pi/2, rotate=2},
+ {dx=0, dz=1, rx=-1, rz=0, yaw=math.pi, rotate=3},
+ {dx=1, dz=0, rx=0, rz=1, yaw=math.pi/2, rotate=0},
+ -- Forbiden values :
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ {dx=0, dz=0, rx=0, rz=0, yaw=0, rotate=0},
+ }
+
+-- dx/dy = depth vector, rx/ly = right vector, yaw = yaw of entity,
+-- rotate = next facedir/wallmount on rotate
+
+local function get_values(node)
+ local ndef = minetest.registered_nodes[node.name]
+
+ if ndef then
+ if ndef.paramtype2 == "wallmounted" then
+ return wallmounted_values[node.param2]
+ end
+ if ndef.paramtype2 == "facedir" then
+ return facedir_values[node.param2]
+ end
+ end
+end
+
+--- Gets the display entities attached with a node. Removes extra ones
+local function get_entities(pos)
+ local objrefs = {}
+ local ndef = minetest.registered_nodes[minetest.get_node(pos).name]
+ if ndef and ndef.display_entities then
+ for _, objref in ipairs(minetest.get_objects_inside_radius(pos, 0.5)) do
+ local entity = objref:get_luaentity()
+ if entity and ndef.display_entities[entity.name] then
+ if objrefs[entity.name] then
+ objref:remove()
+ else
+ objrefs[entity.name] = objref
+ end
+ end
+ end
+ end
+ return objrefs
+end
+
+local function clip_pos_prop(posprop)
+ if posprop then
+ return math.max(-0.5, math.min(0.5, posprop))
+ else
+ return 0
+ end
+end
+
+--- (Create and) place display entities according to the node orientation
+local function place_entities(pos)
+ local node = minetest.get_node(pos)
+ local ndef = minetest.registered_nodes[node.name]
+ local values = get_values(node)
+ local objrefs = get_entities(pos)
+
+ if values and ndef and ndef.display_entities then
+
+ for entity_name, props in pairs(ndef.display_entities) do
+ local depth = clip_pos_prop(props.depth)
+ local height = clip_pos_prop(props.height)
+ local right = clip_pos_prop(props.right)
+ if not objrefs[entity_name] then
+ objrefs[entity_name] = minetest.add_entity(pos, entity_name)
+ end
+
+ objrefs[entity_name]:setpos({
+ x = pos.x - values.dx * depth + values.rx * right,
+ y = pos.y + height,
+ z = pos.z - values.dz * depth + values.rz * right})
+
+ objrefs[entity_name]:setyaw(values.yaw)
+ end
+ end
+ return objrefs
+end
+
+--- Call on_display_update callback of a node for one of its display entities
+local function call_node_on_display_update(pos, objref)
+ local ndef = minetest.registered_nodes[minetest.get_node(pos).name]
+ local entity = objref:get_luaentity()
+ if ndef and ndef.display_entities and entity and ndef.display_entities[entity.name] then
+ ndef.display_entities[entity.name].on_display_update(pos, objref)
+ end
+end
+
+--- Force entity update
+function lcdlib.update_entities(pos)
+ local objrefs = place_entities(pos)
+ for _, objref in pairs(objrefs) do
+ call_node_on_display_update(pos, objref)
+ end
+end
+
+--- On_activate callback for lcdlib entities. Calls on_display_update callbacks
+--- of corresponding node for each entity.
+function lcdlib.on_activate(entity, staticdata)
+ if entity then
+ entity.object:set_armor_groups({immortal=1})
+ call_node_on_display_update(entity.object:getpos(), entity.object)
+ end
+end
+
+--- On_place callback for lcdlib items. Does nothing more than preventing item
+--- from being placed on ceiling or ground
+function lcdlib.on_place(itemstack, placer, pointed_thing)
+ local ndef = itemstack:get_definition()
+ local above = pointed_thing.above
+ local under = pointed_thing.under
+ local dir = {x = under.x - above.x,
+ y = under.y - above.y,
+ z = under.z - above.z}
+
+ if ndef then
+ if ndef.paramtype2 == "wallmounted" then
+
+ local wdir = minetest.dir_to_wallmounted(dir)
+
+ if wdir == 0 or wdir == 1 then
+ dir = placer:get_look_dir()
+ dir.y = 0
+ wdir = minetest.dir_to_wallmounted(dir)
+ end
+
+ return minetest.item_place(itemstack, placer, pointed_thing, wdir)
+ else
+ return minetest.item_place(itemstack, placer, pointed_thing, minetest.dir_to_facedir(dir))
+ end
+ end
+
+end
+
+--- On_construct callback for lcdlib items. Creates entities and update them.
+function lcdlib.on_construct(pos)
+ lcdlib.update_entities(pos)
+end
+
+--- On_destruct callback for lcdlib items. Removes entities.
+function lcdlib.on_destruct(pos)
+ local objrefs = get_entities(pos)
+
+ for _, objref in pairs(objrefs) do
+ objref:remove()
+ end
+end
+
+-- On_rotate (screwdriver) callback for lcdlib items. Prevents axis rotation and reorients entities.
+function lcdlib.on_rotate(pos, node, user, mode, new_param2)
+ if mode ~= 1 then return false end
+
+ local values = get_values(node)
+
+ if values then
+ minetest.swap_node(pos, {name = node.name, param1 = node.param1, param2 = values.rotate})
+ place_entities(pos)
+ return true
+ else
+ return false
+ end
+end
+
+--- Creates display entity with some fields and the on_activate callback
+function lcdlib.register_display_entity(entity_name)
+ if not minetest.registered_entity then
+ minetest.register_entity(':'..entity_name, {
+ collisionbox = { 0, 0, 0, 0, 0, 0 },
+ visual = "upright_sprite",
+ textures = {},
+ on_activate = lcdlib.on_activate,
+ })
+ end
+end
+
+
+
diff --git a/lcdlib/font_default.lua b/lcdlib/font_default.lua
new file mode 100644
index 0000000..1802b57
--- /dev/null
+++ b/lcdlib/font_default.lua
@@ -0,0 +1,12 @@
+--[[
+
+ generated by tools/make_font_lua.sh Thu Dec 21 21:45:53 CET 2017
+
+--]]
+
+lcdlib.register_font(
+ 'default',
+ 12,
+ { [0]=6, [32]=4, [33]=3, [34]=4, [35]=7, [36]=6, [37]=8, [38]=8, [39]=3, [40]=4, [41]=4, [42]=4, [43]=7, [44]=3, [45]=5, [46]=3, [47]=5, [48]=6, [49]=4, [50]=6, [51]=6, [52]=7, [53]=6, [54]=6, [55]=6, [56]=6, [57]=6, [58]=3, [59]=3, [60]=5, [61]=6, [62]=5, [63]=6, [64]=11, [65]=8, [66]=7, [67]=8, [68]=7, [69]=6, [70]=6, [71]=8, [72]=7, [73]=3, [74]=6, [75]=8, [76]=6, [77]=10, [78]=8, [79]=8, [80]=7, [81]=8, [82]=7, [83]=7, [84]=7, [85]=7, [86]=8, [87]=11, [88]=8, [89]=9, [90]=7, [91]=4, [92]=5, [93]=4, [94]=5, [95]=7, [96]=3, [97]=7, [98]=6, [99]=5, [100]=6, [101]=6, [102]=5, [103]=6, [104]=6, [105]=3, [106]=3, [107]=7, [108]=3, [109]=9, [110]=6, [111]=6, [112]=6, [113]=6, [114]=5, [115]=6, [116]=4, [117]=6, [118]=6, [119]=8, [120]=7, [121]=6, [122]=6, [123]=5, [124]=3, [125]=5, [126]=6, [138]=6, [141]=3, [161]=3, [177]=6, [191]=6, [192]=8, [193]=8, [194]=8, [195]=8, [196]=8, [197]=8, [198]=10, [199]=8, [200]=6, [201]=6, [202]=6, [203]=6, [204]=3, [205]=3, [206]=3, [207]=3, [208]=8, [209]=8, [210]=8, [211]=8, [212]=8, [213]=8, [214]=8, [215]=6, [216]=8, [217]=7, [218]=7, [219]=7, [220]=7, [221]=9, [224]=7, [225]=7, [226]=7, [227]=7, [228]=7, [229]=7, [230]=9, [231]=5, [232]=6, [233]=6, [234]=6, [235]=6, [236]=3, [237]=3, [238]=3, [239]=3, [242]=6, [244]=6, [245]=6, [246]=6, [247]=6, [249]=6, [250]=6, [251]=6, [252]=6, [253]=6, [255]=6 }
+);
+
diff --git a/lcdlib/init.lua b/lcdlib/init.lua
new file mode 100644
index 0000000..ef14d6f
--- /dev/null
+++ b/lcdlib/init.lua
@@ -0,0 +1,277 @@
+--[[
+ lcdlib based on:
+
+ font_lib mod for Minetest - Library to add font display capability
+ to display_lib mod.
+ (c) Pierre-Yves Rollo
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see .
+--]]
+
+-- Global variables
+lcdlib = {}
+lcdlib.registered_fonts = {}
+
+-- Local functions
+------------------
+
+-- Split multiline text into array of lines, with maximum lines.
+
+local function split_lines(text, maxlines)
+ local splits = text:split("\n")
+ if maxlines then
+ local lines = {}
+ for num = 1,maxlines do
+ lines[num] = splits[num]
+ end
+ return lines
+ else
+ return splits
+ end
+end
+
+-- Returns next char, managing ascii and unicode plane 0 (0000-FFFF).
+
+local function get_next_char(text, pos)
+ pos = pos + 1
+ local char = text:sub(pos, pos):byte()
+
+ -- 1 byte char
+ if char < 0x80 then
+ return char, pos
+ end
+
+ -- 4 bytes char not managed
+ if char >= 0xF0 then
+ pos = pos + 3
+ return 0, pos
+ end
+
+ -- 3 bytes char not managed
+ if char >= 0xE0 then
+ pos = pos + 2
+ return 0, pos
+ end
+
+ -- 2 bytes char (little endian)
+ if char >= 0xC2 then
+ pos = pos + 1
+ return (char - 0xC2) * 0x40 + text:sub(pos, pos):byte(), pos
+ end
+
+ -- Not an UTF char
+ return 0, pos
+
+end
+
+-- Returns font properties to be used according to font_name
+
+local function get_font(font_name)
+ local font = lcdlib.registered_fonts[font_name]
+
+ if font == nil then
+ local message
+
+ if font_name == nil then
+ message = "No font given"
+ else
+ message = "Font \""..font_name.."\" unregistered"
+ end
+
+ if lcdlib.fallback_font == nil then
+ minetest.log("error", message.." and no other font registered.")
+ else
+ minetest.log("info", message..", using font \""..lcdlib.fallback_font.."\".")
+ font = lcdlib.registered_fonts[lcdlib.fallback_font]
+ end
+ end
+
+ return font
+end
+
+-- API functions
+----------------
+
+-- Computes text size for a given font and text (ignores new lines)
+-- @param font_name Font to be used
+-- @param text Text to be rendered
+-- @return Rendered text (width, height)
+
+function lcdlib.get_text_size(font_name, text)
+ local char
+ local width = 0
+ local pos = 0
+ local font = get_font(font_name)
+
+ if font == nil then
+ return 0, 0
+ else
+ while pos < #text do
+ char, pos = get_next_char(text, pos)
+ -- Ignore chars with no texture
+ if font.widths[char] ~= nil then
+ width = width + font.widths[char]
+ end
+ end
+ end
+
+ return width, font.height
+end
+
+--- Builds texture part for a text line
+-- @param font_name Font to be used
+-- @param text Text to be rendered
+-- @param width Width of the texture (extra text is not rendered)
+-- @param x Starting x position in texture
+-- @param y Vertical position of the line in texture
+-- @return Texture string
+
+--> ADD ALIGN
+function lcdlib.make_line_texture(font_name, text, width, x, y)
+ local texture = ""
+ local char
+ local pos = 0
+ local font = get_font(font_name)
+
+ if font ~= nil then
+ while pos < #text do
+ char, pos = get_next_char(text, pos)
+
+ -- Ignore chars with no texture
+ if font.widths[char] ~= nil then
+ -- Add image only if it is visible (at least partly)
+ if x + font.widths[char] >= 0 and x <= width then
+ texture = texture..
+ string.format(":%d,%d=font_%s_%04x.png",
+ x, y, font.name, char)
+ end
+ x = x + font.widths[char]
+ else
+ print(string.format("Missing char %d (%04x)",char,char))
+ end
+ end
+ end
+
+ return texture
+end
+
+--- Builds texture for a multiline colored text
+-- @param font_name Font to be used
+-- @param text Text to be rendered
+-- @param texturew Width of the texture (extra text will be truncated)
+-- @param textureh Height of the texture
+-- @param maxlines Maximum number of lines
+-- @param valign Vertical text align ("top" or "center")
+-- @param color Color of the text
+-- @return Texture string
+
+function lcdlib.make_multiline_texture(font_name, text, width, height,
+ maxlines, valign, color)
+ local texture = ""
+ local lines = {}
+ local textheight = 0
+ local y, w, h
+
+ for num, line in pairs(split_lines(text, maxlines)) do
+ w, h = lcdlib.get_text_size(font_name, line)
+ lines[num] = { text = line, width = w, height = h, }
+ textheight = textheight + h
+ end
+
+ if #lines then
+ if valign == "top" then
+ y = 0
+ elseif valign == "bottom" then
+ y = height - textheight
+ else
+ y = (height - textheight) / 2
+ end
+ end
+
+ for _, line in pairs(lines) do
+ texture = texture..
+ lcdlib.make_line_texture(font_name, line.text, width,
+ (width - line.width) / 2, y)
+ y = y + line.height
+ end
+
+ texture = string.format("[combine:%dx%d", width, height)..texture
+ if color then texture = texture.."^[colorize:"..color end
+
+ return texture
+end
+
+--- Register a new font
+-- Textures corresponding to the font should be named after following patern :
+-- font__.png
+-- : name of the font
+-- : 4 digit hexadecimal unicode of the char
+-- If registering different sizes, add size in the font name (e.g. times_10, times_12...)
+-- @param height Font height in pixels
+-- @param widths Array of character widths in pixel, indexed by unicode number.
+
+function lcdlib.register_font(font_name, height, widths)
+ if lcdlib.registered_fonts[font_name] ~= nil then
+ minetest.log("error", "Font \""..font_name.."\" already registered.")
+ return
+ end
+
+ lcdlib.registered_fonts[font_name] =
+ { name = font_name, height = height, widths = widths }
+
+ -- If no fallback font, set it (so, first font registered will be the default fallback font)
+ if lcdlib.fallback_font == nil then
+ lcdlib.fallback_font = font_name
+ end
+end
+
+--- Define the fallback font
+-- This font will be used instead of given font if not registered.
+-- @param font_name Name of the font to be used as fallback font (has to be registered).
+
+function lcdlib.set_fallback_font(font_name)
+ if lcdlib.registered_fonts[font_name] == nil then
+ minetest.log("error", "Fallback font \""..font_name.."\" not registered.")
+ else
+ lcdlib.fallback_font = font_name
+ end
+end
+
+--- Standard on_display_update entity callback.
+-- Node should have a corresponding display_entity with size, resolution and maxlines fields and
+-- optionally valign and color fields
+-- @param pos Node position
+-- @param objref Object reference of entity
+
+function lcdlib.on_display_update(pos, objref)
+ local meta = minetest.get_meta(pos)
+ local text = meta:get_string("display_text")
+ local ndef = minetest.registered_nodes[minetest.get_node(pos).name]
+ local entity = objref:get_luaentity()
+
+ if entity and ndef.display_entities[entity.name] then
+ local def = ndef.display_entities[entity.name]
+
+ objref:set_properties({
+ textures={lcdlib.make_multiline_texture(
+ def.font_name, text, def.size.x*def.resolution.x, def.size.y*def.resolution.y,
+ def.maxlines, def.valign, def.color)},
+ visual_size = def.size
+ })
+ end
+end
+
+dofile(minetest.get_modpath("lcdlib").."/font_default.lua")
+dofile(minetest.get_modpath("lcdlib").."/display.lua")
+
diff --git a/lcdlib/textures/font_default_0000.png b/lcdlib/textures/font_default_0000.png
new file mode 100644
index 0000000..65e43a7
Binary files /dev/null and b/lcdlib/textures/font_default_0000.png differ
diff --git a/lcdlib/textures/font_default_0020.png b/lcdlib/textures/font_default_0020.png
new file mode 100644
index 0000000..049fd14
Binary files /dev/null and b/lcdlib/textures/font_default_0020.png differ
diff --git a/lcdlib/textures/font_default_0021.png b/lcdlib/textures/font_default_0021.png
new file mode 100644
index 0000000..7691a14
Binary files /dev/null and b/lcdlib/textures/font_default_0021.png differ
diff --git a/lcdlib/textures/font_default_0022.png b/lcdlib/textures/font_default_0022.png
new file mode 100644
index 0000000..91f4c5f
Binary files /dev/null and b/lcdlib/textures/font_default_0022.png differ
diff --git a/lcdlib/textures/font_default_0023.png b/lcdlib/textures/font_default_0023.png
new file mode 100644
index 0000000..9290dc1
Binary files /dev/null and b/lcdlib/textures/font_default_0023.png differ
diff --git a/lcdlib/textures/font_default_0024.png b/lcdlib/textures/font_default_0024.png
new file mode 100644
index 0000000..cde69d4
Binary files /dev/null and b/lcdlib/textures/font_default_0024.png differ
diff --git a/lcdlib/textures/font_default_0025.png b/lcdlib/textures/font_default_0025.png
new file mode 100644
index 0000000..703ab16
Binary files /dev/null and b/lcdlib/textures/font_default_0025.png differ
diff --git a/lcdlib/textures/font_default_0026.png b/lcdlib/textures/font_default_0026.png
new file mode 100644
index 0000000..6f98d49
Binary files /dev/null and b/lcdlib/textures/font_default_0026.png differ
diff --git a/lcdlib/textures/font_default_0027.png b/lcdlib/textures/font_default_0027.png
new file mode 100644
index 0000000..df31d75
Binary files /dev/null and b/lcdlib/textures/font_default_0027.png differ
diff --git a/lcdlib/textures/font_default_0028.png b/lcdlib/textures/font_default_0028.png
new file mode 100644
index 0000000..478c2c4
Binary files /dev/null and b/lcdlib/textures/font_default_0028.png differ
diff --git a/lcdlib/textures/font_default_0029.png b/lcdlib/textures/font_default_0029.png
new file mode 100644
index 0000000..8973488
Binary files /dev/null and b/lcdlib/textures/font_default_0029.png differ
diff --git a/lcdlib/textures/font_default_002a.png b/lcdlib/textures/font_default_002a.png
new file mode 100644
index 0000000..2b83a5c
Binary files /dev/null and b/lcdlib/textures/font_default_002a.png differ
diff --git a/lcdlib/textures/font_default_002b.png b/lcdlib/textures/font_default_002b.png
new file mode 100644
index 0000000..abce910
Binary files /dev/null and b/lcdlib/textures/font_default_002b.png differ
diff --git a/lcdlib/textures/font_default_002c.png b/lcdlib/textures/font_default_002c.png
new file mode 100644
index 0000000..8a624c7
Binary files /dev/null and b/lcdlib/textures/font_default_002c.png differ
diff --git a/lcdlib/textures/font_default_002d.png b/lcdlib/textures/font_default_002d.png
new file mode 100644
index 0000000..f0ff962
Binary files /dev/null and b/lcdlib/textures/font_default_002d.png differ
diff --git a/lcdlib/textures/font_default_002e.png b/lcdlib/textures/font_default_002e.png
new file mode 100644
index 0000000..aff49bc
Binary files /dev/null and b/lcdlib/textures/font_default_002e.png differ
diff --git a/lcdlib/textures/font_default_002f.png b/lcdlib/textures/font_default_002f.png
new file mode 100644
index 0000000..4667bf7
Binary files /dev/null and b/lcdlib/textures/font_default_002f.png differ
diff --git a/lcdlib/textures/font_default_0030.png b/lcdlib/textures/font_default_0030.png
new file mode 100644
index 0000000..470f0b0
Binary files /dev/null and b/lcdlib/textures/font_default_0030.png differ
diff --git a/lcdlib/textures/font_default_0031.png b/lcdlib/textures/font_default_0031.png
new file mode 100644
index 0000000..e84a9d3
Binary files /dev/null and b/lcdlib/textures/font_default_0031.png differ
diff --git a/lcdlib/textures/font_default_0032.png b/lcdlib/textures/font_default_0032.png
new file mode 100644
index 0000000..1ef3e84
Binary files /dev/null and b/lcdlib/textures/font_default_0032.png differ
diff --git a/lcdlib/textures/font_default_0033.png b/lcdlib/textures/font_default_0033.png
new file mode 100644
index 0000000..ec9f518
Binary files /dev/null and b/lcdlib/textures/font_default_0033.png differ
diff --git a/lcdlib/textures/font_default_0034.png b/lcdlib/textures/font_default_0034.png
new file mode 100644
index 0000000..bc82823
Binary files /dev/null and b/lcdlib/textures/font_default_0034.png differ
diff --git a/lcdlib/textures/font_default_0035.png b/lcdlib/textures/font_default_0035.png
new file mode 100644
index 0000000..3ed26c5
Binary files /dev/null and b/lcdlib/textures/font_default_0035.png differ
diff --git a/lcdlib/textures/font_default_0036.png b/lcdlib/textures/font_default_0036.png
new file mode 100644
index 0000000..6e706a4
Binary files /dev/null and b/lcdlib/textures/font_default_0036.png differ
diff --git a/lcdlib/textures/font_default_0037.png b/lcdlib/textures/font_default_0037.png
new file mode 100644
index 0000000..884b48a
Binary files /dev/null and b/lcdlib/textures/font_default_0037.png differ
diff --git a/lcdlib/textures/font_default_0038.png b/lcdlib/textures/font_default_0038.png
new file mode 100644
index 0000000..a1e05bf
Binary files /dev/null and b/lcdlib/textures/font_default_0038.png differ
diff --git a/lcdlib/textures/font_default_0039.png b/lcdlib/textures/font_default_0039.png
new file mode 100644
index 0000000..6443be9
Binary files /dev/null and b/lcdlib/textures/font_default_0039.png differ
diff --git a/lcdlib/textures/font_default_003a.png b/lcdlib/textures/font_default_003a.png
new file mode 100644
index 0000000..752e9de
Binary files /dev/null and b/lcdlib/textures/font_default_003a.png differ
diff --git a/lcdlib/textures/font_default_003b.png b/lcdlib/textures/font_default_003b.png
new file mode 100644
index 0000000..77878e8
Binary files /dev/null and b/lcdlib/textures/font_default_003b.png differ
diff --git a/lcdlib/textures/font_default_003c.png b/lcdlib/textures/font_default_003c.png
new file mode 100644
index 0000000..0252ab9
Binary files /dev/null and b/lcdlib/textures/font_default_003c.png differ
diff --git a/lcdlib/textures/font_default_003d.png b/lcdlib/textures/font_default_003d.png
new file mode 100644
index 0000000..af0325a
Binary files /dev/null and b/lcdlib/textures/font_default_003d.png differ
diff --git a/lcdlib/textures/font_default_003e.png b/lcdlib/textures/font_default_003e.png
new file mode 100644
index 0000000..77fe954
Binary files /dev/null and b/lcdlib/textures/font_default_003e.png differ
diff --git a/lcdlib/textures/font_default_003f.png b/lcdlib/textures/font_default_003f.png
new file mode 100644
index 0000000..e94177c
Binary files /dev/null and b/lcdlib/textures/font_default_003f.png differ
diff --git a/lcdlib/textures/font_default_0040.png b/lcdlib/textures/font_default_0040.png
new file mode 100644
index 0000000..c7a11d2
Binary files /dev/null and b/lcdlib/textures/font_default_0040.png differ
diff --git a/lcdlib/textures/font_default_0041.png b/lcdlib/textures/font_default_0041.png
new file mode 100644
index 0000000..5917cc0
Binary files /dev/null and b/lcdlib/textures/font_default_0041.png differ
diff --git a/lcdlib/textures/font_default_0042.png b/lcdlib/textures/font_default_0042.png
new file mode 100644
index 0000000..69a92b3
Binary files /dev/null and b/lcdlib/textures/font_default_0042.png differ
diff --git a/lcdlib/textures/font_default_0043.png b/lcdlib/textures/font_default_0043.png
new file mode 100644
index 0000000..6f68703
Binary files /dev/null and b/lcdlib/textures/font_default_0043.png differ
diff --git a/lcdlib/textures/font_default_0044.png b/lcdlib/textures/font_default_0044.png
new file mode 100644
index 0000000..94c0a30
Binary files /dev/null and b/lcdlib/textures/font_default_0044.png differ
diff --git a/lcdlib/textures/font_default_0045.png b/lcdlib/textures/font_default_0045.png
new file mode 100644
index 0000000..b6732c3
Binary files /dev/null and b/lcdlib/textures/font_default_0045.png differ
diff --git a/lcdlib/textures/font_default_0046.png b/lcdlib/textures/font_default_0046.png
new file mode 100644
index 0000000..992bdc1
Binary files /dev/null and b/lcdlib/textures/font_default_0046.png differ
diff --git a/lcdlib/textures/font_default_0047.png b/lcdlib/textures/font_default_0047.png
new file mode 100644
index 0000000..12340e7
Binary files /dev/null and b/lcdlib/textures/font_default_0047.png differ
diff --git a/lcdlib/textures/font_default_0048.png b/lcdlib/textures/font_default_0048.png
new file mode 100644
index 0000000..f315c03
Binary files /dev/null and b/lcdlib/textures/font_default_0048.png differ
diff --git a/lcdlib/textures/font_default_0049.png b/lcdlib/textures/font_default_0049.png
new file mode 100644
index 0000000..53ef0bc
Binary files /dev/null and b/lcdlib/textures/font_default_0049.png differ
diff --git a/lcdlib/textures/font_default_004a.png b/lcdlib/textures/font_default_004a.png
new file mode 100644
index 0000000..32cd569
Binary files /dev/null and b/lcdlib/textures/font_default_004a.png differ
diff --git a/lcdlib/textures/font_default_004b.png b/lcdlib/textures/font_default_004b.png
new file mode 100644
index 0000000..1f770e7
Binary files /dev/null and b/lcdlib/textures/font_default_004b.png differ
diff --git a/lcdlib/textures/font_default_004c.png b/lcdlib/textures/font_default_004c.png
new file mode 100644
index 0000000..313ecfe
Binary files /dev/null and b/lcdlib/textures/font_default_004c.png differ
diff --git a/lcdlib/textures/font_default_004d.png b/lcdlib/textures/font_default_004d.png
new file mode 100644
index 0000000..f6676fb
Binary files /dev/null and b/lcdlib/textures/font_default_004d.png differ
diff --git a/lcdlib/textures/font_default_004e.png b/lcdlib/textures/font_default_004e.png
new file mode 100644
index 0000000..4e28110
Binary files /dev/null and b/lcdlib/textures/font_default_004e.png differ
diff --git a/lcdlib/textures/font_default_004f.png b/lcdlib/textures/font_default_004f.png
new file mode 100644
index 0000000..1b27777
Binary files /dev/null and b/lcdlib/textures/font_default_004f.png differ
diff --git a/lcdlib/textures/font_default_0050.png b/lcdlib/textures/font_default_0050.png
new file mode 100644
index 0000000..ddfff40
Binary files /dev/null and b/lcdlib/textures/font_default_0050.png differ
diff --git a/lcdlib/textures/font_default_0051.png b/lcdlib/textures/font_default_0051.png
new file mode 100644
index 0000000..c3df8ec
Binary files /dev/null and b/lcdlib/textures/font_default_0051.png differ
diff --git a/lcdlib/textures/font_default_0052.png b/lcdlib/textures/font_default_0052.png
new file mode 100644
index 0000000..f93ff7c
Binary files /dev/null and b/lcdlib/textures/font_default_0052.png differ
diff --git a/lcdlib/textures/font_default_0053.png b/lcdlib/textures/font_default_0053.png
new file mode 100644
index 0000000..389a62b
Binary files /dev/null and b/lcdlib/textures/font_default_0053.png differ
diff --git a/lcdlib/textures/font_default_0054.png b/lcdlib/textures/font_default_0054.png
new file mode 100644
index 0000000..11ec544
Binary files /dev/null and b/lcdlib/textures/font_default_0054.png differ
diff --git a/lcdlib/textures/font_default_0055.png b/lcdlib/textures/font_default_0055.png
new file mode 100644
index 0000000..5d15704
Binary files /dev/null and b/lcdlib/textures/font_default_0055.png differ
diff --git a/lcdlib/textures/font_default_0056.png b/lcdlib/textures/font_default_0056.png
new file mode 100644
index 0000000..3e6f48a
Binary files /dev/null and b/lcdlib/textures/font_default_0056.png differ
diff --git a/lcdlib/textures/font_default_0057.png b/lcdlib/textures/font_default_0057.png
new file mode 100644
index 0000000..cc140d0
Binary files /dev/null and b/lcdlib/textures/font_default_0057.png differ
diff --git a/lcdlib/textures/font_default_0058.png b/lcdlib/textures/font_default_0058.png
new file mode 100644
index 0000000..fe71fb9
Binary files /dev/null and b/lcdlib/textures/font_default_0058.png differ
diff --git a/lcdlib/textures/font_default_0059.png b/lcdlib/textures/font_default_0059.png
new file mode 100644
index 0000000..1d1db03
Binary files /dev/null and b/lcdlib/textures/font_default_0059.png differ
diff --git a/lcdlib/textures/font_default_005a.png b/lcdlib/textures/font_default_005a.png
new file mode 100644
index 0000000..e89b0eb
Binary files /dev/null and b/lcdlib/textures/font_default_005a.png differ
diff --git a/lcdlib/textures/font_default_005b.png b/lcdlib/textures/font_default_005b.png
new file mode 100644
index 0000000..e547c51
Binary files /dev/null and b/lcdlib/textures/font_default_005b.png differ
diff --git a/lcdlib/textures/font_default_005c.png b/lcdlib/textures/font_default_005c.png
new file mode 100644
index 0000000..35fc222
Binary files /dev/null and b/lcdlib/textures/font_default_005c.png differ
diff --git a/lcdlib/textures/font_default_005d.png b/lcdlib/textures/font_default_005d.png
new file mode 100644
index 0000000..040ebe0
Binary files /dev/null and b/lcdlib/textures/font_default_005d.png differ
diff --git a/lcdlib/textures/font_default_005e.png b/lcdlib/textures/font_default_005e.png
new file mode 100644
index 0000000..be3bbb1
Binary files /dev/null and b/lcdlib/textures/font_default_005e.png differ
diff --git a/lcdlib/textures/font_default_005f.png b/lcdlib/textures/font_default_005f.png
new file mode 100644
index 0000000..3cc8d3d
Binary files /dev/null and b/lcdlib/textures/font_default_005f.png differ
diff --git a/lcdlib/textures/font_default_0060.png b/lcdlib/textures/font_default_0060.png
new file mode 100644
index 0000000..58500d2
Binary files /dev/null and b/lcdlib/textures/font_default_0060.png differ
diff --git a/lcdlib/textures/font_default_0061.png b/lcdlib/textures/font_default_0061.png
new file mode 100644
index 0000000..2121aa8
Binary files /dev/null and b/lcdlib/textures/font_default_0061.png differ
diff --git a/lcdlib/textures/font_default_0062.png b/lcdlib/textures/font_default_0062.png
new file mode 100644
index 0000000..ba3feeb
Binary files /dev/null and b/lcdlib/textures/font_default_0062.png differ
diff --git a/lcdlib/textures/font_default_0063.png b/lcdlib/textures/font_default_0063.png
new file mode 100644
index 0000000..cee372c
Binary files /dev/null and b/lcdlib/textures/font_default_0063.png differ
diff --git a/lcdlib/textures/font_default_0064.png b/lcdlib/textures/font_default_0064.png
new file mode 100644
index 0000000..c5989c1
Binary files /dev/null and b/lcdlib/textures/font_default_0064.png differ
diff --git a/lcdlib/textures/font_default_0065.png b/lcdlib/textures/font_default_0065.png
new file mode 100644
index 0000000..7cd370a
Binary files /dev/null and b/lcdlib/textures/font_default_0065.png differ
diff --git a/lcdlib/textures/font_default_0066.png b/lcdlib/textures/font_default_0066.png
new file mode 100644
index 0000000..a63276c
Binary files /dev/null and b/lcdlib/textures/font_default_0066.png differ
diff --git a/lcdlib/textures/font_default_0067.png b/lcdlib/textures/font_default_0067.png
new file mode 100644
index 0000000..baf3e88
Binary files /dev/null and b/lcdlib/textures/font_default_0067.png differ
diff --git a/lcdlib/textures/font_default_0068.png b/lcdlib/textures/font_default_0068.png
new file mode 100644
index 0000000..1c9e9b4
Binary files /dev/null and b/lcdlib/textures/font_default_0068.png differ
diff --git a/lcdlib/textures/font_default_0069.png b/lcdlib/textures/font_default_0069.png
new file mode 100644
index 0000000..785cdb5
Binary files /dev/null and b/lcdlib/textures/font_default_0069.png differ
diff --git a/lcdlib/textures/font_default_006a.png b/lcdlib/textures/font_default_006a.png
new file mode 100644
index 0000000..a7abd8e
Binary files /dev/null and b/lcdlib/textures/font_default_006a.png differ
diff --git a/lcdlib/textures/font_default_006b.png b/lcdlib/textures/font_default_006b.png
new file mode 100644
index 0000000..ff5f32a
Binary files /dev/null and b/lcdlib/textures/font_default_006b.png differ
diff --git a/lcdlib/textures/font_default_006c.png b/lcdlib/textures/font_default_006c.png
new file mode 100644
index 0000000..53ef0bc
Binary files /dev/null and b/lcdlib/textures/font_default_006c.png differ
diff --git a/lcdlib/textures/font_default_006d.png b/lcdlib/textures/font_default_006d.png
new file mode 100644
index 0000000..351aeef
Binary files /dev/null and b/lcdlib/textures/font_default_006d.png differ
diff --git a/lcdlib/textures/font_default_006e.png b/lcdlib/textures/font_default_006e.png
new file mode 100644
index 0000000..60e089d
Binary files /dev/null and b/lcdlib/textures/font_default_006e.png differ
diff --git a/lcdlib/textures/font_default_006f.png b/lcdlib/textures/font_default_006f.png
new file mode 100644
index 0000000..dd48b6c
Binary files /dev/null and b/lcdlib/textures/font_default_006f.png differ
diff --git a/lcdlib/textures/font_default_0070.png b/lcdlib/textures/font_default_0070.png
new file mode 100644
index 0000000..0fdb26f
Binary files /dev/null and b/lcdlib/textures/font_default_0070.png differ
diff --git a/lcdlib/textures/font_default_0071.png b/lcdlib/textures/font_default_0071.png
new file mode 100644
index 0000000..787418e
Binary files /dev/null and b/lcdlib/textures/font_default_0071.png differ
diff --git a/lcdlib/textures/font_default_0072.png b/lcdlib/textures/font_default_0072.png
new file mode 100644
index 0000000..7d2bf4c
Binary files /dev/null and b/lcdlib/textures/font_default_0072.png differ
diff --git a/lcdlib/textures/font_default_0073.png b/lcdlib/textures/font_default_0073.png
new file mode 100644
index 0000000..b2b2ed2
Binary files /dev/null and b/lcdlib/textures/font_default_0073.png differ
diff --git a/lcdlib/textures/font_default_0074.png b/lcdlib/textures/font_default_0074.png
new file mode 100644
index 0000000..dcdbd37
Binary files /dev/null and b/lcdlib/textures/font_default_0074.png differ
diff --git a/lcdlib/textures/font_default_0075.png b/lcdlib/textures/font_default_0075.png
new file mode 100644
index 0000000..5ef59c7
Binary files /dev/null and b/lcdlib/textures/font_default_0075.png differ
diff --git a/lcdlib/textures/font_default_0076.png b/lcdlib/textures/font_default_0076.png
new file mode 100644
index 0000000..710703f
Binary files /dev/null and b/lcdlib/textures/font_default_0076.png differ
diff --git a/lcdlib/textures/font_default_0077.png b/lcdlib/textures/font_default_0077.png
new file mode 100644
index 0000000..373ecb0
Binary files /dev/null and b/lcdlib/textures/font_default_0077.png differ
diff --git a/lcdlib/textures/font_default_0078.png b/lcdlib/textures/font_default_0078.png
new file mode 100644
index 0000000..23541ff
Binary files /dev/null and b/lcdlib/textures/font_default_0078.png differ
diff --git a/lcdlib/textures/font_default_0079.png b/lcdlib/textures/font_default_0079.png
new file mode 100644
index 0000000..e3fddb2
Binary files /dev/null and b/lcdlib/textures/font_default_0079.png differ
diff --git a/lcdlib/textures/font_default_007a.png b/lcdlib/textures/font_default_007a.png
new file mode 100644
index 0000000..2a92823
Binary files /dev/null and b/lcdlib/textures/font_default_007a.png differ
diff --git a/lcdlib/textures/font_default_007b.png b/lcdlib/textures/font_default_007b.png
new file mode 100644
index 0000000..7606697
Binary files /dev/null and b/lcdlib/textures/font_default_007b.png differ
diff --git a/lcdlib/textures/font_default_007c.png b/lcdlib/textures/font_default_007c.png
new file mode 100644
index 0000000..777f1e4
Binary files /dev/null and b/lcdlib/textures/font_default_007c.png differ
diff --git a/lcdlib/textures/font_default_007d.png b/lcdlib/textures/font_default_007d.png
new file mode 100644
index 0000000..b9ee397
Binary files /dev/null and b/lcdlib/textures/font_default_007d.png differ
diff --git a/lcdlib/textures/font_default_007e.png b/lcdlib/textures/font_default_007e.png
new file mode 100644
index 0000000..759b56e
Binary files /dev/null and b/lcdlib/textures/font_default_007e.png differ
diff --git a/lcdlib/textures/font_default_008a.png b/lcdlib/textures/font_default_008a.png
new file mode 100644
index 0000000..e4f3236
Binary files /dev/null and b/lcdlib/textures/font_default_008a.png differ
diff --git a/lcdlib/textures/font_default_008d.png b/lcdlib/textures/font_default_008d.png
new file mode 100644
index 0000000..fcc3b38
Binary files /dev/null and b/lcdlib/textures/font_default_008d.png differ
diff --git a/lcdlib/textures/font_default_00a1.png b/lcdlib/textures/font_default_00a1.png
new file mode 100644
index 0000000..df91ae3
Binary files /dev/null and b/lcdlib/textures/font_default_00a1.png differ
diff --git a/lcdlib/textures/font_default_00b1.png b/lcdlib/textures/font_default_00b1.png
new file mode 100644
index 0000000..2413844
Binary files /dev/null and b/lcdlib/textures/font_default_00b1.png differ
diff --git a/lcdlib/textures/font_default_00bf.png b/lcdlib/textures/font_default_00bf.png
new file mode 100644
index 0000000..fec3deb
Binary files /dev/null and b/lcdlib/textures/font_default_00bf.png differ
diff --git a/lcdlib/textures/font_default_00c0.png b/lcdlib/textures/font_default_00c0.png
new file mode 100644
index 0000000..4652acf
Binary files /dev/null and b/lcdlib/textures/font_default_00c0.png differ
diff --git a/lcdlib/textures/font_default_00c1.png b/lcdlib/textures/font_default_00c1.png
new file mode 100644
index 0000000..f2d7464
Binary files /dev/null and b/lcdlib/textures/font_default_00c1.png differ
diff --git a/lcdlib/textures/font_default_00c2.png b/lcdlib/textures/font_default_00c2.png
new file mode 100644
index 0000000..c759ac9
Binary files /dev/null and b/lcdlib/textures/font_default_00c2.png differ
diff --git a/lcdlib/textures/font_default_00c3.png b/lcdlib/textures/font_default_00c3.png
new file mode 100644
index 0000000..6239ee6
Binary files /dev/null and b/lcdlib/textures/font_default_00c3.png differ
diff --git a/lcdlib/textures/font_default_00c4.png b/lcdlib/textures/font_default_00c4.png
new file mode 100644
index 0000000..1178423
Binary files /dev/null and b/lcdlib/textures/font_default_00c4.png differ
diff --git a/lcdlib/textures/font_default_00c5.png b/lcdlib/textures/font_default_00c5.png
new file mode 100644
index 0000000..64e5efc
Binary files /dev/null and b/lcdlib/textures/font_default_00c5.png differ
diff --git a/lcdlib/textures/font_default_00c6.png b/lcdlib/textures/font_default_00c6.png
new file mode 100644
index 0000000..7eaf588
Binary files /dev/null and b/lcdlib/textures/font_default_00c6.png differ
diff --git a/lcdlib/textures/font_default_00c7.png b/lcdlib/textures/font_default_00c7.png
new file mode 100644
index 0000000..247fbc4
Binary files /dev/null and b/lcdlib/textures/font_default_00c7.png differ
diff --git a/lcdlib/textures/font_default_00c8.png b/lcdlib/textures/font_default_00c8.png
new file mode 100644
index 0000000..517b63d
Binary files /dev/null and b/lcdlib/textures/font_default_00c8.png differ
diff --git a/lcdlib/textures/font_default_00c9.png b/lcdlib/textures/font_default_00c9.png
new file mode 100644
index 0000000..cd4f8d8
Binary files /dev/null and b/lcdlib/textures/font_default_00c9.png differ
diff --git a/lcdlib/textures/font_default_00ca.png b/lcdlib/textures/font_default_00ca.png
new file mode 100644
index 0000000..39aa1aa
Binary files /dev/null and b/lcdlib/textures/font_default_00ca.png differ
diff --git a/lcdlib/textures/font_default_00cb.png b/lcdlib/textures/font_default_00cb.png
new file mode 100644
index 0000000..7058b5a
Binary files /dev/null and b/lcdlib/textures/font_default_00cb.png differ
diff --git a/lcdlib/textures/font_default_00cc.png b/lcdlib/textures/font_default_00cc.png
new file mode 100644
index 0000000..a382d73
Binary files /dev/null and b/lcdlib/textures/font_default_00cc.png differ
diff --git a/lcdlib/textures/font_default_00cd.png b/lcdlib/textures/font_default_00cd.png
new file mode 100644
index 0000000..86339a1
Binary files /dev/null and b/lcdlib/textures/font_default_00cd.png differ
diff --git a/lcdlib/textures/font_default_00ce.png b/lcdlib/textures/font_default_00ce.png
new file mode 100644
index 0000000..78583df
Binary files /dev/null and b/lcdlib/textures/font_default_00ce.png differ
diff --git a/lcdlib/textures/font_default_00cf.png b/lcdlib/textures/font_default_00cf.png
new file mode 100644
index 0000000..b680e2e
Binary files /dev/null and b/lcdlib/textures/font_default_00cf.png differ
diff --git a/lcdlib/textures/font_default_00d0.png b/lcdlib/textures/font_default_00d0.png
new file mode 100644
index 0000000..50db9f9
Binary files /dev/null and b/lcdlib/textures/font_default_00d0.png differ
diff --git a/lcdlib/textures/font_default_00d1.png b/lcdlib/textures/font_default_00d1.png
new file mode 100644
index 0000000..912524f
Binary files /dev/null and b/lcdlib/textures/font_default_00d1.png differ
diff --git a/lcdlib/textures/font_default_00d2.png b/lcdlib/textures/font_default_00d2.png
new file mode 100644
index 0000000..d7e635f
Binary files /dev/null and b/lcdlib/textures/font_default_00d2.png differ
diff --git a/lcdlib/textures/font_default_00d3.png b/lcdlib/textures/font_default_00d3.png
new file mode 100644
index 0000000..27ae016
Binary files /dev/null and b/lcdlib/textures/font_default_00d3.png differ
diff --git a/lcdlib/textures/font_default_00d4.png b/lcdlib/textures/font_default_00d4.png
new file mode 100644
index 0000000..a62a3ed
Binary files /dev/null and b/lcdlib/textures/font_default_00d4.png differ
diff --git a/lcdlib/textures/font_default_00d5.png b/lcdlib/textures/font_default_00d5.png
new file mode 100644
index 0000000..3740df7
Binary files /dev/null and b/lcdlib/textures/font_default_00d5.png differ
diff --git a/lcdlib/textures/font_default_00d6.png b/lcdlib/textures/font_default_00d6.png
new file mode 100644
index 0000000..9b3cd62
Binary files /dev/null and b/lcdlib/textures/font_default_00d6.png differ
diff --git a/lcdlib/textures/font_default_00d7.png b/lcdlib/textures/font_default_00d7.png
new file mode 100644
index 0000000..a92ac66
Binary files /dev/null and b/lcdlib/textures/font_default_00d7.png differ
diff --git a/lcdlib/textures/font_default_00d8.png b/lcdlib/textures/font_default_00d8.png
new file mode 100644
index 0000000..0453191
Binary files /dev/null and b/lcdlib/textures/font_default_00d8.png differ
diff --git a/lcdlib/textures/font_default_00d9.png b/lcdlib/textures/font_default_00d9.png
new file mode 100644
index 0000000..607ac14
Binary files /dev/null and b/lcdlib/textures/font_default_00d9.png differ
diff --git a/lcdlib/textures/font_default_00da.png b/lcdlib/textures/font_default_00da.png
new file mode 100644
index 0000000..91e5781
Binary files /dev/null and b/lcdlib/textures/font_default_00da.png differ
diff --git a/lcdlib/textures/font_default_00db.png b/lcdlib/textures/font_default_00db.png
new file mode 100644
index 0000000..f63177d
Binary files /dev/null and b/lcdlib/textures/font_default_00db.png differ
diff --git a/lcdlib/textures/font_default_00dc.png b/lcdlib/textures/font_default_00dc.png
new file mode 100644
index 0000000..eeaa7c6
Binary files /dev/null and b/lcdlib/textures/font_default_00dc.png differ
diff --git a/lcdlib/textures/font_default_00dd.png b/lcdlib/textures/font_default_00dd.png
new file mode 100644
index 0000000..f194136
Binary files /dev/null and b/lcdlib/textures/font_default_00dd.png differ
diff --git a/lcdlib/textures/font_default_00e0.png b/lcdlib/textures/font_default_00e0.png
new file mode 100644
index 0000000..b9779fe
Binary files /dev/null and b/lcdlib/textures/font_default_00e0.png differ
diff --git a/lcdlib/textures/font_default_00e1.png b/lcdlib/textures/font_default_00e1.png
new file mode 100644
index 0000000..aeaeaf5
Binary files /dev/null and b/lcdlib/textures/font_default_00e1.png differ
diff --git a/lcdlib/textures/font_default_00e2.png b/lcdlib/textures/font_default_00e2.png
new file mode 100644
index 0000000..8ca07ed
Binary files /dev/null and b/lcdlib/textures/font_default_00e2.png differ
diff --git a/lcdlib/textures/font_default_00e3.png b/lcdlib/textures/font_default_00e3.png
new file mode 100644
index 0000000..e2f00bb
Binary files /dev/null and b/lcdlib/textures/font_default_00e3.png differ
diff --git a/lcdlib/textures/font_default_00e4.png b/lcdlib/textures/font_default_00e4.png
new file mode 100644
index 0000000..6bcf6fb
Binary files /dev/null and b/lcdlib/textures/font_default_00e4.png differ
diff --git a/lcdlib/textures/font_default_00e5.png b/lcdlib/textures/font_default_00e5.png
new file mode 100644
index 0000000..698094e
Binary files /dev/null and b/lcdlib/textures/font_default_00e5.png differ
diff --git a/lcdlib/textures/font_default_00e6.png b/lcdlib/textures/font_default_00e6.png
new file mode 100644
index 0000000..70ac70a
Binary files /dev/null and b/lcdlib/textures/font_default_00e6.png differ
diff --git a/lcdlib/textures/font_default_00e7.png b/lcdlib/textures/font_default_00e7.png
new file mode 100644
index 0000000..f0462bd
Binary files /dev/null and b/lcdlib/textures/font_default_00e7.png differ
diff --git a/lcdlib/textures/font_default_00e8.png b/lcdlib/textures/font_default_00e8.png
new file mode 100644
index 0000000..841363e
Binary files /dev/null and b/lcdlib/textures/font_default_00e8.png differ
diff --git a/lcdlib/textures/font_default_00e9.png b/lcdlib/textures/font_default_00e9.png
new file mode 100644
index 0000000..7752df4
Binary files /dev/null and b/lcdlib/textures/font_default_00e9.png differ
diff --git a/lcdlib/textures/font_default_00ea.png b/lcdlib/textures/font_default_00ea.png
new file mode 100644
index 0000000..b549be6
Binary files /dev/null and b/lcdlib/textures/font_default_00ea.png differ
diff --git a/lcdlib/textures/font_default_00eb.png b/lcdlib/textures/font_default_00eb.png
new file mode 100644
index 0000000..f9c4dbc
Binary files /dev/null and b/lcdlib/textures/font_default_00eb.png differ
diff --git a/lcdlib/textures/font_default_00ec.png b/lcdlib/textures/font_default_00ec.png
new file mode 100644
index 0000000..e86f3a7
Binary files /dev/null and b/lcdlib/textures/font_default_00ec.png differ
diff --git a/lcdlib/textures/font_default_00ed.png b/lcdlib/textures/font_default_00ed.png
new file mode 100644
index 0000000..94f12e8
Binary files /dev/null and b/lcdlib/textures/font_default_00ed.png differ
diff --git a/lcdlib/textures/font_default_00ee.png b/lcdlib/textures/font_default_00ee.png
new file mode 100644
index 0000000..e8a743d
Binary files /dev/null and b/lcdlib/textures/font_default_00ee.png differ
diff --git a/lcdlib/textures/font_default_00ef.png b/lcdlib/textures/font_default_00ef.png
new file mode 100644
index 0000000..d2c744f
Binary files /dev/null and b/lcdlib/textures/font_default_00ef.png differ
diff --git a/lcdlib/textures/font_default_00f2.png b/lcdlib/textures/font_default_00f2.png
new file mode 100644
index 0000000..f7d1127
Binary files /dev/null and b/lcdlib/textures/font_default_00f2.png differ
diff --git a/lcdlib/textures/font_default_00f4.png b/lcdlib/textures/font_default_00f4.png
new file mode 100644
index 0000000..4b0cce6
Binary files /dev/null and b/lcdlib/textures/font_default_00f4.png differ
diff --git a/lcdlib/textures/font_default_00f5.png b/lcdlib/textures/font_default_00f5.png
new file mode 100644
index 0000000..ec7cec1
Binary files /dev/null and b/lcdlib/textures/font_default_00f5.png differ
diff --git a/lcdlib/textures/font_default_00f6.png b/lcdlib/textures/font_default_00f6.png
new file mode 100644
index 0000000..7213c8a
Binary files /dev/null and b/lcdlib/textures/font_default_00f6.png differ
diff --git a/lcdlib/textures/font_default_00f7.png b/lcdlib/textures/font_default_00f7.png
new file mode 100644
index 0000000..408687d
Binary files /dev/null and b/lcdlib/textures/font_default_00f7.png differ
diff --git a/lcdlib/textures/font_default_00f9.png b/lcdlib/textures/font_default_00f9.png
new file mode 100644
index 0000000..67d16b5
Binary files /dev/null and b/lcdlib/textures/font_default_00f9.png differ
diff --git a/lcdlib/textures/font_default_00fa.png b/lcdlib/textures/font_default_00fa.png
new file mode 100644
index 0000000..97de7e1
Binary files /dev/null and b/lcdlib/textures/font_default_00fa.png differ
diff --git a/lcdlib/textures/font_default_00fb.png b/lcdlib/textures/font_default_00fb.png
new file mode 100644
index 0000000..2861e15
Binary files /dev/null and b/lcdlib/textures/font_default_00fb.png differ
diff --git a/lcdlib/textures/font_default_00fc.png b/lcdlib/textures/font_default_00fc.png
new file mode 100644
index 0000000..c7deddd
Binary files /dev/null and b/lcdlib/textures/font_default_00fc.png differ
diff --git a/lcdlib/textures/font_default_00fd.png b/lcdlib/textures/font_default_00fd.png
new file mode 100644
index 0000000..b6f45f9
Binary files /dev/null and b/lcdlib/textures/font_default_00fd.png differ
diff --git a/lcdlib/textures/font_default_00ff.png b/lcdlib/textures/font_default_00ff.png
new file mode 100644
index 0000000..d182a29
Binary files /dev/null and b/lcdlib/textures/font_default_00ff.png differ