To: vim-dev@vim.org Subject: Patch 6.1.343 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit ------------ Patch 6.1.343 (depends on 6.1.342) Problem: Cannot compile with the +multi_byte feature but without +rightleft. Cannot compile without the GUI. Solution: Fix the #ifdefs. (partly by Nam SungHyun) Files: src/gui.c, src/mbyte.c, src/ui.c *** ../vim61.342/src/gui.c Tue Feb 18 21:41:40 2003 --- src/gui.c Wed Feb 19 10:51:34 2003 *************** *** 948,954 **** } else { ! #ifdef FEAT_MBYTE int col_off = FALSE; #endif /* --- 949,955 ---- } else { ! #if defined(FEAT_MBYTE) && defined(FEAT_RIGHTLEFT) int col_off = FALSE; #endif /* *************** *** 973,978 **** --- 974,980 ---- /* Double wide character. */ if (shape_table[idx].shape != SHAPE_VER) cur_width += gui.char_width; + # ifdef FEAT_RIGHTLEFT if (!(State & CMDLINE) && curwin->w_p_rl) { /* gui.col points to the left halve of the character but *************** *** 982,991 **** col_off = TRUE; ++gui.col; } } #endif gui_mch_draw_part_cursor(cur_width, cur_height, cbg); ! #ifdef FEAT_MBYTE if (col_off) --gui.col; #endif --- 984,994 ---- col_off = TRUE; ++gui.col; } + # endif } #endif gui_mch_draw_part_cursor(cur_width, cur_height, cbg); ! #if defined(FEAT_MBYTE) && defined(FEAT_RIGHTLEFT) if (col_off) --gui.col; #endif *** ../vim61.342/src/mbyte.c Mon Feb 17 21:06:47 2003 --- src/mbyte.c Wed Feb 19 11:02:56 2003 *************** *** 1971,1977 **** return (q == p) ? 0 : 1; } ! #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) || defined(PROTO) /* * Special version of dbcs_head_off() that works for ScreenLines[], where * single-width DBCS_JPNU characters are stored separately. --- 1971,1978 ---- return (q == p) ? 0 : 1; } ! #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) || defined(FEAT_RIGHTLEFT) \ ! || defined(PROTO) /* * Special version of dbcs_head_off() that works for ScreenLines[], where * single-width DBCS_JPNU characters are stored separately. *************** *** 2276,2282 **** return NULL; } - #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) || defined(PROTO) /* * Return TRUE if the character at "row"/"col" on the screen is the left side * of a double-width character. --- 2277,2282 ---- *************** *** 2298,2304 **** && ScreenLines[LineOffset[row] + col + 1] == 0); return FALSE; } - #endif #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) || defined(FEAT_RIGHTLEFT) \ || defined(PROTO) --- 2298,2303 ---- *** ../vim61.342/src/ui.c Sun Feb 16 20:29:05 2003 --- src/ui.c Wed Feb 19 11:02:23 2003 *************** *** 1811,1817 **** } #endif ! #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) || defined(PROTO) /* * Check bounds for column number */ --- 1812,1819 ---- } #endif ! #if defined(FEAT_CLIPBOARD) || defined(FEAT_GUI) || defined(FEAT_RIGHTLEFT) \ ! || defined(PROTO) /* * Check bounds for column number */ *** ../vim61.342/src/version.c Tue Feb 18 21:41:40 2003 --- src/version.c Wed Feb 19 10:51:39 2003 *************** *** 608,609 **** --- 612,615 ---- { /* Add new patch number below this line */ + /**/ + 343, /**/ -- "Intelligence has much less practical application than you'd think." -- Scott Adams, Dilbert. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// Creator of Vim - Vi IMproved -- http://www.Vim.org \\\ \\\ Project leader for A-A-P -- http://www.A-A-P.org /// \\\ Help AIDS victims, buy at Amazon -- http://ICCF.nl/click1.html ///