Results 1 to 3 of 3

Thread: Strange Qt 4.4.0 string problem

  1. #1
    Join Date
    May 2007
    Location
    Lublin, Poland
    Posts
    345
    Thanks
    40
    Thanked 8 Times in 4 Posts
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default Strange Qt 4.4.0 string problem

    Hi gusy,

    After switching to Qt 4.4.0 I have few problems, most of which are connected with strings. Compiled against Qt 4.3.4 my app runs fine.
    When I compile against 4.4.0 it crashes because:

    when I read data from a file (simple C code, no Qt) while I read double var it crashes because doubles are stored like this: "89.9999", but when I have "89,9999" instead it works fine.

    Suddenly Most of my sees doubles with ","[comma] not with a simple '.' before the fraction part.

    Any idea what can be wrong?

    What strikes me though, there is no Qt code/classes used while reading data from files, but depending on Qt ver I get different run-time result.

    Thanks for any idea.

    Kacper
    Qt allows you to use everything you want
    wysota
    --------------------------------------------------------------------------------
    #if defined(Q_OS_UNIX) && defined(QT_DEBUG)
    abort(); // trap; generates core dump
    #else
    exit(1); // goodbye cruel world
    #endif

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Strange Qt 4.4.0 string problem

    Can we see the code?

  3. #3
    Join Date
    Jan 2006
    Location
    Bremen, Germany
    Posts
    554
    Thanked 86 Times in 81 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Strange Qt 4.4.0 string problem

    Looks like you're using another locale setting. Maybe QLocale can help you but don't know exactly.

Similar Threads

  1. Very Strange problem
    By dreamer in forum Qt Programming
    Replies: 1
    Last Post: 30th April 2008, 09:20
  2. Hi. I have problem with QCString in 4.4.0
    By ivi2501 in forum Qt Programming
    Replies: 3
    Last Post: 25th March 2008, 18:30
  3. Strange shortcut problem
    By blukske in forum Qt Programming
    Replies: 0
    Last Post: 13th March 2007, 10:26
  4. QT string Find problem
    By kingslee in forum Qt Programming
    Replies: 2
    Last Post: 16th October 2006, 20:45
  5. Strange Problem with JPEG Support on win XP
    By caligula in forum Installation and Deployment
    Replies: 3
    Last Post: 18th September 2006, 10:36

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.