Fix Visual Studio compiler warnings

This commit is contained in:
Albrecht Schlosser 2022-11-11 19:27:00 +01:00
parent 578601f062
commit 8d636d931e
2 changed files with 3 additions and 3 deletions

View File

@ -223,11 +223,11 @@ Fl_GDI_Font_Descriptor::Fl_GDI_Font_Descriptor(const char* name, Fl_Fontsize fsi
case ' ': break;
default: name--;
}
int wn = fl_utf8toUtf16(name, strlen(name), wstr, wstr_len);
int wn = fl_utf8toUtf16(name, (unsigned int)strlen(name), wstr, wstr_len);
if (wn >= wstr_len) {
wstr = (unsigned short*) realloc(wstr, sizeof(unsigned short) * (wn + 1));
wstr_len = wn + 1;
wn = fl_utf8toUtf16(name, strlen(name), wstr, wstr_len);
wn = fl_utf8toUtf16(name, (unsigned int)strlen(name), wstr, wstr_len);
}
fid = CreateFontW(

View File

@ -577,7 +577,7 @@ int main(int argc, char** argv)
latin1, (unsigned int)strlen(latin1));
utf8[l] = '\0';
strcat(utf8, emoji);
l = strlen(utf8);
l = (int)strlen(utf8);
make_font_chooser();
extra_font = FL_TIMES_BOLD_ITALIC;