Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-1057

QDoubleSpinBox doesn't respect the widget's locale property

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • 4.7.0
    • 4.3.1
    • Core: Locales (i18n)
    • None

    Description

      On a German system (decimal separator ','), this will continue to use the ',' separator even though it should use '.':

      #include <QtGui>

      int main(int argc, char **argv)
      {
      QApplication app(argc, argv);

      QDoubleSpinBox spinBox;
      spinBox.setLocale(QLocale::C);
      spinBox.setMaximum(10000);
      spinBox.show();
      spinBox.setValue(1000.12);

      return app.exec();
      }

      If the locale defines that thousand and decimal separators are the same, then this will in fact show neither.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            waterdomain Water Domain (Inactive)
            vhilshei Volker Hilsheimer
            Votes:
            2 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes