To: vim-dev@vim.org Subject: Patch 6.2.266 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.2.266 Problem: When redirecting output and using ":silent", line breaks are missing from output of ":map" and ":tselect". Alignment of columns is wrong. Solution: Insert a line break where "msg_didout" was tested. Update msg_col when redirecting and using ":silent". Files: src/getchar.c, src/message.c *** ../vim-6.2.265/src/getchar.c Sun Jan 25 20:30:03 2004 --- src/getchar.c Tue Feb 17 17:47:22 2004 *************** *** 3462,3468 **** { int len = 1; ! if (msg_didout) msg_putchar('\n'); if ((mp->m_mode & (INSERT + CMDLINE)) == INSERT + CMDLINE) msg_putchar('!'); /* :map! */ --- 3469,3475 ---- { int len = 1; ! if (msg_didout || msg_silent != 0) msg_putchar('\n'); if ((mp->m_mode & (INSERT + CMDLINE)) == INSERT + CMDLINE) msg_putchar('!'); /* :map! */ *** ../vim-6.2.265/src/message.c Sun Feb 8 17:09:51 2004 --- src/message.c Sun Feb 15 21:04:31 2004 *************** *** 468,473 **** --- 468,474 ---- */ if (emsg_silent != 0) { + msg_start(); redir_write(s, -1); return TRUE; } *************** *** 2477,2482 **** --- 2478,2486 ---- ++cur_col; ++s; } + + if (msg_silent != 0) /* should update msg_col */ + msg_col = cur_col; } } *************** *** 2522,2528 **** { if (msg_silent != 0) /* nothing to advance to */ { ! msg_putchar(' '); /* insert something for redirection */ return; } if (col >= Columns) /* not enough room */ --- 2526,2532 ---- { if (msg_silent != 0) /* nothing to advance to */ { ! msg_col = col; /* for redirection, may fill it up later */ return; } if (col >= Columns) /* not enough room */ *** ../vim-6.2.265/src/version.c Tue Feb 17 20:41:09 2004 --- src/version.c Tue Feb 17 20:42:45 2004 *************** *** 639,640 **** --- 639,642 ---- { /* Add new patch number below this line */ + /**/ + 266, /**/ -- hundred-and-one symptoms of being an internet addict: 169. You hire a housekeeper for your home page. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ Project leader for A-A-P -- http://www.A-A-P.org /// \\\ Help AIDS victims, buy here: http://ICCF-Holland.org/click1.html ///