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. Single line editor with history for console app
Qt 6.11 is out! See what's new in the release blog

Single line editor with history for console app

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 3 Posters 648 Views 2 Watching
  • 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.
  • ocgltdO Offline
    ocgltdO Offline
    ocgltd
    wrote on last edited by
    #1

    I am writing a console app that prompts for info from the user. I would like to implement a command history, tab for completion, etc.

    Does Qt already have a library that does this?

    I found reference to a "readline" library which might do some of this, but I'm hoping for something Qt specific

    JonBJ 1 Reply Last reply
    0
    • Kent-DorfmanK Offline
      Kent-DorfmanK Offline
      Kent-Dorfman
      wrote on last edited by
      #2

      readline is the standard library for this in POSIX systems.

      The dystopian literature that served as a warning in my youth has become an instruction manual in my elder years.

      1 Reply Last reply
      2
      • ocgltdO ocgltd

        I am writing a console app that prompts for info from the user. I would like to implement a command history, tab for completion, etc.

        Does Qt already have a library that does this?

        I found reference to a "readline" library which might do some of this, but I'm hoping for something Qt specific

        JonBJ Online
        JonBJ Online
        JonB
        wrote on last edited by JonB
        #3

        @ocgltd
        I heartily recommend readline, having used it for many years. It is written in plain C. It works fine with a Qt (console) application. This is for Linux; if you are Windows I don't know how good/supported it is these days.

        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