From 0556faf2e7c2b8ed51276a88bc87815072fb5b9a Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Tue, 4 Jul 2023 12:06:56 +0530 Subject: [PATCH] Rename function --- kitty/boss.py | 6 +++--- kitty/fast_data_types.pyi | 2 +- kitty/glfw.c | 2 +- kitty/state.c | 8 ++++---- kitty/state.h | 2 +- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/kitty/boss.py b/kitty/boss.py index f6b00bd4f..95c33d4d3 100644 --- a/kitty/boss.py +++ b/kitty/boss.py @@ -106,9 +106,9 @@ set_boss, set_in_sequence_mode, set_options, + set_os_window_chrome, set_os_window_size, set_os_window_title, - set_window_chrome, thread_write, toggle_fullscreen, toggle_maximized, @@ -1474,7 +1474,7 @@ def default_bg_changed_for(self, window_id: int) -> None: t = tm.tab_for_id(w.tab_id) if t is not None: t.relayout_borders() - set_window_chrome(w.os_window_id) + set_os_window_chrome(w.os_window_id) def dispatch_action( self, @@ -2399,7 +2399,7 @@ def patch_colors(self, spec: Dict[str, Optional[int]], configured: bool = False) t = tm.active_tab if t is not None: t.relayout_borders() - set_window_chrome(tm.os_window_id) + set_os_window_chrome(tm.os_window_id) patch_global_colors(spec, configured) def apply_new_options(self, opts: Options) -> None: diff --git a/kitty/fast_data_types.pyi b/kitty/fast_data_types.pyi index f2ef86e5d..3dd584199 100644 --- a/kitty/fast_data_types.pyi +++ b/kitty/fast_data_types.pyi @@ -466,7 +466,7 @@ def init_cell_program() -> None: pass -def set_window_chrome(os_window_id: int) -> bool: +def set_os_window_chrome(os_window_id: int) -> bool: pass diff --git a/kitty/glfw.c b/kitty/glfw.c index b17082e23..938a0a377 100644 --- a/kitty/glfw.c +++ b/kitty/glfw.c @@ -886,7 +886,7 @@ apply_window_chrome_state(GLFWwindow *w, WindowChromeState new_state, int width, #endif void -set_window_chrome(OSWindow *w) { +set_os_window_chrome(OSWindow *w) { if (!w->handle) return; color_type bg = OPT(background); if (w->num_tabs > w->active_tab) { diff --git a/kitty/state.c b/kitty/state.c index 5faabf310..3046e522e 100644 --- a/kitty/state.c +++ b/kitty/state.c @@ -516,7 +516,7 @@ set_active_window(id_type os_window_id, id_type tab_id, id_type window_id) { (void)window; tab->active_window = w; osw->needs_render = true; - set_window_chrome(osw); + set_os_window_chrome(osw); END_WITH_WINDOW; } @@ -878,11 +878,11 @@ PYWRAP1(run_with_activation_token) { Py_RETURN_NONE; } -PYWRAP1(set_window_chrome) { +PYWRAP1(set_os_window_chrome) { id_type os_window_id; PA("K", &os_window_id); WITH_OS_WINDOW(os_window_id) - set_window_chrome(os_window); + set_os_window_chrome(os_window); Py_RETURN_TRUE; END_WITH_OS_WINDOW Py_RETURN_FALSE; @@ -1360,7 +1360,7 @@ static PyMethodDef module_methods[] = { MW(mark_os_window_for_close, METH_VARARGS), MW(set_application_quit_request, METH_VARARGS), MW(current_application_quit_request, METH_NOARGS), - MW(set_window_chrome, METH_VARARGS), + MW(set_os_window_chrome, METH_VARARGS), MW(focus_os_window, METH_VARARGS), MW(mark_tab_bar_dirty, METH_O), MW(run_with_activation_token, METH_O), diff --git a/kitty/state.h b/kitty/state.h index 6d9393054..b55296fe9 100644 --- a/kitty/state.h +++ b/kitty/state.h @@ -314,7 +314,7 @@ void send_image_to_gpu(uint32_t*, const void*, int32_t, int32_t, bool, bool, boo void send_sprite_to_gpu(FONTS_DATA_HANDLE fg, unsigned int, unsigned int, unsigned int, pixel*); void blank_canvas(float, color_type); void blank_os_window(OSWindow *); -void set_window_chrome(OSWindow *w); +void set_os_window_chrome(OSWindow *w); FONTS_DATA_HANDLE load_fonts_data(double, double, double); void send_prerendered_sprites_for_window(OSWindow *w); #ifdef __APPLE__