To: vim_dev@googlegroups.com
Subject: Patch 7.4.042
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.4.042
Problem: When using ":setlocal" for 'spell' and 'spellang' then :spelldump
doesn't work. (Dimitar Dimitrov)
Solution: Copy the option variables to the new window used to show the dump.
(Christian Brabandt)
Files: src/spell.c
*** ../vim-7.4.041/src/spell.c 2013-09-25 18:54:20.000000000 +0200
--- src/spell.c 2013-09-29 13:15:51.000000000 +0200
***************
*** 15569,15579 ****
ex_spelldump(eap)
exarg_T *eap;
{
if (no_spell_checking(curwin))
return;
! /* Create a new empty buffer by splitting the window. */
do_cmdline_cmd((char_u *)"new");
if (!bufempty() || !buf_valid(curbuf))
return;
--- 15569,15589 ----
ex_spelldump(eap)
exarg_T *eap;
{
+ char_u *spl;
+ long dummy;
+
if (no_spell_checking(curwin))
return;
+ get_option_value((char_u*)"spl", &dummy, &spl, OPT_LOCAL);
! /* Create a new empty buffer in a new window. */
do_cmdline_cmd((char_u *)"new");
+
+ /* enable spelling locally in the new window */
+ set_option_value((char_u*)"spell", TRUE, (char_u*)"", OPT_LOCAL);
+ set_option_value((char_u*)"spl", dummy, spl, OPT_LOCAL);
+ vim_free(spl);
+
if (!bufempty() || !buf_valid(curbuf))
return;
*** ../vim-7.4.041/src/version.c 2013-09-25 23:24:54.000000000 +0200
--- src/version.c 2013-09-29 13:15:17.000000000 +0200
***************
*** 740,741 ****
--- 740,743 ----
{ /* Add new patch number below this line */
+ /**/
+ 42,
/**/
--
Experience is what you get when you don't get what you want.
/// 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 ///