zsh-workers
 help / color / mirror / code / Atom feed
* [4.3 CVS] funny output with multibyte
@ 2006-02-02  9:08 François-Xavier Coudert
  2006-02-02  9:33 ` Jean Chalard
  0 siblings, 1 reply; 6+ messages in thread
From: François-Xavier Coudert @ 2006-02-02  9:08 UTC (permalink / raw)
  To: zsh-workers

Hello,

I have been using the 4.3 devel branch (2006-01-21) for two weeks now
and find it quite stable and behaving nicely. Thanks for all the hard
work on multibyte!

There is one minor glitch I noticed. Here is how to reproduce it:

  1. Enter a command that will not return immediately (e.g. "sleep 10")
  2. Enter a few keystrokes before it returns, so that the screen is now

pc31 ~ $ sleep 10
azerty

  3. When the function returns, the screen turns into :

pc31 ~ $ sleep 10
azerty%
pc31 ~ $ azerty

Please note that the percent sign (%) is followed by spaces up to the
end of the line, and that there is no newline after that.

While it's not a major problem, I found that amazing. Bug or feature?

Thanks,
FX


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [4.3 CVS] funny output with multibyte
  2006-02-02  9:08 [4.3 CVS] funny output with multibyte François-Xavier Coudert
@ 2006-02-02  9:33 ` Jean Chalard
  2006-02-02 12:41   ` Zvi Har'El
  0 siblings, 1 reply; 6+ messages in thread
From: Jean Chalard @ 2006-02-02  9:33 UTC (permalink / raw)
  To: François-Xavier Coudert; +Cc: zsh-workers

>   3. When the function returns, the screen turns into :
>
> pc31 ~ $ sleep 10
> azerty%
> pc31 ~ $ azerty
>
> Please note that the percent sign (%) is followed by spaces up to the
> end of the line, and that there is no newline after that.
>
> While it's not a major problem, I found that amazing. Bug or feature?

I think you are experiencing the effects of the new PROMPT_SPACES
option, which is the new solution to the NO_PROMPT_CR debate that has
been around for quite a time.
IIRC, by default zsh now print spaces that fill the terminal width and
then prints a CR. If nothing had been printed before, the last space
is on the last column but the cursor is still on the same line so the
CR makes it return at the beginning of the line so that you won't see
an empty line. If something had been printed on the line before, then
the cursor is going to be on the next line, so that your prompt won't
be printed over previous data that was not followed by a NL.

This ought to end the debate about PROMPT_CR :)

--
J
"Toi, je te trouve pas la même tête que sur la page précédente" -- Wakamiya

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [4.3 CVS] funny output with multibyte
  2006-02-02  9:33 ` Jean Chalard
@ 2006-02-02 12:41   ` Zvi Har'El
  2006-02-02 14:23     ` Vincent Lefevre
  2006-02-02 15:58     ` Bart Schaefer
  0 siblings, 2 replies; 6+ messages in thread
From: Zvi Har'El @ 2006-02-02 12:41 UTC (permalink / raw)
  To: Jean Chalard; +Cc: Zsh hackers list

[-- Attachment #1: Type: text/plain, Size: 1607 bytes --]

The explanation explains everything, except the percent sign. BTW, In my 
case, I see a reverse-video percent sign printed. What does it mean?

Jean Chalard wrote, On 02/02/2006 11:33 AM:

>>   3. When the function returns, the screen turns into :>> pc31 ~ $ sleep 10> azerty%> pc31 ~ $ azerty>> Please note that the percent sign (%) is followed by spaces up to the> end of the line, and that there is no newline after that.>> While it's not a major problem, I found that amazing. Bug or feature?
>>     
> I think you are experiencing the effects of the new PROMPT_SPACESoption, which is the new solution to the NO_PROMPT_CR debate that hasbeen around for quite a time.IIRC, by default zsh now print spaces that fill the terminal width andthen prints a CR. If nothing had been printed before, the last spaceis on the last column but the cursor is still on the same line so theCR makes it return at the beginning of the line so that you won't seean empty line. If something had been printed on the line before, thenthe cursor is going to be on the next line, so that your prompt won'tbe printed over previous data that was not followed by a NL.
> This ought to end the debate about PROMPT_CR :)
> --J"Toi, je te trouve pas la même tête que sur la page précédente" -- Wakamiya
>   

-- 
Dr. Zvi Har'El      mailto:rl@math.technion.ac.il    Department of Mathematics
tel:+972-54-4227607 icq:179294841    Technion - Israel Institute of Technology
fax:+972-4-8293388  http://www.math.technion.ac.il/~rl/    Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)


[-- Attachment #2: Type: text/html, Size: 2328 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [4.3 CVS] funny output with multibyte
  2006-02-02 12:41   ` Zvi Har'El
@ 2006-02-02 14:23     ` Vincent Lefevre
  2006-02-02 15:58     ` Bart Schaefer
  1 sibling, 0 replies; 6+ messages in thread
From: Vincent Lefevre @ 2006-02-02 14:23 UTC (permalink / raw)
  To: Zsh hackers list

On 2006-02-02 14:41:00 +0200, Zvi Har'El wrote:
> The explanation explains everything, except the percent sign. BTW, In my 
> case, I see a reverse-video percent sign printed. What does it mean?

AFAIK, it is printed when zsh added a newline.

-- 
Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/>
100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/>
Work: CR INRIA - computer arithmetic / SPACES project at LORIA


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [4.3 CVS] funny output with multibyte
  2006-02-02 12:41   ` Zvi Har'El
  2006-02-02 14:23     ` Vincent Lefevre
@ 2006-02-02 15:58     ` Bart Schaefer
  2006-02-02 16:27       ` Zvi Har'El
  1 sibling, 1 reply; 6+ messages in thread
From: Bart Schaefer @ 2006-02-02 15:58 UTC (permalink / raw)
  To: Zsh hackers list

On Feb 2,  2:41pm, Zvi Har'El wrote:
}
} The explanation explains everything, except the percent sign. BTW,
} In my case, I see a reverse-video percent sign printed. What does it
} mean?

It means "this was the end of the output before the prompt was printed."
It's so that you can tell it was the shell that took over at that point,
rather than that some other process output something it wasn't meant to.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [4.3 CVS] funny output with multibyte
  2006-02-02 15:58     ` Bart Schaefer
@ 2006-02-02 16:27       ` Zvi Har'El
  0 siblings, 0 replies; 6+ messages in thread
From: Zvi Har'El @ 2006-02-02 16:27 UTC (permalink / raw)
  To: Bart Schaefer; +Cc: Zsh hackers list

[-- Attachment #1: Type: text/plain, Size: 833 bytes --]

Thanks. This makes a lot of sense.

Bart Schaefer wrote, On 02/02/2006 05:58 PM:

> On Feb 2,  2:41pm, Zvi Har'El wrote:
> }
> } The explanation explains everything, except the percent sign. BTW,
> } In my case, I see a reverse-video percent sign printed. What does it
> } mean?
>
> It means "this was the end of the output before the prompt was printed."
> It's so that you can tell it was the shell that took over at that point,
> rather than that some other process output something it wasn't meant to.
>   

-- 
Dr. Zvi Har'El      mailto:rl@math.technion.ac.il    Department of Mathematics
tel:+972-54-4227607 icq:179294841    Technion - Israel Institute of Technology
fax:+972-4-8293388  http://www.math.technion.ac.il/~rl/    Haifa 32000, ISRAEL
"If you can't say somethin' nice, don't say nothin' at all." -- Thumper (1942)


[-- Attachment #2: Type: text/html, Size: 1422 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2006-02-02 16:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-02-02  9:08 [4.3 CVS] funny output with multibyte François-Xavier Coudert
2006-02-02  9:33 ` Jean Chalard
2006-02-02 12:41   ` Zvi Har'El
2006-02-02 14:23     ` Vincent Lefevre
2006-02-02 15:58     ` Bart Schaefer
2006-02-02 16:27       ` Zvi Har'El

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).