|
void | LoadFontDefault (void) |
|
void | UnloadFontDefault (void) |
|
Font | GetFontDefault () |
|
Font | LoadFont (const char *fileName) |
|
Font | LoadFontEx (const char *fileName, int fontSize, int *fontChars, int glyphCount) |
|
Font | LoadFontFromImage (Image image, Color key, int firstChar) |
|
Font | LoadFontFromMemory (const char *fileType, const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int glyphCount) |
|
GlyphInfo * | LoadFontData (const unsigned char *fileData, int dataSize, int fontSize, int *fontChars, int glyphCount, int type) |
|
Image | GenImageFontAtlas (const GlyphInfo *chars, Rectangle **charRecs, int glyphCount, int fontSize, int padding, int packMethod) |
|
void | UnloadFontData (GlyphInfo *glyphs, int glyphCount) |
|
void | UnloadFont (Font font) |
|
bool | ExportFontAsCode (Font font, const char *fileName) |
|
void | DrawFPS (int posX, int posY) |
|
void | DrawText (const char *text, int posX, int posY, int fontSize, Color color) |
|
void | DrawTextEx (Font font, const char *text, Vector2 position, float fontSize, float spacing, Color tint) |
|
void | DrawTextPro (Font font, const char *text, Vector2 position, Vector2 origin, float rotation, float fontSize, float spacing, Color tint) |
|
void | DrawTextCodepoint (Font font, int codepoint, Vector2 position, float fontSize, Color tint) |
|
void | DrawTextCodepoints (Font font, const int *codepoints, int count, Vector2 position, float fontSize, float spacing, Color tint) |
|
int | MeasureText (const char *text, int fontSize) |
|
Vector2 | MeasureTextEx (Font font, const char *text, float fontSize, float spacing) |
|
int | GetGlyphIndex (Font font, int codepoint) |
|
GlyphInfo | GetGlyphInfo (Font font, int codepoint) |
|
Rectangle | GetGlyphAtlasRec (Font font, int codepoint) |
|
unsigned int | TextLength (const char *text) |
|
const char * | TextFormat (const char *text,...) |
|
int | TextToInteger (const char *text) |
|
int | TextCopy (char *dst, const char *src) |
|
bool | TextIsEqual (const char *text1, const char *text2) |
|
const char * | TextSubtext (const char *text, int position, int length) |
|
char * | TextReplace (char *text, const char *replace, const char *by) |
|
char * | TextInsert (const char *text, const char *insert, int position) |
|
const char * | TextJoin (const char **textList, int count, const char *delimiter) |
|
const char ** | TextSplit (const char *text, char delimiter, int *count) |
|
void | TextAppend (char *text, const char *append, int *position) |
|
int | TextFindIndex (const char *text, const char *find) |
|
const char * | TextToUpper (const char *text) |
|
const char * | TextToLower (const char *text) |
|
const char * | TextToPascal (const char *text) |
|
char * | TextCodepointsToUTF8 (const int *codepoints, int length) |
|
RLAPI const char * | CodepointToUTF8 (int codepoint, int *byteSize) |
|
int * | LoadCodepoints (const char *text, int *count) |
|
void | UnloadCodepoints (int *codepoints) |
|
int | GetCodepointCount (const char *text) |
|
int | GetCodepoint (const char *text, int *bytesProcessed) |
|
#define STB_RECT_PACK_IMPLEMENTATION |
rtext - Basic functions to load fonts and draw text
CONFIGURATION:
#define SUPPORT_MODULE_RTEXT rtext module is included in the build
#define SUPPORT_FILEFORMAT_FNT #define SUPPORT_FILEFORMAT_TTF Selected desired fileformats to be supported for loading. Some of those formats are supported by default, to remove support, just comment unrequired #define in this module
#define SUPPORT_DEFAULT_FONT Load default raylib font on initialization to be used by DrawText() and MeasureText(). If no default font loaded, DrawTextEx() and MeasureTextEx() are required.
#define TEXTSPLIT_MAX_TEXT_BUFFER_LENGTH TextSplit() function static buffer max size
#define MAX_TEXTSPLIT_COUNT TextSplit() function static substrings pointers array (pointing to static buffer)
DEPENDENCIES: stb_truetype - Load TTF file and rasterize characters data stb_rect_pack - Rectangles packing algorythms, required for font atlas generation
LICENSE: zlib/libpng
Copyright (c) 2013-2022 Ramon Santamaria (@raysan5)
This software is provided "as-is", without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.
Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions:
- The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
- Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
- This notice may not be removed or altered from any source distribution.
Definition at line 71 of file rtext.c.