Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!uunet!virtech!cpcahil From: cpcahil@virtech.UUCP (Conor P. Cahill) Newsgroups: comp.windows.x Subject: Re: how does xterm tell vi the window size Keywords: xterm vi Message-ID: <1227@virtech.UUCP> Date: 4 Oct 89 12:28:24 GMT References: <253@zeek.UUCP> Organization: Virtual Technologies Inc Lines: 32 In article <253@zeek.UUCP>, rick@zeek.UUCP (Rick Wilhelm) writes: > From an xterm, I logged on to a remote host and tried to vi a file. > vi thinks that the window is 24 lines deep. It has no idea that I have > extended the window to >30 lines. Depending upon what OS you are running you can set up the environment to specify the correct size of the window. For system V.3 you can use: LINES=xx COLUMNS=xx export LINES COLUMNS For bsd you need to use: (check the man page, I may not have the exact sequence since I no longer have access to a BSD system) stty rows xx columns xx On the local system this info is available via the resize command. On remote systems I handle this by a couple of prompts in my .profile. Since vi is a pre-X program, it has no built in mechanisms for determining the size of the window from X. You must specify the information in your environment. -- +-----------------------------------------------------------------------+ | Conor P. Cahill uunet!virtech!cpcahil 703-430-9247 ! | Virtual Technologies Inc., P. O. Box 876, Sterling, VA 22170 | +-----------------------------------------------------------------------+