From 0fde05fa03e3ff051c90a93f2278a468f2615654 Mon Sep 17 00:00:00 2001 From: Nishi Date: Sun, 8 Mar 2026 07:06:12 +0900 Subject: [PATCH] fix some parts --- include/Mw/LowLevel.h | 8 ++++---- src/text/ft2.c | 2 +- src/text/stbtt.c | 3 +-- src/text/text.c | 4 ++-- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/include/Mw/LowLevel.h b/include/Mw/LowLevel.h index dcab28d..9766d05 100644 --- a/include/Mw/LowLevel.h +++ b/include/Mw/LowLevel.h @@ -235,14 +235,14 @@ MWDECL void (*MwLLGetClipboard)(MwLL handle); MWDECL void (*MwLLGetCursorCoord)(MwLL handle, MwPoint* point); MWDECL void (*MwLLGetScreenSize)(MwLL handle, MwRect* rect); -/*font renderer */ -MWDECL void MwFLSetup(); +/* font renderer */ +MWDECL void MwFLSetup(void); #ifdef USE_FREETYPE2 -MWDECL int MWFL_FT2Setup(); +MWDECL int MWFL_FT2Setup(void); #endif #ifdef USE_STB_TRUETYPE -MWDECL int MwFL_STBTTSetup(); +MWDECL int MwFL_STBTTSetup(void); #endif MWDECL int (*MwFLDrawText)(MwWidget handle, MwPoint* point, const char* text, int bold, int align, MwLLColor color); diff --git a/src/text/ft2.c b/src/text/ft2.c index a5fb920..c30f3da 100644 --- a/src/text/ft2.c +++ b/src/text/ft2.c @@ -128,7 +128,7 @@ static void ft2_MwFontFree(void* handle) { free(ttf); } -int MWFL_FT2Setup() { +int MWFL_FT2Setup(void) { MwFLDrawText = ft2_MwDrawText; MwFLTextWidth = ft2_MwTextWidth; MwFLTextHeight = ft2_MwTextHeight; diff --git a/src/text/stbtt.c b/src/text/stbtt.c index fb5e783..ab9d539 100644 --- a/src/text/stbtt.c +++ b/src/text/stbtt.c @@ -1,5 +1,4 @@ #ifdef USE_STB_TRUETYPE -#include #include #include "../../external/stb_truetype.h" @@ -129,7 +128,7 @@ static void stbtt_MwFontFree(void* handle) { free(ttf); } -int MwFL_STBTTSetup() { +int MwFL_STBTTSetup(void) { MwFLDrawText = stbtt_MwDrawText; MwFLTextWidth = stbtt_MwTextWidth; MwFLTextHeight = stbtt_MwTextHeight; diff --git a/src/text/text.c b/src/text/text.c index e25d28b..8d19de8 100644 --- a/src/text/text.c +++ b/src/text/text.c @@ -140,8 +140,8 @@ static void bitmap_MwDrawText(MwWidget handle, MwPoint* point, const char* text, free(px); } -typedef int (*call_t)(); -void MwFLSetup() { +typedef int (*call_t)(void); +void MwFLSetup(void) { call_t calls[] = { #ifdef USE_FREETYPE2 MWFL_FT2Setup,