mirror of
https://github.com/pyrollo/display_modpack.git
synced 2025-07-06 01:50:39 +02:00
Rename get_glyph to getglyph
This is for naming consistency among other font def params like `linespacing`, `margintop` etc.
This commit is contained in:
@ -258,10 +258,10 @@ function Font:render(text, texturew, textureh, style)
|
||||
|
||||
-- Add image only if it is visible (at least partly)
|
||||
if x + self.widths[codepoint] >= 0 and x <= texturew then
|
||||
if self.get_glyph == nil then
|
||||
if self.getglyph == nil then
|
||||
glyph = string.format("font_%s_%04x.png", self.name, codepoint)
|
||||
else
|
||||
glyph = self.get_glyph(codepoint):gsub("[\\^:]", "\\%0")
|
||||
glyph = self.getglyph(codepoint):gsub("[\\^:]", "\\%0")
|
||||
end
|
||||
texture = texture..
|
||||
string.format(":%d,%d=%s", x, y, glyph)
|
||||
|
Reference in New Issue
Block a user