Morteza Jamshidi d610103126 QDoubleSpinBox: Use QLocale to omit group separators
Instead of removing group separators after conversion, we can omit them
using QLocale. The decimal point and group separators can be the
same character, if the user configures the system locale accordingly.

Add a test that compares the text shown by the spinbox with what the
locale would do. Since the C locale sets the OmitGroupSeperator number
option by default, cover several cases to verify that we explicitly
set the correct number options based on the QDoubleSpinBox property,
and implement a customized system locale that returns the same
character for group separator and decimal point.

Fixes: QTBUG-77939
Change-Id: I257ea44ed988c70cb4fc0cfc81c3b366c0a431eb
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 34b5e43e6259c6362c642a244ceb26d482f35b82)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
2024-11-08 12:32:26 +00:00
..
2024-11-07 08:38:49 +01:00
2024-11-07 08:38:49 +01:00
2024-11-07 08:38:49 +01:00

This directory contains autotests and benchmarks based on Qt Test. In order
to run the autotests reliably, you need to configure a desktop to match the
test environment that these tests are written for.

Linux X11:

   * The user must be logged in to an active desktop; you can't run the
     autotests without a valid DISPLAY that allows X11 connections.

   * The tests are run against a KDE3 or KDE4 desktop.

   * Window manager uses "click to focus", and not "focus follows mouse". Many
     tests move the mouse cursor around and expect this to not affect focus
     and activation.

   * Disable "click to activate", i.e., when a window is opened, the window
     manager should automatically activate it (give it input focus) and not
     wait for the user to click the window.