From 026fe120fe5eadf8e5a45c73b0f63e9d867136d8 Mon Sep 17 00:00:00 2001 From: Romain Goyet Date: Wed, 17 Jun 2020 14:27:38 -0400 Subject: [PATCH] [simulator] Make the calculator's screen pixel-perfect --- ion/src/simulator/shared/layout.cpp | 2 +- ion/src/simulator/shared/main_sdl.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ion/src/simulator/shared/layout.cpp b/ion/src/simulator/shared/layout.cpp index 0b2241778..088e5444c 100644 --- a/ion/src/simulator/shared/layout.cpp +++ b/ion/src/simulator/shared/layout.cpp @@ -11,7 +11,7 @@ static constexpr float X(int x) { return static_cast(x)/static_cast(y)/static_cast(backgroundHeight); } static constexpr SDL_FRect areaOfInterest = {X(110), Y(30), X(940), Y(2150)}; -static constexpr SDL_FRect screenRect = {X(192), Y(191), X(779), Y(582)}; +static constexpr SDL_FRect screenRect = {X(192), Y(191), X(776), Y(582)}; static SDL_Rect sFrame; diff --git a/ion/src/simulator/shared/main_sdl.cpp b/ion/src/simulator/shared/main_sdl.cpp index bc7f59f83..0a79caf9c 100644 --- a/ion/src/simulator/shared/main_sdl.cpp +++ b/ion/src/simulator/shared/main_sdl.cpp @@ -73,7 +73,7 @@ void init() { Ion::Display::Height, 0 // Default flags: no high-dpi, not resizeable. #else - 290, 555, // Otherwise use a default size that matches the whole calculator + 458, 888, // Otherwise use a default size that makes the screen pixel-perfect SDL_WINDOW_ALLOW_HIGHDPI #if EPSILON_SDL_FULLSCREEN | SDL_WINDOW_FULLSCREEN