Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Emulate terminal with QTextEdit, but how to log to text file sequentially
Forum Update on Monday, May 27th 2025

Emulate terminal with QTextEdit, but how to log to text file sequentially

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 596 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    jemyzhang
    wrote on last edited by
    #1

    I am writing a serial terminal with qtextedit, and want to log the output to file.

    But a lot of insert/delete actions takes in the terminal while I have to log out the final text.

    and a feature is, terminal(text) only display the limited lines, the oldest lines will be discarded, but the log file has to record all.

    now, my implement is, while one 'return' is input, the previous line will be write to the log file.
    but if doing this, the last line without 'return' will be lost.

    So, is there any better way?

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved