mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-25 17:52:02 +02:00
macOS: Implement background blurring
Uses a private API that allows us to control the amount of blurring. While using a private API is obviously not ideal, it is used by both iTerm.app and Apple's own Terminal.app, so hopefully it should stick around. Fixes #6135
This commit is contained in:
5
glfw/window.c
vendored
5
glfw/window.c
vendored
@@ -334,6 +334,8 @@ void glfwDefaultWindowHints(void)
|
||||
_glfw.hints.window.ns.retina = true;
|
||||
// use the default colorspace assigned by the system
|
||||
_glfw.hints.window.ns.color_space = 0;
|
||||
// no blur
|
||||
_glfw.hints.window.ns.blur_radius = 0;
|
||||
}
|
||||
|
||||
GLFWAPI void glfwWindowHint(int hint, int value)
|
||||
@@ -417,6 +419,9 @@ GLFWAPI void glfwWindowHint(int hint, int value)
|
||||
case GLFW_COCOA_COLOR_SPACE:
|
||||
_glfw.hints.window.ns.color_space = value;
|
||||
return;
|
||||
case GLFW_COCOA_BLUR_RADIUS:
|
||||
_glfw.hints.window.ns.blur_radius = value;
|
||||
return;
|
||||
case GLFW_COCOA_GRAPHICS_SWITCHING:
|
||||
_glfw.hints.context.nsgl.offline = value ? true : false;
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user