Article View: news.software.readers
Article #41340Re: How to tell trn to use only 20 lines for display?
From: Kaz Kylheku
Date: Fri, 05 Jun 1998 00:00
Date: Fri, 05 Jun 1998 00:00
58 lines
2673 bytes
2673 bytes
In article <ulnrb64s5.fsf@xxx.yyy.zzz>, David Charlap <qqqq@xxx.yyy.zzz> wrote: >Aart de Vos <advs@xs4all.nl> writes: >> >> I use a Psion 3A organiser for dialing in onto a Unix machine. One of >> the applications I am using is trn. The Psion has a screen of 20 lines >> of 80 characters. After seting the LINES environment variable to 20, >> most applications run fine (vi, lynx) except for trn. I checked the man >> pages and the FAQ's but could not find any clue. > >If you're running it on a UNIX host, you can use the "stty" command. >That always worked for me when I wanted to make the display larger. It >should work for smaller as well. If your UNIX platform resembles BSD, >this should work: > > stty rows 20 This might not be sufficient for some programs. What you have done is installed the row size into the terminal driver. However, some applications depend on the LINES environment variable to also be correctly set because they don't check the values in the terminal driver, or they ignore those values if LINES is also set. There is a program called ``resize'' which comes with X11 distributions; it's meant to be used in conjunction with xterm. What it does is query the actual size of the window by telling the VT100 to move the cursor down and to the right by some large increments, to ensure that the cursor lands in the bottom right position, and then querying the terminal to discover the X, Y position where the cursor landed. When resize determines the position, it spits out some shell commands that set up the COLUMNS and LINES variables. Thus if you execute the command eval `resize` your COLUMNS and LINES should be set properly. If resize doesn't appear to be in your path, try /usr/X11/bin, /usr/bin/X11 or wherever your basic X binaries are stored. I have an eval `resize` command as part of my login script on nearly every system. stored. >Then run trn as usual. > >-- David
Technical Details
Message-ID:
<6l9rs9$sha@espresso.cafe.net>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mailReferences:
<6l8t4a$bbq$1@xs2.xs4all.nl> <ulnrb64s5.fsf@xxx.yyy.zzz>Show Full Headers
Complete Article Headers
Message-ID: <6l9rs9$sha@espresso.cafe.net> Subject: Re: How to tell trn to use only 20 lines for display? Date: Fri, 05 Jun 1998 00:00:00 +0000 From: kaz@cafe.net (Kaz Kylheku) References: <6l8t4a$bbq$1@xs2.xs4all.nl> <ulnrb64s5.fsf@xxx.yyy.zzz> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mail X-Deja-AN: 359970130 Sender: bill@espresso.cafe.net NNTP-Posting-Date: Fri, 05 Jun 1998 15:39:23 PDT Reply-To: kaz@cafe.net Organization: Internet Direct Newsgroups: news.software.readers