質問

XNAでカスタムフォントを使用する方法はありますか?

役に立ちましたか?

解決

確実に、フォントをシステムにインポートする必要があります。フォントをフォントシステムカタログに追加するか、コントロールパネルを介して追加します。準備ができたら(Reboot Visual Studio)XMLファイルを生成するVisual StudioのSpritefontのカスタムテンプレートを使用します。EXMALE:

<?xml version="1.0" encoding="utf-8"?>
<!--
This file contains an xml description of a font, and will be read by the XNA
Framework Content Pipeline. Follow the comments to customize the appearance
of the font in your game, and to change the characters which are available to draw
with.
-->
<XnaContent xmlns:Graphics="Microsoft.Xna.Framework.Content.Pipeline.Graphics">
  <Asset Type="Graphics:FontDescription">

    <!--
    Modify this string to change the font that will be imported.
    -->
    <FontName>Moire</FontName>
...
.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top