如何使用外部字体? [英] How to use external fonts?

查看:151
本文介绍了如何使用外部字体?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我可以直接从Delphi中的资源使用一个字体,但是第一步我有一个问题。例如我不能包括Segoe UI Light字体在项目的资源中,发生异常。只有文件的扩展名是'ttf'。



如果上面写的不可能,那么我如何使用外部字体而不分开部署字体(从可执行文件)?



提前感谢

解决方案

在Windows 2000及更高版本中,您可以使用 AddFontMemResourceEx 从内存中为进程安装字体。


Is it possible to use a font directly from resources in Delphi and how?

I have a problem with the very first steps.Example I cannot include Segoe UI Light font in resources of a project,an exception occurs.And that is only if the file's extension is 'ttf'.

If the written above is not possible then how do I use an external font without deploying the font separately(from executable)?

Thanks in advance!

解决方案

On Windows 2000 and later, you can use AddFontMemResourceEx to install fonts for your process from memory.

这篇关于如何使用外部字体?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆