【发布时间】:2013-11-07 15:35:09
【问题描述】:
我正在使用 Corona SDK 进行游戏开发。我需要为我的应用程序使用“comic sans font”。 我正在使用这样的字体。
GAME_FONT = "ComicSansMS"
local txtTitle = display.newText("My Text", 0, 0, GAME_FONT, 30)
这在模拟器中运行良好,但在真正的 iPhone 设备上却不行。我也试过下载这个字体并添加到项目中,然后更新build.settings文件。
settings = {
orientation = {
default = "landscapeRight",
supported = { "landscapeRight", }
},
iphone = {
plist = {
UIAppFonts = { "comic.ttf"},
UIStatusBarHidden = true,
UIPrerenderedIcon = true, -- set to false for "shine" overlay
UIApplicationExitsOnSuspend = true, -- uncomment to quit app on suspend
}
},
}
但它仍然无法在真正的 iPhone 设备上运行。
我还通过以下代码确定“ComicSansMS”是否内置。
local fonts = native.getFontNames()
for i,fontname in ipairs(fonts) do
print(fontname)
end
我可以在列表中看到“ComicSansMS”。 任何建议将不胜感激。
【问题讨论】:
标签: fonts coronasdk game-physics