---
** [tickets:#202] Bug with resizing panes in tmux when using ZSH**
**Status:** open
**Created:** Tue Jun 02, 2015 02:42 PM UTC by Sam Perry
**Last Updated:** Tue Jun 02, 2015 02:42 PM UTC
**Owner:** nobody
I am using Tmux with ZSH and have a problem when trying to resize panels.
I am currently using these bindings to resize panels as I work:
unbind-key M-j ; bind-key -n M-j resize-pane -D 1
unbind-key M-k ; bind-key -n M-k resize-pane -U 1
unbind-key M-h ; bind-key -n M-h resize-pane -L 1
unbind-key M-l ; bind-key -n M-l resize-pane -R 1
For example: I have two panels, one on top of the other and both displaying a
ZSH prompt. The top panel has run the following commands:
perry@touriste-147-12:~% echo hello
hello
perry@touriste-147-12:~% echo goodbye
goodbye
perry@touriste-147-12:~% _
When vertically resizing the bottom panel to make it smaller the top panel will
be enlarged to compensate as expected but the following is added to the screen:
perry@touriste-147-12:~% <<<
perry@touriste-147-12:~% <<< THIS IS ALL NEW AND NOT CREATED
perry@touriste-147-12:~% <<< BY ME
perry@touriste-147-12:~% echo hello <<<
perry@touriste-147-12:~% echo hello
hello
samperry@touriste-147-12:~% echo goodbye
goodbye
perry@touriste-147-12:~% _
Then if I resize the bottom panel back the same happens to the bottom, with the
prompt staying at the position where it had been shrunk to like this:
From:
perry@touriste-147-12:~% _
To:
perry@touriste-147-12:~%
perry@touriste-147-12:~%
perry@touriste-147-12:~%
perry@touriste-147-12:~%
perry@touriste-147-12:~%
perry@touriste-147-12:~%
perry@touriste-147-12:~%
perry@touriste-147-12:~% _
This does not occur when resizing the window using iTerm without tmux. The zsh
shell displays properly in iTerm
The same is true of Terminal
This also does not occur when using bash in tmux with the same settings
So far I have tried:
- Adding <code>export LANG=en_GB.UTF-8</code> to my .zshrc
- Setting <code>export TERM="xterm-256color"</code> and <code>export
TERM="screen-256color"</code> in my .zshrc
- Using the same for <code>set -g default-terminal "xterm-256color"</code>
Sadly, none of this has solved my problem.
>From posting this here:
>http://superuser.com/questions/918182/bug-with-resizing-panes-in-tmux-when-using-zsh
the following comment goes some way to fixing the problem: "I haven't found a
solution either, but I worked around the bug by adding if [[ ! -z $TMUX ]];
then printf '\n'; fi to my .zshrc" though I thought it would be worth bringing
to your attention regardless.
---
Sent from sourceforge.net because tmux-users@lists.sourceforge.net is
subscribed to https://sourceforge.net/p/tmux/tickets/
To unsubscribe from further messages, a project admin can change settings at
https://sourceforge.net/p/tmux/admin/tickets/options. Or, if this is a mailing
list, you can unsubscribe from the mailing list.
------------------------------------------------------------------------------
_______________________________________________
tmux-users mailing list
tmux-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/tmux-users