Fix: Use "round" instead of "floor" in snapping UI to pixels

This commit is contained in:
Aleksandr Zinovev 2017-03-26 12:16:04 +03:00
parent 001fce167a
commit fa63515c37
Notes: blender-bot 2023-05-22 12:40:41 +02:00
Referenced by issue #51845, UI Scale cause double width vertical borders
1 changed files with 1 additions and 1 deletions

View File

@ -1337,7 +1337,7 @@ static void ui_but_to_pixelrect(rcti *rect, const ARegion *ar, uiBlock *block, u
rctf rectf;
ui_block_to_window_rctf(ar, block, &rectf, (but) ? &but->rect : &block->rect);
BLI_rcti_rctf_copy_floor(rect, &rectf);
BLI_rcti_rctf_copy(rect, &rectf);
BLI_rcti_translate(rect, -ar->winrct.xmin, -ar->winrct.ymin);
}