Gui : susbtitute dot with local decimal separator for spin boxes

Main goal is to improve user-friendlyness for several locales
 Substitution of dot is performed :
 * Always if dot is neither decimal nor group/thousand separator of current locale
 * Only on NUMPAD dot if dot is not decimal but is group separator of current locale
This commit is contained in:
0penBrain
2020-06-13 16:19:32 +02:00
parent 68fbf89e38
commit 510cbf523a
3 changed files with 41 additions and 0 deletions

View File

@@ -2080,6 +2080,12 @@ void Application::runApplication(void)
WheelEventFilter* filter = new WheelEventFilter(&mainApp);
mainApp.installEventFilter(filter);
}
//filter keyboard events to substitute decimal separator
if (hGrp->GetBool("SubstituteDecimalSeparator", false)) {
KeyboardFilter* filter = new KeyboardFilter(&mainApp);
mainApp.installEventFilter(filter);
}
#if defined(HAVE_QT5_OPENGL)
{