Difference between revisions of "love.graphics.newFont"

(Added variant)
(Linkified + added See Also)
Line 1: Line 1:
Creates a new Font.
+
Creates a new [[Font]].
 
== Function ==
 
== Function ==
 
=== Synopsis ===
 
=== Synopsis ===
Line 23: Line 23:
 
== See Also ==
 
== See Also ==
 
* [[parent::love.graphics]]
 
* [[parent::love.graphics]]
 +
* [[love.graphics.setFont]]
 
[[Category:Functions]]
 
[[Category:Functions]]
 
{{#set:Description=Creates a new Font.}}
 
{{#set:Description=Creates a new Font.}}

Revision as of 12:20, 18 April 2010

Creates a new Font.

Function

Synopsis

font = love.graphics.newFont( filename, size )

Arguments

string filename
The filepath to the font file.
number size (12)
The size of the font.

Returns

Font font
A Font object which can be used to draw text on screen.

Function

This variant uses the default font (Vera Sans) with a custom size.

Synopsis

font = love.graphics.newFont( size )

Arguments

number size (12)
The size of the font.

Returns

Font font
A Font object which can be used to draw text on screen.

See Also