From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: zsh-workers-request@euclid.skiles.gatech.edu Received: from euclid.skiles.gatech.edu (list@euclid.skiles.gatech.edu [130.207.146.50]) by coral.primenet.com.au (8.7.5/8.7.3) with ESMTP id AAA23631 for ; Sat, 9 Nov 1996 00:26:39 +1100 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id IAA26699; Fri, 8 Nov 1996 08:19:07 -0500 (EST) Resent-Date: Fri, 8 Nov 1996 08:19:07 -0500 (EST) From: Zefram Message-Id: <7845.199611081318@stone.dcs.warwick.ac.uk> Subject: Re: zsh and xterm To: Pierpaolo.Righini@cern.ch (Pierpaolo Righini) Date: Fri, 8 Nov 1996 13:18:23 +0000 (GMT) Cc: zsh-workers@math.gatech.edu In-Reply-To: from "Pierpaolo Righini" at Nov 8, 96 12:08:46 pm X-Loop: zefram@dcs.warwick.ac.uk X-Stardate: [-31]8392.77 X-US-Congress: Moronic fuckers Content-Type: text Resent-Message-ID: <"pYocK.0.5X6.9DpWo"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/2337 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu >PS1="$(print "\033")]2;[ $_U ]%m: %/$(print "\007 \r")$PSB " > >and in fact this works for the title but then i have problems with the >muliline editing (it supposes to have written the title also after the >prompt and so the line is broken too early). Yes, you need to indicate to zsh that part of the prompt doesn't take up any space on the screen: PS1="%{$(print "\033")]2;[ $_U ]%m: %/$(print "\007 \r")%}$PSB " ^^ ^^ But in this case it would be better to use the chpwd feature: function chpwd { print -nP "\033]2;[ $_U ]%m: %/\007" } chpwd gets executed every time the current directory changes. Other things of this nature can be done using precmd, which is executed before the prompt is displayed. -zefram