Skinning How To/Add custom fonts to the viewer

From Second Life Wiki
Jump to navigation Jump to search

Introduction

There are three font styles you can add to your skin:

  • FontSansSerif (Regular text)
  • FontSansSerifBold (Bold text)
  • FontMonospace (Script Editor text)

These fonts are currently set in settings.xml (the file that holds all the viewer settings). Settings.xml should be included in skins. However, the default fonts for these are also included in the viewer in the SecondLifeReleaseCandidate\fonts\ folder, so can using file replace custom fonts can be used.

Replacing the viewer fonts with your own

WARNING: Be SURE you have distribution and modify rights to the fonts you use. You cannot alter or distribute proprietary fonts.

In the SecondLifeReleaseCandidate\fonts\ folder, you'll see the following font files:

  • MtBkLfRg.ttf (Sans serif font)
  • MtBdLfRg.ttf (Sans serif bold font)
  • profontwindows.ttf (Monospace font)

These are the default fonts the viewer uses (i.e. the default ones set in settings.xml).

To replace them:

  1. Download a free or open source font (.ttf file), or create your own. The font can be serif if you'd like.
  2. Delete or rename the pre-installed viewer fonts.
  3. Rename your font to the same name as the viewer fonts you want to replace.
  4. Run Second Life.

Note that some fonts will not work well with the viewer. This is very much a try-as-you go process.