Blender V5.0
wm_window.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2007 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9#pragma once
10
11#include "BLI_compiler_attrs.h"
12
13struct bContext;
14struct Main;
15struct PointerRNA;
16struct wmOperator;
17struct wmOperatorType;
18struct wmWindow;
19struct wmWindowManager;
20
21/* *************** Internal API ************** */
22
29void wm_ghost_exit();
30
32
44
48wmWindow *wm_window_new(const Main *bmain, wmWindowManager *wm, wmWindow *parent, bool dialog);
53 Main *bmain, wmWindowManager *wm, wmWindow *win_src, bool duplicate_layout, bool child);
58wmWindow *wm_window_copy_test(bContext *C, wmWindow *win_src, bool duplicate_layout, bool child);
69
89
96
97void wm_window_raise(wmWindow *win);
98void wm_window_lower(wmWindow *win);
99void wm_window_set_size(wmWindow *win, int width, int height);
105void wm_window_set_swap_interval(wmWindow *win, int interval);
106bool wm_window_get_swap_interval(wmWindow *win, int *r_interval);
107
108bool wm_cursor_position_get(wmWindow *win, int *r_x, int *r_y) ATTR_WARN_UNUSED_RESULT;
111
114
115#ifdef WITH_INPUT_IME
116void wm_window_IME_begin(wmWindow *win, int x, int y, int w, int h, bool complete);
117void wm_window_IME_end(wmWindow *win);
118#endif
119
125
126/* *************** window operators ************** */
127
141
144
#define ATTR_WARN_UNUSED_RESULT
#define ATTR_NONNULL(...)
#define C
Definition RandGen.cpp:29
SIMD_FORCE_INLINE const btScalar & w() const
Return the w value.
Definition btQuadWord.h:119
PointerRNA * ptr
Definition wm_files.cc:4238
wmOperatorType * ot
Definition wm_files.cc:4237
wmWindow * wm_window_copy(Main *bmain, wmWindowManager *wm, wmWindow *win_src, const bool duplicate_layout, const bool child)
Definition wm_window.cc:335
void wm_window_swap_buffer_release(wmWindow *win)
void wm_cursor_position_from_ghost_screen_coords(wmWindow *win, int *x, int *y)
wmWindow * wm_window_new(const Main *bmain, wmWindowManager *wm, wmWindow *parent, bool dialog)
Definition wm_window.cc:319
void wm_window_raise(wmWindow *win)
void wm_cursor_position_to_ghost_client_coords(wmWindow *win, int *x, int *y)
void wm_cursor_position_from_ghost_client_coords(wmWindow *win, int *x, int *y)
void wm_cursor_position_to_ghost_screen_coords(wmWindow *win, int *x, int *y)
void wm_window_reset_drawable()
void wm_window_swap_buffer_acquire(wmWindow *win)
Push rendered buffer to the screen.
void wm_window_events_process(const bContext *C)
bool wm_cursor_position_get(wmWindow *win, int *r_x, int *r_y)
void wm_window_close(bContext *C, wmWindowManager *wm, wmWindow *win)
Definition wm_window.cc:463
void wm_window_set_swap_interval(wmWindow *win, int interval)
void wm_window_set_size(wmWindow *win, int width, int height)
bool wm_window_get_swap_interval(wmWindow *win, int *r_interval)
void wm_window_ghostwindows_remove_invalid(bContext *C, wmWindowManager *wm)
void wm_window_clear_drawable(wmWindowManager *wm)
void wm_window_make_drawable(wmWindowManager *wm, wmWindow *win)
wmWindow * wm_window_copy_test(bContext *C, wmWindow *win_src, const bool duplicate_layout, const bool child)
Definition wm_window.cc:365
void wm_window_free(bContext *C, wmWindowManager *wm, wmWindow *win)
Definition wm_window.cc:245
void wm_window_ghostwindows_ensure(wmWindowManager *wm)
bool wm_get_desktopsize(int r_size[2])
Definition wm_window.cc:192
void wm_window_lower(wmWindow *win)
void wm_quit_with_optional_confirmation_prompt(bContext *C, wmWindow *win) ATTR_NONNULL()
Definition wm_window.cc:407
wmOperatorStatus wm_window_new_exec(bContext *C, wmOperator *op)
void wm_test_foreign_file_warning(bContext *C)
Definition wm_files.cc:4305
void wm_test_autorun_revert_action_set(wmOperatorType *ot, PointerRNA *ptr)
Definition wm_files.cc:4241
void wm_ghost_exit()
void wm_ghost_init_background()
void wm_clipboard_free()
wmOperatorStatus wm_window_close_exec(bContext *C, wmOperator *op)
wmOperatorStatus wm_window_new_main_exec(bContext *C, wmOperator *op)
void wm_test_autorun_warning(bContext *C)
Definition wm_files.cc:4274
wmOperatorStatus wm_window_fullscreen_toggle_exec(bContext *C, wmOperator *op)
void wm_ghost_init(bContext *C)
bool wm_get_screensize(int r_size[2]) ATTR_NONNULL(1) ATTR_WARN_UNUSED_RESULT
Definition wm_window.cc:181
void wm_window_timers_delete_removed(wmWindowManager *wm)