Skip to content

Instantly share code, notes, and snippets.

@zauguin
Created September 25, 2018 22:14
Show Gist options
  • Save zauguin/925c12e156f2ab94f6660464e8efcb87 to your computer and use it in GitHub Desktop.
Save zauguin/925c12e156f2ab94f6660464e8efcb87 to your computer and use it in GitHub Desktop.
font.each working with luaotfload
local function fonteach_next(max, f)
repeat
f = f + 1
if f > max then return end
until font.frozen(f) ~= nil
return f, font.getfont(f) or font.fonts[f]
end
font.each = function() return fonteach_next, font.max(), 0 end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment