Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
message 737 as context diff (zle_refresh)
- X-seq: zsh-workers 742
- From: Geoff Wing <mason@xxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxxx (zsh-list)
- Subject: message 737 as context diff (zle_refresh)
- Date: Tue, 16 Jan 1996 11:34:48 +1100 (EST)
Message 737 resent as a context diff.
*** zle_refresh.c.orig Fri Dec 22 09:44:43 1995
--- zle_refresh.c Tue Jan 16 01:26:36 1996
***************
*** 41,47 ****
/* Oct/Nov 94: <mason> some code savagely redesigned to fix several bugs -
refreshline() & tc_rightcurs() majorly rewritten; refresh() fixed -
I've put my fingers into just about every routine in here -
! any queries about updates to mason@xxxxxxxxxxxxxxxxxxx */
char **nbuf = NULL, /* new video buffer line-by-line char array */
**obuf = NULL; /* old video buffer line-by-line char array */
--- 41,47 ----
/* Oct/Nov 94: <mason> some code savagely redesigned to fix several bugs -
refreshline() & tc_rightcurs() majorly rewritten; refresh() fixed -
I've put my fingers into just about every routine in here -
! any queries about updates to mason@xxxxxxxxxxxxxxxxxx */
char **nbuf = NULL, /* new video buffer line-by-line char array */
**obuf = NULL; /* old video buffer line-by-line char array */
***************
*** 56,62 ****
winpos; /* singlelinezle: line's position in window */
static unsigned pmpt_attr = 0, /* text attributes after displaying prompt */
rpmpt_attr = 0; /* text attributes after displaying rprompt */
- static char am_char = ' '; /* first col char if needed for automargin */
/**/
void
--- 56,61 ----
***************
*** 103,109 ****
vcs = pptw;
olnct = nlnct = 0;
! if(showinglist > 0)
showinglist = -2;
}
--- 102,108 ----
vcs = pptw;
olnct = nlnct = 0;
! if (showinglist > 0)
showinglist = -2;
}
***************
*** 172,178 ****
* that was called from the end of refresh(), then we don't need to do *
* anything. All this `inlist' code is actually unnecessary, but it *
* improves speed a little in a common case. */
! if(inlist)
return;
#ifdef HAVE_SELECT
--- 171,177 ----
* that was called from the end of refresh(), then we don't need to do *
* anything. All this `inlist' code is actually unnecessary, but it *
* improves speed a little in a common case. */
! if (inlist)
return;
#ifdef HAVE_SELECT
***************
*** 407,419 ****
/* if we have a new list showing, note it; if part of the list has been
overwritten, redisplay it. */
! if(showinglist == -2 || (showinglist > 0 && showinglist < nlnct)) {
inlist = 1;
listmatches();
inlist = 0;
refresh();
}
! if(showinglist == -1)
showinglist = nlnct;
}
--- 406,418 ----
/* if we have a new list showing, note it; if part of the list has been
overwritten, redisplay it. */
! if (showinglist == -2 || (showinglist > 0 && showinglist < nlnct)) {
inlist = 1;
listmatches();
inlist = 0;
refresh();
}
! if (showinglist == -1)
showinglist = nlnct;
}
***************
*** 480,490 ****
col_cleareol = i;
}
! /* 3: set character for first column, in case automargin stuff needs doing:
! to begin with, this is the first char of the old screen line, if any. */
! am_char = *ol ? *ol : *nl;
!
! /* 4: main display loop - write out the buffer using whatever tricks we can */
for (;;) {
/* skip past all matching characters */
--- 479,485 ----
col_cleareol = i;
}
! /* 3: main display loop - write out the buffer using whatever tricks we can */
for (;;) {
/* skip past all matching characters */
***************
*** 494,500 ****
if ((char_ins <= 0) || (ccs >= winw)) /* written everything */
return;
else /* we've got junk on the right yet to clear */
! if (tccan(TCCLEAREOL) && (char_ins >= tclen[TCCLEAREOL]))
col_cleareol = 0; /* force a clear to end of line */
}
--- 489,496 ----
if ((char_ins <= 0) || (ccs >= winw)) /* written everything */
return;
else /* we've got junk on the right yet to clear */
! if (tccan(TCCLEAREOL) && (char_ins >= tclen[TCCLEAREOL]) &&
! (!hasam || ln == nlnct - 1))
col_cleareol = 0; /* force a clear to end of line */
}
***************
*** 602,614 ****
putc('\n', shout);
SELECT_ADD_COST(2);
} else {
! putc(am_char, shout);
tcout(TCLEFT);
SELECT_ADD_COST(1 + tclen[TCLEFT]);
}
vln++, vcs = 0;
}
- am_char = ' ';
/* move up */
if (ln < vln) {
--- 598,612 ----
putc('\n', shout);
SELECT_ADD_COST(2);
} else {
! if ((vln < nlnct - 1) && *nbuf[vln + 1])
! putc(*nbuf[vln + 1], shout);
! else
! putc(' ', shout);
tcout(TCLEFT);
SELECT_ADD_COST(1 + tclen[TCLEFT]);
}
vln++, vcs = 0;
}
/* move up */
if (ln < vln) {
--
Mason [G.C.W] mason@xxxxxxxxxxxxxxxxxx "Hurt...Agony...Pain...LOVE-IT"
Messages sorted by:
Reverse Date,
Date,
Thread,
Author