On Mi, 25 Jun 2014, itchyny wrote:

> To reproduce
> vim -u NONE -N
> 500ia<ESC>^
> >>
> set wrap breakindent
> set breakindentopt=shift:10
> hlhlhlwbwb
> x
> 
> Problem
> The indentation is not updated soon after we change breakindentopt.
> 
> Expected behaviour
> The indentation is updated soon.

Yes, I noticed that too.

diff --git a/src/misc1.c b/src/misc1.c
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -513,11 +513,11 @@ get_breakindent_win(wp, line)
        prev_ts = wp->w_buffer->b_p_ts;
        prev_tick = wp->w_buffer->b_changedtick;
        prev_indent = get_indent_str(line,
-                 (int)wp->w_buffer->b_p_ts, wp->w_p_list) + wp->w_p_brishift;
-    }
-
+                 (int)wp->w_buffer->b_p_ts, wp->w_p_list);
+    }
+
+    bri = prev_indent + wp->w_p_brishift;
     /* indent minus the length of the showbreak string */
-    bri = prev_indent;
     if (wp->w_p_brisbr)
        bri -= vim_strsize(p_sbr);


Best,
Christian
-- 
Der Ungläubige glaubt mehr, als er meint,
der Gläub'ge weniger, als ihm scheint.
                -- Franz Grillparzer (Glaube)

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui