![]() |
![]() |
![]() |
![]() |
Generate a font name
uchar_t * PfGenerateFontName( uchar_t const * pkucDescription, uint32_t const kuiFlags, uint32_t const kuiSize, uchar_t * pucBuff );
ph
PfGenerateFontName() is a convenience function that generates a proper font name from the arguments given:
NULL on failure, pucBuff on success.
char szHelvetica12[MAX_FONT_TAG]; if(PfGenerateFontName("Helvetica", PF_STYLE_BOLD, 12, szHelvetica12) == NULL) { perror("Unable to find font"); } else { PfExtentText(&tsExtent, NULL, szHelvetica12, "Hello", 0); }
The szHelvetica12 variable can now be used with any function that takes a "font" pointer, such as PfExtentText(), PfGlyph(), or PfRenderText().
Photon
Safety: | |
---|---|
Interrupt handler | No |
Signal handler | No |
Thread | No |
PfQueryFontInfo(), PfQueryFonts()
Fonts chapter of the Photon Programmer's Guide
![]() |
![]() |
![]() |
![]() |