YesNoOk
avatar

TrueType Fonts (Fonts) (Read 4885 times)

Started by JustNoPoint, October 29, 2015, 02:08:03 am
Share this topic:
TrueType Fonts (Fonts)
New #1  October 29, 2015, 02:08:03 am
  • ******
    • www.justnopoint.com/
An example TrueType font definition file, with inline comments, is shown below:

Code:
[FNT v2]
; FNT v2 version number.  Don't change this.
fntversion = 2,00
; Name of this font.
name = "Arial"
; Font author
author = "Microsoft"

[Def]
; This is a truetype font.
Type = truetype
; Size of font: width, height.  Only height is used for truetype fonts.
Size = 18,36
; Spacing between font glyphs.  Only height is used for truetype fonts.
Spacing = 1,1
; Drawing offset: x, y.
Offset = 0,0
; Filename of the font to load.  Will search Windows font directory if not in current directory.
File = arial.ttf
; Preferred blending mode: 0 - none, 1 - blended.
Blend = 1

; Note: All units are in pixels.
; Text rendered with truetype fonts may be ASCII or UTF-8
TrueType font definitions must be accompanied by a TrueType font file, which typically has an extension of .ttf or .ttc. If the TrueType font file is located in the same directory as the definition file, it will be loaded. Otherwise, M.U.G.E.N will attempt to load the font file from the Windows font directory.

Bumping this thread just to add mugen also supports .otf (OpenType) fonts, even though this isn't documented on any official file.
Last Edit: February 12, 2017, 05:16:15 am by Just No Point