How to make fonts work properly?

I’ve read through this twice:
http://maurits.tv/data/garrysmod/wiki/wiki.garrysmod.com/index5b6d.html

I’m installing the font at this location:
resource/fonts/spraypaint.ttf

This is my code:
[lua]
surface.CreateFont (“spraypaint”, 30, 400, true, false, “PressUse”)
hook.Add(“HUDPaint”, “FindModelPaths”, function()
draw.DrawText(“Test[a]”, “PressUse”, (ScrW()/2)-1, (ScrH()-100)+1, Color(150,150,0,255), TEXT_ALIGN_CENTER)
end)
[/lua]

The text shows up as some default text from I don’t know where.

How do I make the font work properly? I’ve tried other fonts in that resource folder and they work fine also. I don’t have to install the font to my windows fonts do I?

Make sure the name of the font you’re trying to use is the TrueType font name, not the file name.

What do you mean by that? Something inside Properties?

If I open up the font it has this:
Font name: Spraypaint Free
Version: Version 1.000
TrueType Outlines

ABCDE etc.

You need to use this:

[lua]
surface.CreateFont (“Spraypaint Free”, 30, 400, true, false, “PressUse”)
[/lua]

instead of

[lua]
surface.CreateFont (“spraypaint”, 30, 400, true, false, “PressUse”)
[/lua]

Thanks that’s what I thought.