mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-27 17:28:41 +00:00
Fix some minor code issues all over the place
This commit is contained in:
parent
289425f6bd
commit
74762470b2
19 changed files with 45 additions and 109 deletions
|
@ -356,7 +356,7 @@ namespace gui
|
|||
load_flags = FT_LOAD_DEFAULT | FT_LOAD_RENDER;
|
||||
if (!useHinting()) load_flags |= FT_LOAD_NO_HINTING;
|
||||
if (!useAutoHinting()) load_flags |= FT_LOAD_NO_AUTOHINT;
|
||||
if (useMonochrome()) load_flags |= FT_LOAD_MONOCHROME | FT_LOAD_TARGET_MONO | FT_RENDER_MODE_MONO;
|
||||
if (useMonochrome()) load_flags |= FT_LOAD_MONOCHROME | FT_LOAD_TARGET_MONO;
|
||||
else load_flags |= FT_LOAD_TARGET_NORMAL;
|
||||
}
|
||||
u32 getWidthFromCharacter(wchar_t c) const;
|
||||
|
|
|
@ -1331,7 +1331,7 @@ public:
|
|||
{
|
||||
u32 i;
|
||||
const uchar16_t* oa = other.c_str();
|
||||
for(i=0; array[i] && oa[i] && i < n; ++i)
|
||||
for(i=0; i < n && array[i] && oa[i]; ++i)
|
||||
if (array[i] != oa[i])
|
||||
return false;
|
||||
|
||||
|
@ -1350,7 +1350,7 @@ public:
|
|||
if (!str)
|
||||
return false;
|
||||
u32 i;
|
||||
for(i=0; array[i] && str[i] && i < n; ++i)
|
||||
for(i=0; i < n && array[i] && str[i]; ++i)
|
||||
if (array[i] != str[i])
|
||||
return false;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue