=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/screen-write.c,v retrieving revision 1.47 retrieving revision 1.48 diff -c -r1.47 -r1.48 *** src/usr.bin/tmux/screen-write.c 2011/03/07 23:46:27 1.47 --- src/usr.bin/tmux/screen-write.c 2011/03/26 19:07:33 1.48 *************** *** 1,4 **** ! /* $OpenBSD: screen-write.c,v 1.47 2011/03/07 23:46:27 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott --- 1,4 ---- ! /* $OpenBSD: screen-write.c,v 1.48 2011/03/26 19:07:33 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott *************** *** 1012,1019 **** * If this is a wide character and there is no room on the screen, for * the entire character, don't print it. */ ! if (width > 1 && (width > screen_size_x(s) || ! (s->cx != screen_size_x(s) && s->cx > screen_size_x(s) - width))) return; /* --- 1012,1021 ---- * If this is a wide character and there is no room on the screen, for * the entire character, don't print it. */ ! if (!(s->mode & MODE_WRAP) ! && (width > 1 && (width > screen_size_x(s) || ! (s->cx != screen_size_x(s) ! && s->cx > screen_size_x(s) - width)))) return; /* *************** *** 1045,1052 **** } /* Sanity checks. */ ! if (((s->mode & MODE_WRAP) && s->cx > screen_size_x(s) - 1) ! || s->cy > screen_size_y(s) - 1) return; /* Handle overwriting of UTF-8 characters. */ --- 1047,1054 ---- } /* Sanity checks. */ ! if (((s->mode & MODE_WRAP) && s->cx > screen_size_x(s) - width) ! || s->cy > screen_size_y(s) - width) return; /* Handle overwriting of UTF-8 characters. */