src_c/_freetype.c¶
This extension module defines Python type pygame.freetype.Font
Create a new Font instance from a supported font file..
Header file: src_c/include/pygame_freetype.h
-
type
pgFontObject
¶ The
pygame.freetype.Font
instance C struct.
-
type
pgFont_Type
¶ The
pygame.freetype.Font
Python type.
-
PyObject *
pgFont_New
(const char *filename, long font_index)¶ Open the font file with path filename and return a new new
pygame.freetype.Font
instance for that font. Set font_index to0
unless the file contains multiple, indexed, fonts. On error raise a Python exception and returnNULL
.
-
int
pgFont_Check
(PyObject *x)¶ Return true if x is a
pygame.freetype.Font
instance. Will return false for a subclass ofFont
. This is a macro. No check is made that x is notNULL
.
-
int
pgFont_IS_ALIVE
(PyObject *o)¶ Return true if
pygame.freetype.Font
objecto
is an open font file. This is a macro. No check is made that o is notNULL
or not aFont
instance.
Edit on GitHub