Menu

#255 How to disable the pager?

None
closed
nobody
None
8
2024-09-26
2020-09-26
No

wxMaxima, a frontend to maxima, a cool computer algebra system can tell gnuplot to use the png or the pngcairo terminal. The latter is way better, but some gnuplot versions (namely on MacOs) come without it. I therefore start gnuplot on startup, feed it with the commands

set terminal;
quit();

from its standard input - and am asked to press enter once every few lines hoping that the user hasn't set PAGER to something else than less.

Is there a way to tell gnuplot not to use any pager? Just unsetting the PAGER environment variable doesn't help, seemingly.

Thanks a lot in advance,
Gunter.

Discussion

  • Ethan Merritt

    Ethan Merritt - 2020-09-26

    gnuplot doesn't know anything about PAGER. That's a shell thing.

    I don't follow what exactly "set terminal; quit" is supposed to accomplish? It lists the supported terminals on the screen one line per terminal, which I guess is what you don't want. Perhaps you could instead use

      $ gnuplot -e "print GPVAL_TERMINALS"
    

    or even

       $ gnuplot -e "print GPVAL_TERMINAL" |& grep -c pngcairo
    

    The first will show a one line list of available terminals. The second with return 1 or 0 depending on whether pngcairo appears in that list.

     
    • Ethan Merritt

      Ethan Merritt - 2020-09-27

      Slight correction: gnuplot does use PAGER from the environment to print out sections of the user manual when you type "help". It does not use it for the output of any commands other than "help".

       
  • Gunter Königsmann

    That's exactly what I was searching for! Thanks a lot,

     Gunter.
    
     
  • Ethan Merritt

    Ethan Merritt - 2024-09-26
    • status: open --> closed
    • Group: -->
     

Log in to post a comment.