How to Create Subset Fonts in .NET?

后端 未结 5 633
天命终不由人
天命终不由人 2021-01-05 04:35

I have a Silverlight application that I need to embed some less-than-common fonts in. It\'s simple enough for me to just copy over the TTF/OTF and compile that with my app.

5条回答
  •  一生所求
    2021-01-05 05:10

    The native API CreateFontPackage may be what you're looking for. You can pass a TTF and a list of characters to keep. If you pass TTFCFP_SUBSET for usSubsetFormat, you'll then get back a working TTF with only those characters.

    Here's a thread with what appears to be code of a working example (in C, unfortunately).

提交回复
热议问题