To: vim_dev@googlegroups.com Subject: Patch 8.0.0986 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.0.0986 Problem: Terminal feature always requires multi-byte feature. Solution: Remove #ifdef FEAT_MBYTE, disable terminal without multi-byte. Files: src/terminal.c, src/feature.h *** ../vim-8.0.0985/src/terminal.c 2017-08-22 20:33:48.097449744 +0200 --- src/terminal.c 2017-08-22 22:13:31.324404632 +0200 *************** *** 63,69 **** * mouse in the Terminal window for copy/paste. * - when 'encoding' is not utf-8, or the job is using another encoding, setup * conversions. - * - update ":help function-list" for terminal functions. * - In the GUI use a terminal emulator for :!cmd. * - Copy text in the vterm to the Vim buffer once in a while, so that * completion works. --- 63,68 ---- *************** *** 2103,2116 **** if (c == NUL) { ScreenLines[off] = ' '; - #if defined(FEAT_MBYTE) if (enc_utf8) ScreenLinesUC[off] = NUL; - #endif } else { - #if defined(FEAT_MBYTE) if (enc_utf8) { if (c >= 0x80) --- 2102,2112 ---- *************** *** 2124,2130 **** ScreenLinesUC[off] = NUL; } } ! # ifdef WIN3264 else if (has_mbyte && c >= 0x80) { char_u mb[MB_MAXBYTES+1]; --- 2120,2126 ---- ScreenLinesUC[off] = NUL; } } ! #ifdef WIN3264 else if (has_mbyte && c >= 0x80) { char_u mb[MB_MAXBYTES+1]; *************** *** 2140,2148 **** else ScreenLines[off] = c; } - # endif - else #endif ScreenLines[off] = c; } ScreenAttrs[off] = cell2attr(cell.attrs, cell.fg, cell.bg); --- 2136,2143 ---- else ScreenLines[off] = c; } #endif + else ScreenLines[off] = c; } ScreenAttrs[off] = cell2attr(cell.attrs, cell.fg, cell.bg); *************** *** 2151,2161 **** ++off; if (cell.width == 2) { - #if defined(FEAT_MBYTE) if (enc_utf8) ScreenLinesUC[off] = NUL; else if (!has_mbyte) - #endif ScreenLines[off] = NUL; ++pos.col; ++off; --- 2146,2154 ---- *** ../vim-8.0.0985/src/feature.h 2017-08-12 19:51:37.815214191 +0200 --- src/feature.h 2017-08-22 22:16:24.603338446 +0200 *************** *** 1269,1276 **** /* * +terminal ":terminal" command. Runs a terminal in a window. */ ! #if !defined(FEAT_JOB_CHANNEL) && defined(FEAT_TERMINAL) # undef FEAT_TERMINAL #endif #if defined(FEAT_TERMINAL) && !defined(CURSOR_SHAPE) --- 1269,1278 ---- /* * +terminal ":terminal" command. Runs a terminal in a window. + * requires +channel and +multibyte */ ! #if defined(FEAT_TERMINAL) && \ ! !(defined(FEAT_JOB_CHANNEL) && defined(FEAT_MBYTE)) # undef FEAT_TERMINAL #endif #if defined(FEAT_TERMINAL) && !defined(CURSOR_SHAPE) *** ../vim-8.0.0985/src/version.c 2017-08-22 22:12:12.940882195 +0200 --- src/version.c 2017-08-22 22:17:15.127027462 +0200 *************** *** 771,772 **** --- 771,774 ---- { /* Add new patch number below this line */ + /**/ + 986, /**/ -- The average life of an organization chart is six months. You can safely ignore any order from your boss that would take six months to complete. (Scott Adams - The Dilbert principle) /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///