summary |
tags |
clone url |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
c3a7432)
SCCS-vsn: usr.bin/more/screen.c 5.5
-static char sccsid[] = "@(#)screen.c 5.4 (Berkeley) %G%";
+static char sccsid[] = "@(#)screen.c 5.5 (Berkeley) %G%";
-static
-cannot(s)
- char *s;
-{
- char message[100];
-
- (void)sprintf(message, "WARNING: terminal cannot \"%s\"", s);
- error(message);
-}
-
/*
* Get terminal capabilities via termcap.
*/
/*
* Get terminal capabilities via termcap.
*/
sc_eol_clear = tgetstr("ce", &sp);
if (hard || sc_eol_clear == NULL || *sc_eol_clear == '\0')
{
sc_eol_clear = tgetstr("ce", &sp);
if (hard || sc_eol_clear == NULL || *sc_eol_clear == '\0')
{
- cannot("clear to end of line");
sc_eol_clear = "";
}
sc_clear = tgetstr("cl", &sp);
if (hard || sc_clear == NULL || *sc_clear == '\0')
{
sc_eol_clear = "";
}
sc_clear = tgetstr("cl", &sp);
if (hard || sc_clear == NULL || *sc_clear == '\0')
{
- cannot("clear screen");
{
if (*sc_move == '\0')
{
{
if (*sc_move == '\0')
{
/*
* This last resort for sc_home is supposed to
* be an up-arrow suggesting moving to the
/*
* This last resort for sc_home is supposed to
* be an up-arrow suggesting moving to the
* your imagination as you try to use this on
* a hard copy terminal.)
*/
* your imagination as you try to use this on
* a hard copy terminal.)
*/
{
if (*sc_move == '\0')
{
{
if (*sc_move == '\0')
{
- cannot("move cursor to lower left of screen");
sc_lower_left = "\r";
} else
{
sc_lower_left = "\r";
} else
{
if (hard || sc_addline == NULL || *sc_addline == '\0')
{
if (hard || sc_addline == NULL || *sc_addline == '\0')
{
- cannot("scroll backwards");
sc_addline = "";
/* Force repaint on any backward movement */
back_scroll = 0;
sc_addline = "";
/* Force repaint on any backward movement */
back_scroll = 0;