From d7b0fa588fdf3cafd93fa9edf03226c2ec99e8cf Mon Sep 17 00:00:00 2001 From: Rob Loach Date: Tue, 24 Mar 2026 20:21:15 -0400 Subject: [PATCH] Further fixes --- nuklear.h | 6 +++--- src/nuklear_tooltip.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/nuklear.h b/nuklear.h index f1260387..3961073d 100644 --- a/nuklear.h +++ b/nuklear.h @@ -30711,11 +30711,11 @@ nk_tooltip_begin_offset(struct nk_context *ctx, float width, enum nk_tooltip_pos return 0; w = nk_iceilf(width); - h = NK_MAX(win->layout->row.min_height, ctx->style.font->height+2*ctx->style.window.padding.y); + h = (int)NK_MAX(win->layout->row.min_height, ctx->style.font->height+2*ctx->style.window.padding.y); /* Default origin is top left, plus user offset */ - x = nk_ifloorf(in->mouse.pos.x + 1) - (int)win->layout->clip.x + offset.x; - y = nk_ifloorf(in->mouse.pos.y + 1) - (int)win->layout->clip.y + offset.y; + x = nk_ifloorf(in->mouse.pos.x + 1) - (int)win->layout->clip.x + (int)offset.x; + y = nk_ifloorf(in->mouse.pos.y + 1) - (int)win->layout->clip.y + (int)offset.y; /* Adjust origin based on enum */ switch (position) { diff --git a/src/nuklear_tooltip.c b/src/nuklear_tooltip.c index 3729a0f5..1fee2e37 100644 --- a/src/nuklear_tooltip.c +++ b/src/nuklear_tooltip.c @@ -35,11 +35,11 @@ nk_tooltip_begin_offset(struct nk_context *ctx, float width, enum nk_tooltip_pos return 0; w = nk_iceilf(width); - h = NK_MAX(win->layout->row.min_height, ctx->style.font->height+2*ctx->style.window.padding.y); + h = (int)NK_MAX(win->layout->row.min_height, ctx->style.font->height+2*ctx->style.window.padding.y); /* Default origin is top left, plus user offset */ - x = nk_ifloorf(in->mouse.pos.x + 1) - (int)win->layout->clip.x + offset.x; - y = nk_ifloorf(in->mouse.pos.y + 1) - (int)win->layout->clip.y + offset.y; + x = nk_ifloorf(in->mouse.pos.x + 1) - (int)win->layout->clip.x + (int)offset.x; + y = nk_ifloorf(in->mouse.pos.y + 1) - (int)win->layout->clip.y + (int)offset.y; /* Adjust origin based on enum */ switch (position) {