Skip to content

Commit 87e4d07

Browse files
committed
Maybe address high DPI on wayland?
1 parent 3fd07ff commit 87e4d07

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/lib/gui/window_glfw.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ class window_glfw
3131
return;
3232
}
3333

34+
glfwWindowHint(GLFW_SCALE_TO_MONITOR, GLFW_TRUE);
3435
_w = glfwCreateWindow(width, height, title.c_str(), NULL, NULL);
3536
if (!_w)
3637
{
@@ -102,7 +103,7 @@ class window_glfw
102103
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
103104
glViewport(xOffset, yOffset, viewportWidth, viewportHeight);
104105
};
105-
glfwSetWindowSizeCallback(_w, fun);
106+
glfwSetFramebufferSizeCallback(_w, fun);
106107
}
107108

108109
void resize(unsigned width, unsigned height)

0 commit comments

Comments
 (0)