Opened 14 years ago

Closed 14 years ago

#127 closed defect (fixed)

QDesigner fails to load large/complex ui file made on MAC/Windows

Reported by: jvw Owned by:
Priority: major Milestone: Qt 4.6.2
Component: Tools Version: 4.5.1 GA
Severity: low Keywords: Designer
Cc:

Description

I just installed the Qt4 4.51 WPI archives to check out QDesigner with some existing Qt projects I have (created on Windows, using Qt 4.60).

Sofar I did not install the GCC compiler yet, just playing with the designer.

The very first project I tried, with one dialog, failed to load that dialog with an error message stating the file was not a valid ui file, with additional info saying:

++++++
An error has occurred while reading the ui file at line 1, column 2: Expected '?', '!', or '[a-zA-Z]', but got '/'.
++++++

Of course those lines look fine in an editor, and the files works fine on Windows as well as the MAC. A small dummy dialog created on OS/2 does read back properly.

Testing the larger dialog by removing several widgets from the ui file, lead me to believe there is some size constraint (or overflow bug). After removing checkboxes one-by-one, the file became 'acceptable' when 4 of the 8 checkboxes had been removed, and the file size went down from almost 9884 bytes to 8376.

I will try to attach an OK and BAD version of the ui file.

TIA for any insight on this problem ...

Jan van Wijk

Attachments (2)

ardlgbad.ui (9.7 KB) - added by jvw 14 years ago.
Designer ui file, fails to load (maybe too large)
ardlg-ok.ui (8.2 KB) - added by jvw 14 years ago.
Designer ui file, stripped down from BAD, loads fine

Download all attachments as: .zip

Change History (5)

Changed 14 years ago by jvw

Attachment: ardlgbad.ui added

Designer ui file, fails to load (maybe too large)

Changed 14 years ago by jvw

Attachment: ardlg-ok.ui added

Designer ui file, stripped down from BAD, loads fine

comment:1 Changed 14 years ago by Dmitry A. Kuminov

Looks like QIODevice::seek(0) doesn't actually move the file pointer to the beginning of the file...

To be more exact, regular files were treated as sequential data streams and therefore seeking didn't work properly on QFile objects (internal QIODevice buffer got out of sync and would return earlier/later parts of the file when reading from files beyond the buffer size). Fixed in r551. The hot-fix drop-in replacement DLL is available at ftp://ftp.netlabs.org/pub/qt4/4.5.1-ga/QtCore4_r551.zip.

Please test on your side.

comment:2 in reply to:  1 Changed 14 years ago by jvw

Replying to dmik:

Looks like QIODevice::seek(0) doesn't actually move the file pointer to the beginning of the file...

Fixed in r551. The hot-fix drop-in replacement DLL is available at ftp://ftp.netlabs.org/pub/qt4/4.5.1-ga/QtCore4_r551.zip.

Please test on your side.

OK, thanks for this quick fix.

It seems to work just fine, I can now open de ui files that failed before!

Regards, JvW

comment:3 Changed 14 years ago by Dmitry A. Kuminov

Resolution: fixed
Status: newclosed

Thank you for the feedback.

Note: See TracTickets for help on using tickets.