From 77b96094f0ece31a76a20f46c174145fa18a5ed2 Mon Sep 17 00:00:00 2001 From: Bjorn Winckler Date: Tue, 10 May 2011 13:11:31 +0200 Subject: [PATCH] Fix cursor drawing issue with 'rl' enabled --- src/MacVim/gui_macvim.m | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/src/MacVim/gui_macvim.m b/src/MacVim/gui_macvim.m index 904dc7aa6d..440fca6f54 100644 --- a/src/MacVim/gui_macvim.m +++ b/src/MacVim/gui_macvim.m @@ -1155,13 +1155,6 @@ gui_mch_draw_part_cursor(int w, int h, guicolor_T color) // the shape_table to determine the shape and size of the cursor (just like // gui_update_cursor() does). -#ifdef FEAT_RIGHTLEFT - // If 'rl' is set the insert mode cursor must be drawn on the right-hand - // side of a text cell. - int rl = curwin ? curwin->w_p_rl : FALSE; -#else - int rl = FALSE; -#endif int idx = get_shape_idx(FALSE); int shape = MMInsertionPointBlock; switch (shape_table[idx].shape) { @@ -1169,8 +1162,13 @@ gui_mch_draw_part_cursor(int w, int h, guicolor_T color) shape = MMInsertionPointHorizontal; break; case SHAPE_VER: - shape = rl ? MMInsertionPointVerticalRight - : MMInsertionPointVertical; + shape = +#ifdef FEAT_RIGHTLEFT + // If 'rl' is set the insert mode cursor may be drawn on + // the right-hand side of a text cell. + CURSOR_BAR_RIGHT ? MMInsertionPointVerticalRight : +#endif + MMInsertionPointVertical; break; }