On Sun, 05 Aug 2007 01:55:13 +0000, Andy Smith wrote: > On Sat, Aug 04, 2007 at 09:06:19PM -0400, Tong Sun wrote: >> I remember that I used to be able to exit 'less' by command key 'x' or >> something so that the content just viewed is left on screen, instead of >> being cleared and restored to the screen before invoking 'less'. But I >> found there is no such capability in current less (version 394). Or >> is there? > > Can't you just call "less -X" or set the environment variable LESS > to contain "-X"?
Thanks for all replies. On reviewing them and the faq, I think my wish still holds. Just like John Hasler has pointed out, the -X disables termcap initialization and deinitialization. The effect is that, when I browse say a big file, paging up and down several times, and then exit, my xterm will be left with all contents that I've browsed, with " ...skipping... " in between them. So having a keyboard command 'x' or something can allows me, - have the freedom to decide whether I want to leave the content or not - invoke less the same way, no matter whether I want to leave the content or not - leave my xterm with the only pageful of info that I deliberately chosen, instead of cluttering it with all the contents that I've viewed. I don't know if this is possible. But it's a nice feature. It comes especially handy when you want to preserve your xterm scroll-back history as much as possible, but still able to copy the content out of the man page, which might be lengthy and might took a while for your to locate where you want to copy from. Thanks -- Tong (remove underscore(s) to reply) http://xpt.sourceforge.net/techdocs/ http://xpt.sourceforge.net/tools/ -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]