#158 can't backspace or use ^B to go to previous line

Andrew Finlay

I recently reinstalled my Ubuntu on my computer and gnuplot is showing some very strange behaviour.

If when typing a command it goes into a new line (ie. soft return) I can no longer go back to the previous line. Backspace doesn't work, back arrow or ^B don't work either.

I've also noticed that if I use the back arrow to try to reach the previous line then press the forward arrow it will append the last few characters from the previous line to the front of the current line. The number of characters appended seems to depend on how many times I press the back arrow. Using backspace at the front of the line seems to stop this particular behaviour.

I have no idea how to fix this, so any help would be very much appreciated. Thank you.


  • Could you please provide the output of
    show version long ?
    Did you compile gnuplot or install it from a repository?

  • Andrew Finlay
    Andrew Finlay

    Output from "show version long":

    G N U P L O T
    Version 4.6 patchlevel 3    last modified 2013-04-12 
    Build System: Linux i686
    Copyright (C) 1986-1993, 1998, 2004, 2007-2013
    Thomas Williams, Colin Kelley and many others
    gnuplot home:     http://www.gnuplot.info
    faq, bugs, etc:   type "help FAQ"
    immediate help:   type "help"  (plot window: hit 'h')

    Compile options:

    GNUPLOT_DRIVER_DIR = "/usr/local/libexec/gnuplot/4.6"
    GNUPLOT_PS_DIR = "/usr/local/share/gnuplot/4.6/PostScript"
    HELPFILE = "/usr/local/share/gnuplot/4.6/gnuplot.gih"

    I compiled gnuplot.
    Or in case I've got my terminology off: I extracted the archive gnuplot-4.6.3.tar.gz, then used the commands:
    make install

  • Andrew Finlay
    Andrew Finlay

    Okay, I seem to have fixed my problem.

    I installed the library "libreadline-dev" then recompiled gnuplot and now things appear to be working as they should.

    I should note, I also had installed Code Blocks on my computer before I added the aforementioned library and recompiled, but I strongly suspect it was the added library that made the difference.

    Thanks anyway.

  • Ethan Merritt
    Ethan Merritt

    • status: open --> closed
    • Group: -->