zsh-workers
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: "Zsh Hackers' List" <zsh-workers@zsh.org>
Subject: Re: Prompt redrawing issues with wrapped prompt on SIGWINCH
Date: Sat, 18 Apr 2015 10:21:38 -0700	[thread overview]
Message-ID: <150418102138.ZM12808@torch.brasslantern.com> (raw)
In-Reply-To: <55328E8D.8000502@thequod.de>

On Apr 18,  7:04pm, Daniel Hahler wrote:
}
} Some remarks: it does not only affect urxvt, but also gnome-terminal.
} So it's likely to be a common issue with all terminals?!

Doesn't happen to me with xterm, but it sends multiple SIGWINCH rather
than wait for the final size of the window.

} Could this be addressed by e.g. having the terminal notify zsh about
} SIGWINCH before reflowing/rewrapping the text, or something similar?

Signals are asynchronous at the OS level so the emulator can't control
whether the shell has as chance to respond to the signal before it
redraws the text.  In any case this would require reprogramming the
emulator, so is out of our hands.

} > PS1=$'${(pl:COLUMNS-1::=:)}\n %# '
} 
} This suggested workaround only helps if you resize the window by one
} column, e.g. when using the mouse. But modkey-h/l in awesome changes
} the master-window-factor by a percent of the screen size.

The suggested workaround was successful for me when using mouse-drag to
resize the window, despite urxvt sending only a single SIGWINCH when the
mouse was released, which should be analogous to having the window manager
trigger a proportional resize.  What version of zsh do you have?


  reply	other threads:[~2015-04-18 17:21 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-17 22:56 Daniel Hahler
2015-04-18  3:43 ` Mikael Magnusson
2015-04-18 15:57   ` Bart Schaefer
2015-04-18 17:04     ` Daniel Hahler
2015-04-18 17:21       ` Bart Schaefer [this message]
2015-04-18 21:30         ` Daniel Hahler
2015-04-18 23:00           ` Bart Schaefer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=150418102138.ZM12808@torch.brasslantern.com \
    --to=schaefer@brasslantern.com \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).