Fix resize_draw_strategy=static
The text is now static again but the background image is still scaled, cant be bothered about that. Fixes #5601
This commit is contained in:
parent
5c34f16ab4
commit
0f340086c0
@ -35,6 +35,11 @@ mouse anywhere in the current command to move the cursor there. See
|
|||||||
Detailed list of changes
|
Detailed list of changes
|
||||||
-------------------------------------
|
-------------------------------------
|
||||||
|
|
||||||
|
0.26.5 [future]
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
- Fix a regression in the previous release that caused a :opt:`resize_draw_strategy` of ``static`` to not work (:iss:`5601`)
|
||||||
|
|
||||||
0.26.4 [2022-10-17]
|
0.26.4 [2022-10-17]
|
||||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
|||||||
@ -690,6 +690,11 @@ render_os_window(OSWindow *os_window, unsigned int active_window_id, color_type
|
|||||||
float x_ratio = 1, y_ratio = 1;
|
float x_ratio = 1, y_ratio = 1;
|
||||||
draw_borders(br->vao_idx, br->num_border_rects, br->rect_buf, br->is_dirty, os_window->viewport_width, os_window->viewport_height, active_window_bg, num_visible_windows, all_windows_have_same_bg, os_window);
|
draw_borders(br->vao_idx, br->num_border_rects, br->rect_buf, br->is_dirty, os_window->viewport_width, os_window->viewport_height, active_window_bg, num_visible_windows, all_windows_have_same_bg, os_window);
|
||||||
br->is_dirty = false;
|
br->is_dirty = false;
|
||||||
|
bool static_live_resize_in_progress = os_window->live_resize.in_progress && OPT(resize_draw_strategy) == RESIZE_DRAW_STATIC;
|
||||||
|
if (static_live_resize_in_progress) {
|
||||||
|
x_ratio = (float) os_window->viewport_width / (float) os_window->live_resize.width;
|
||||||
|
y_ratio = (float) os_window->viewport_height / (float) os_window->live_resize.height;
|
||||||
|
}
|
||||||
if (TD.screen && os_window->num_tabs >= OPT(tab_bar_min_tabs)) draw_cells(TD.vao_idx, 0, &TD, x_ratio, y_ratio, os_window, true, false, NULL);
|
if (TD.screen && os_window->num_tabs >= OPT(tab_bar_min_tabs)) draw_cells(TD.vao_idx, 0, &TD, x_ratio, y_ratio, os_window, true, false, NULL);
|
||||||
for (unsigned int i = 0; i < tab->num_windows; i++) {
|
for (unsigned int i = 0; i < tab->num_windows; i++) {
|
||||||
Window *w = tab->windows + i;
|
Window *w = tab->windows + i;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user