Results 1 to 4 of 4

Thread: File size limitation in qt

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Oct 2014
    Posts
    1
    Qt products
    Qt/Embedded
    Platforms
    Windows

    Question File size limitation in qt

    I have a text file size of 3.33MB which i need to render in the text browser. But only 1MB of text file data is read and rendered.
    It would be helpfull i could know the text file size limit to render in qt.

    I am using the following code.

    Qt Code:
    1. #include "file.h"
    2. #include "ui_file.h"
    3. #include<QFile>
    4. #include<QTextStream>
    5. #include<QMessageBox>
    6.  
    7. file::file(QWidget *parent) :
    8. QMainWindow(parent),
    9. ui(new Ui::file)
    10. {
    11. ui->setupUi(this);
    12. }
    13.  
    14. file::~file()
    15. {
    16. delete ui;
    17. }
    18.  
    19. void file::on_pushButton_clicked()
    20. {
    21. QFile file ("D:\\Users\\aisu1452\\Thales_db_frgbsa9.pc");
    22.  
    23. if(!file.open(QIODevice :: ReadOnly))
    24. {
    25. QMessageBox :: information(0,"info", file.errorString());
    26. }
    27. else
    28. {
    29. QTextStream in (&file);
    30. ui->textBrowser->setText(in.readAll());
    31. }
    32.  
    33. }
    To copy to clipboard, switch view to plain text mode 
    Last edited by wysota; 20th October 2014 at 09:04. Reason: missing [code] tags

Similar Threads

  1. Qwt axis scale limitation
    By Momergil in forum Qwt
    Replies: 2
    Last Post: 14th January 2013, 17:03
  2. QPixmap size limitation
    By Thuan Seah Tan in forum Qt Programming
    Replies: 3
    Last Post: 21st February 2012, 00:26
  3. QImage size limitation
    By JovianGhost in forum Qt Programming
    Replies: 3
    Last Post: 24th March 2010, 12:01
  4. QPoint Limitation
    By archanasubodh in forum Qt Programming
    Replies: 1
    Last Post: 5th August 2008, 10:22
  5. Limitation when adding more than 256 items to a model
    By darkadept in forum Qt Programming
    Replies: 5
    Last Post: 25th May 2006, 15:26

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.