To: vim_dev@googlegroups.com
Subject: Patch 7.3.799
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------

Patch 7.3.799
Problem:    The color column is not correct when entering a buffer. (Ben
	    Fritz)
Solution:   Call check_colorcolumn() if 'textwidth' changed. (Christian
	    Brabandt)
Files:	    src/buffer.c


*** ../vim-7.3.798/src/buffer.c	2012-11-20 12:16:54.000000000 +0100
--- src/buffer.c	2013-02-06 11:52:54.000000000 +0100
***************
*** 1441,1446 ****
--- 1441,1448 ----
  enter_buffer(buf)
      buf_T	*buf;
  {
+     long old_tw = curbuf->b_p_tw;
+ 
      /* Copy buffer and window local option values.  Not for a help buffer. */
      buf_copy_options(buf, BCO_ENTER | BCO_NOHELP);
      if (!buf->b_help)
***************
*** 1464,1469 ****
--- 1466,1473 ----
  
  #ifdef FEAT_SYN_HL
      curwin->w_s = &(buf->b_s);
+     if (old_tw != buf->b_p_tw)
+ 	check_colorcolumn(curwin);
  #endif
  
      /* Cursor on first line by default. */
*** ../vim-7.3.798/src/version.c	2013-01-31 21:09:10.000000000 +0100
--- src/version.c	2013-02-06 11:55:06.000000000 +0100
***************
*** 727,728 ****
--- 727,730 ----
  {   /* Add new patch number below this line */
+ /**/
+     799,
  /**/

-- 
I wonder, do vegetarians eat fruit bats?

 /// 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    ///
