Keymaps: take into account DPI for tweak/drag/pie thresholds.
The intention is to fix a too low default threshold on high DPI screen. Users with high DPI screens that have increased the threshold to fix this or liked the lower threshold will need to lower it again. This is still somewhat of a guess, ideally this would be based on the physical distance travalled, and maybe different per type of input device. However we do not have access to this information, and hope this gives a better default.
This commit is contained in:
@@ -4566,8 +4566,8 @@ void ui_draw_pie_center(uiBlock *block)
|
||||
|
||||
float *pie_dir = block->pie_data.pie_dir;
|
||||
|
||||
float pie_radius_internal = U.pixelsize * U.pie_menu_threshold;
|
||||
float pie_radius_external = U.pixelsize * (U.pie_menu_threshold + 7.0f);
|
||||
float pie_radius_internal = U.dpi_fac * U.pie_menu_threshold;
|
||||
float pie_radius_external = U.dpi_fac * (U.pie_menu_threshold + 7.0f);
|
||||
|
||||
int subd = 40;
|
||||
|
||||
@@ -4609,8 +4609,8 @@ void ui_draw_pie_center(uiBlock *block)
|
||||
immUnbindProgram();
|
||||
|
||||
if (U.pie_menu_confirm > 0 && !(block->pie_data.flags & (UI_PIE_INVALID_DIR | UI_PIE_CLICK_STYLE))) {
|
||||
float pie_confirm_radius = U.pixelsize * (pie_radius_internal + U.pie_menu_confirm);
|
||||
float pie_confirm_external = U.pixelsize * (pie_radius_internal + U.pie_menu_confirm + 7.0f);
|
||||
float pie_confirm_radius = U.dpi_fac * (pie_radius_internal + U.pie_menu_confirm);
|
||||
float pie_confirm_external = U.dpi_fac * (pie_radius_internal + U.pie_menu_confirm + 7.0f);
|
||||
|
||||
const char col[4] = {btheme->tui.wcol_pie_menu.text_sel[0],
|
||||
btheme->tui.wcol_pie_menu.text_sel[1],
|
||||
|
Reference in New Issue
Block a user