Newsgroups: comp.sys.amiga.misc Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!batcomputer!cornell!johnhlee From: johnhlee@CS.Cornell.EDU (John H. Lee) Subject: Re: lines per screen in Handshake Message-ID: <1991May15.210626.17108@cs.cornell.edu> Sender: news@cs.cornell.edu (USENET news user) Nntp-Posting-Host: hermod.cs.cornell.edu Reply-To: johnhlee@cs.cornell.edu (John H. Lee) Organization: Cornell Univ. CS Dept, Ithaca NY 14853 References: <1991May14.223503.24260@cadence.com> Distribution: na Date: Wed, 15 May 1991 21:06:26 GMT Lines: 74 In article <1991May14.223503.24260@cadence.com> atul@cadence.com (Atul Srinivasan) writes: >Uhm.. silly question, but when using Handshake in vt52 emulation >mode, with 48 lines per screen, I can't seem to to set the >page size to double what it is in lo res mode. That is to >say, I am logging in to a unix machine, and when I use utilities >like more/vi they recognize the page size correctly as 24 lines. >If I switch to 48 lines per screen, more still halts pages every >24 lines. Same for vi. Is there a way to control this from >Handshake ? > >Please email, as I am sure absolutely noone else would ever want >to know this. Well, I decided to post this since this is probably close to #1 on the List of Commonly Asked Questions that I get. My answer will be relevant only for BSD-derived systems (i.e., BSD or SUN OS) since I have little to no experience with System-V or POSIX tty drivers. If you're using a recent flavor of BSD Unix (4.3'ish), you may be able set the number of rows and columns the system thinks your terminal has with the "stty" command and the "rows" and "columns" attributes. For instance: % stty rows 48 for a 48-line terminal. Another example: % stty rows 48 columns 132 for a 48-line, 132-column terminal. From this point on, "vi" and "more" will think your terminal has 48-lines. If you're not so lucky, you'll have to set your environment variable, TERMCAP, to reflect the size of your terminal. Xterm users use the program "resize" to do this, but since you're on a real terminal, you'll have to do this manually. (Aside: Why in the world are you using VT52 emulation? VT100 is much better.) You'll need to change the fields "li#" and "co#" to the number of lines and columns of your terminal, respectively. One way to do this is to copy the vt52 entry from /etc/termcap and put it into some file called, say, termcap.vt52 in your home directory. Edit this file and change the name 'vt52' on the first line to 'vt52-48', and change the "li#" and "co#" entries. Oh heck, I'll just include the contents of termcap.vt52: dw|vt52-48|dec vt52 with 48 lines:\ :do=^J:le=^H:bs:cd=\EJ:ce=\EK:cl=\EH\EJ:cm=\EY%+ %+ :co#80:li#48:\ :nd=\EC:pt:sr=\EI:up=\EA:ku=\EA:kd=\EB:kr=\EC:kl=\ED:kb=^H: Now to get the system to use this entry instead, from csh do this: % setenv TERMCAP $HOME/termcap.vt52 # Full pathname of file % set noglob; eval `tset -s vt52-48` From sh, do this: $ export TERMCAP $ TERMCAP=$HOME/termcap.vt52 $ eval `tset -s vt52-48` Note the back-single-quotes used for the "eval" command. You'll probably want to put this into a script file or your .login (or .profile if you're using the Bourne shell.) Finally, set Handshake to 48-line mode. If you're already in 48-line mode, the terminal's scrolling region may still be set for 24 lines. Just select 24-line mode and then back to 48-lines from Handshake's menus to reset the scrolling region. vi and more should now be using all 48-lines! Now wasn't that easy? :-) ------------------------------------------------------------------------------- The DiskDoctor threatens the crew! Next time on AmigaDos: The Next Generation. John Lee Internet: johnhlee@cs.cornell.edu The above opinions are those of the user, and not of this machine.