From 7ef7f57d79ec9c7e06d890e9ab6e5eb135214049 Mon Sep 17 00:00:00 2001 From: tusharsingh09 Date: Sat, 29 Jan 2022 16:35:37 +0530 Subject: [PATCH] Add clamping to upper left edge --- src/rcore.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/rcore.c b/src/rcore.c index 5aeabba8b..e6b25e94a 100644 --- a/src/rcore.c +++ b/src/rcore.c @@ -924,6 +924,10 @@ void InitWindow(int width, int height, const char *title) void InitWindowAt(int width, int height, int x, int y, const char* title) { #if defined(PLATFORM_DESKTOP) + // Maintain borders + if(x <= 0) x = 0; + if(y <= 25) y = 25; + SetConfigFlags(FLAG_WINDOW_HIDDEN); InitWindow(width, height, title); SetWindowPosition(x, y);