mirror of
https://github.com/libSDL2pp/libSDL2pp.git
synced 2025-08-04 03:15:59 -04:00
We have bool type, use it for boolean value
This commit is contained in:
parent
c5554f5853
commit
c9d26eaa18
@ -84,11 +84,11 @@ void Font::SetHinting(int hinting) {
|
|||||||
TTF_SetFontHinting(font_, hinting);
|
TTF_SetFontHinting(font_, hinting);
|
||||||
}
|
}
|
||||||
|
|
||||||
int Font::GetKerning() const {
|
bool Font::GetKerning() const {
|
||||||
return TTF_GetFontKerning(font_);
|
return TTF_GetFontKerning(font_);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Font::SetKerning(int allowed) {
|
void Font::SetKerning(bool allowed) {
|
||||||
TTF_SetFontKerning(font_, allowed);
|
TTF_SetFontKerning(font_, allowed);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -223,20 +223,19 @@ public:
|
|||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
/// \brief Get the current kerning setting of the loaded font
|
/// \brief Get the current kerning setting of the loaded font
|
||||||
///
|
///
|
||||||
/// \returns 0 (zero) if kerning is disabled. A non-zero value
|
/// \returns False if kerning is disabled. True when disabled.
|
||||||
/// is returned when enabled. The default for a newly
|
/// The default for a newly loaded font is true, enabled
|
||||||
/// loaded font is enabled (1)
|
|
||||||
///
|
///
|
||||||
/// \see https://www.libsdl.org/projects/SDL_ttf/docs/SDL_ttf.html#SEC27
|
/// \see https://www.libsdl.org/projects/SDL_ttf/docs/SDL_ttf.html#SEC27
|
||||||
///
|
///
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
int GetKerning() const;
|
bool GetKerning() const;
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
/// \brief Set whther to use kerning when rendering the loaded font
|
/// \brief Set whther to use kerning when rendering the loaded font
|
||||||
///
|
///
|
||||||
/// \param allowed 0 to diable kerning, non-zero to enable kerning.
|
/// \param allowed False to diable kerning, true to enable kerning.
|
||||||
/// The default is 1, enabled
|
/// The default is true, enabled
|
||||||
///
|
///
|
||||||
/// Set whether to use kerning when rendering the loaded font.
|
/// Set whether to use kerning when rendering the loaded font.
|
||||||
/// This has no effect on individual glyphs, but rather when
|
/// This has no effect on individual glyphs, but rather when
|
||||||
@ -248,7 +247,7 @@ public:
|
|||||||
/// \see https://www.libsdl.org/projects/SDL_ttf/docs/SDL_ttf.html#SEC28
|
/// \see https://www.libsdl.org/projects/SDL_ttf/docs/SDL_ttf.html#SEC28
|
||||||
///
|
///
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
void SetKerning(int allowed);
|
void SetKerning(bool allowed);
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
/// \brief Get the maximum pixel height of all glyphs of the loaded font
|
/// \brief Get the maximum pixel height of all glyphs of the loaded font
|
||||||
|
Loading…
x
Reference in New Issue
Block a user