zsh-workers
 help / color / mirror / code / Atom feed
* Re: xterm cur&paste
       [not found] <199608301622.SAA01835@bolyai.cs.elte.hu>
@ 1996-08-31  5:42 ` Geoff Wing
  0 siblings, 0 replies; only message in thread
From: Geoff Wing @ 1996-08-31  5:42 UTC (permalink / raw)
  To: Zoltan Hidvegi; +Cc: zsh-workers

Zoltan Hidvegi wrote:
:> But don't expect a patch before next Tuesday/Wednesday.

Of course, it could be earlier.
This should change it so CLEAREOL and new lines don't get used too early if
the line extends the whole way, but can be used if it doesn't.
This should fix up the multiline cut & paste, without affecting normal long
lines.


*** zle_refresh.c	1996/08/12 01:39:05	2.13
--- zle_refresh.c	1996/08/30 15:58:02
***************
*** 490,500 ****
  	char_ins = 0,		/* number of characters inserted/deleted */
  	col_cleareol,		/* clear to end-of-line from this column */
  	i, j,			/* tmp					 */
! 	nllen, ollen;		/* new and old line buffer lengths	 */
  
  /* 0: setup */
      nl = nbuf[ln];
!     nllen = nl ? strlen(nl) : 0;
      ol = obuf[ln] ? obuf[ln] : "";
      ollen = strlen(ol);
  
--- 490,501 ----
  	char_ins = 0,		/* number of characters inserted/deleted */
  	col_cleareol,		/* clear to end-of-line from this column */
  	i, j,			/* tmp					 */
! 	nllen, ollen,		/* new and old line buffer lengths	 */
! 	rnllen;			/* real new line buffer length		 */
  
  /* 0: setup */
      nl = nbuf[ln];
!     rnllen = nllen = nl ? strlen(nl) : 0;
      ol = obuf[ln] ? obuf[ln] : "";
      ollen = strlen(ol);
  
***************
*** 528,534 ****
     With automatic margins, we shouldn't do it if there is another line, in
     case it messes up cut and paste. */
  
!     if (hasam && ln < nlnct - 1)
  	col_cleareol = -2;	/* clearing eol would be evil so don't */
      else {
  	col_cleareol = -1;
--- 529,535 ----
     With automatic margins, we shouldn't do it if there is another line, in
     case it messes up cut and paste. */
  
!     if (hasam && ln < nlnct - 1 && rnllen == winw)
  	col_cleareol = -2;	/* clearing eol would be evil so don't */
      else {
  	col_cleareol = -1;


-- 
Geoff Wing [mason@primenet.com.au]   PrimeNet - Internet Consultancy
  Web: http://www.primenet.com.au/   Facsimile: +61-3-9819 3788


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1996-08-31  5:53 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <199608301622.SAA01835@bolyai.cs.elte.hu>
1996-08-31  5:42 ` xterm cur&paste Geoff Wing

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).