Hi, I’m trying to add a custom font to my app, and I keep getting a warning that says ‘Could not load font: “Segment14”. Using default font’.
In my main.lua I have the following code:
[code]local fonts = native.getFontNames()
fontname = “”
for i, v in ipairs (fonts) do
if string.find(v, “egment”, 1, true) then
fontname = v
end
end
print ("font = " … fontname)[/code]
This outputs: ‘font = Segment14’
However when I use the following code:
txtbox = display.newText( "default", 0, 0, fontname, 20 )
I get the warning described above.
Any help would be much appreciated. [import]uid: 35591 topic_id: 11507 reply_id: 311507[/import]