i'm trying to make a chat application in QT . Is it possible to read data from the text browser of QT GUI(which shows conversations) so that i can maintain a chat history...?plz help..Thank You
Is it possible to read data from the text browser of QT GUI
4.4k views Asked by kernel At
2
There are 2 answers
Related Questions in QT
- qt c++ fonction converting adress to coordinates (longitude, latitude)
- Qml table and chart using python
- Qt: running callback in the main thread from the worker thread
- i have installed qt version 6.0.3 and this error QMYSQL driver not loaded displaying again and again
- Frameless Qt + WinAPI maximized window size is bigger than the availableGeometry()
- new window with c++ qt
- How to get scaling from transformation matrix
- How to build just Qt core libraries from Qt sources
- doxyqml not documenting qml files properly
- Incorrect assignment from a QStringList to a char * array
- How to make QT Chart size larger than widget size?
- Queued async operations with QtConcurrent interfere QImage from freed
- Questions about qt5 dynamic link library
- how to document QML files inside C++ project?
- How do I keep my screen contents centered and also have a scrollbar in QT?
Related Questions in DATAREADER
- SSIS Deployment Error: DataReader Issue When Executing Truncate Table SQL Command Task from SSISDB in SQL Server
- MATLAB urlread function error appears when trying to connect to a server
- Python: yfinance unable to handle exceptions
- pycharm pandas datareader unable to import duyf=f]dai;sad'lsahildsalj;dasli
- time data 'yahoo' does not match format '%Y-%m-%d in pandas datareader, python
- Move On To Next Record If Condition Not Met
- TypeError: string indices must be integers <-- How do I?
- Retrieved data not read in while loop using SQLiteDataReader.Read() method in C#
- MySQL DataReader only read first row and nothing else
- C# SqlDataReader Get Value By Column Name (Case Insensitive)
- Why am I getting this error with this simple code?
- How can I retrieve the correct value of a MySQL Time Column in C# using the MySqlDataReader
- python install pip and pandas-data reader on Mac
- Suddenly getting an error "Operation is not valid due to the current state of the object" in VB.net with Oracle 11g Database
- VB.NET SQL conversion error when trying to read data
Related Questions in QTEXTBROWSER
- pyqt5 - Implementing a custom Horizontal ScrollBar for Qtextbrowser
- Using QTextCursor to select and delete a given row from QTextBrowser
- QT 4.8.6 TextBrowser Displaying Hyperlinks That Runs Functions
- tableContent wont update the contents when the search criteria changed
- QTextbrowser Scroll through text whilst new text is still being added
- PyQt6 QTextBrowser find text and put it at the top and deselect it
- Unexpected results when appending links and line breaks to QTextBrowser
- QTextBrowser doesnt update with append, when calling this function from another class
- In PySside2, how can I show the thumbnail for an item in QtextBrowser when the user hovers it?
- Qtextbrowser pyqt5 problem after click on anchor
- QTextBrowser shows markdown on Mac but not on Windows
- How to write text from QTextBrowser to csv?
- PyQt5 - Display lines from script
- About QT5 Qprocess output in Ubuntu
- How can I erase the last lines in a QTextBrowser?
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Popular Tags
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
The
QTextBrowserinheritsQTextEdit, which works on aQTextDocument. The QTextDocument can be converted to (and saved as) HTML usingQTextDocument::toHtml():I advise you to append to a log file every time a new message comes in / goes out, so update the QTextBrowser and the file "in parallel", and not saving the entire chat history everytime a new message appears.
To do so, open the log file and manually write the open
<html>and<body>tags without closing them. Then append the chat log entries on the still opened file. On application exit (object destruction of the chat window or whatever), close the</body>and</html>tags and afterwards the file itself. This will result in a much better performance than saving the whole file for every change of the QTextBrowser widget.