简体   繁体   English

在应用程序运行时下载并安装iphone中的字体

[英]to download and install font in iphone while application running

I have links to fonts from where I can download fontName.ttf. 我有字体的链接,我可以从中下载fontName.ttf。 Now When user selects a particular font I want to download that and install and use it for label. 现在,当用户选择我要下载的特定字体并安装并将其用于标签时。 Can I add row in Plist Fonts provided by application programatically? 我可以以编程方式在应用程序提供的Plist字体中添加行吗? And where should I save the fontName.ttf so application will use it. 我应该在哪里保存fontName.ttf,以便应用程序使用它。

Settings bundle resides inside your app's bundle, thus - you cannot change it at runtime, only at compile-time. 设置包位于应用程序包的内部,因此 - 您无法在运行时更改它,仅在编译时。 So it is not possible. 所以这是不可能的。

You could check out different solutions: 您可以查看不同的解决方案:

Core Text fonts: Dynamic custom fonts loader in iOS 核心文本字体: iOS中的动态自定义字体加载器

NSUserDefaults: Can i modify Root.plist in settings bundle dynamically? NSUserDefaults: 我可以动态修改设置包中的Root.plist吗?

不可能你不能在运行时添加和删除bundle中的任何东西。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM