Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-06 Fir de Conversatie Coacher
CC'ing tex indent maintainer as it appears to be a tex-specific problem.

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-04 Fir de Conversatie Coacher
On Friday, 4 November 2016 22:33:42 UTC+3, DrChip  wrote:
> Coacher wrote:
> > On Friday, 4 November 2016 14:36:12 UTC+3, Antony Scriven  wrote:
> >> That's because 'o' in 'indentkeys' is causing new lines to be
> >> indented according to 'indentexpr'.
> > Indeed, after 'set indentkeys-=o' gqgq works as expected in the case 
> > described above.
> > gqgq works as expected in non-tex files even with the default 'indentkeys' 
> > setting, which includes 'o'.
> >
> So, to find out where it was last changed (if at all):  verbose set
> indentkeys?

  indentkeys=0{,0},:,0#,!^F,o,O,e,[,(,{,),},],&,=\bibitem,=\item
Last set from /usr/share/vim/vim80/indent/tex.vim

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-04 Fir de Conversatie Coacher
On Friday, 4 November 2016 22:30:29 UTC+3, DrChip  wrote:
> Your example has  "filetype plugin indent on" -- that means that you
> have plugins enabled, and anything in ~/.vim/plugin has been loaded (ie.
> sourced).  Ditto for indent plugins.

Neither ~/.vim/plugin, nor ~/.vim/indent exists.

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-04 Fir de Conversatie Charles E Campbell
Coacher wrote:
> On Friday, 4 November 2016 14:36:12 UTC+3, Antony Scriven  wrote:
>> That's because 'o' in 'indentkeys' is causing new lines to be
>> indented according to 'indentexpr'.
> Indeed, after 'set indentkeys-=o' gqgq works as expected in the case 
> described above.
> gqgq works as expected in non-tex files even with the default 'indentkeys' 
> setting, which includes 'o'.
>
So, to find out where it was last changed (if at all):  verbose set
indentkeys?

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-04 Fir de Conversatie Charles E Campbell
Coacher wrote:
> On Wednesday, 2 November 2016 23:50:57 UTC+3, DrChip  wrote:
>> Using 8.0.055, I get your expected results.  So, I suggest that you
>> check your plugins.
> AFAIU since I have '-u NONE' in cmdline, only system-wide plugins are 
> possibly in effect and I don't have any, except for plugin manager itself. 
> Since ~/.vimrc isn't processed, plugin manager is never activated. Please 
> correct me if I am wrong, but I don't see how my plugins can change anything 
> here.
>
>
Your example has  "filetype plugin indent on" -- that means that you
have plugins enabled, and anything in ~/.vim/plugin has been loaded (ie.
sourced).  Ditto for indent plugins.

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-04 Fir de Conversatie Coacher
On Friday, 4 November 2016 14:36:12 UTC+3, Antony Scriven  wrote:
> That's because 'o' in 'indentkeys' is causing new lines to be
> indented according to 'indentexpr'.

Indeed, after 'set indentkeys-=o' gqgq works as expected in the case described 
above.
gqgq works as expected in non-tex files even with the default 'indentkeys' 
setting, which includes 'o'.

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-04 Fir de Conversatie Antony Scriven
On 2 November 2016 at 16:51, Coacher wrote:

 > [...] Consider the following file:
 >
 > \begin{env}
 > 
x

x
 > \end{env}
 >
 > Open it like this: vim -N -u NONE -c 'filetype plugin indent on' -c
'set ft=tex' 
 > Place the cursor at the beginning of the second line.
 > In Normal mode type 'gqgq' to format it.
 >
 > Actual results:
 >
 > \begin{env}
 >  x
 > 
 > x
 > \end{env}
 > Expected results:
 >
 > \begin{env}
 >  x
 >  x
 > \end{env}
 >
 > [...]

That's because 'o' in 'indentkeys' is causing new lines to be
indented according to 'indentexpr'. If you hit '==' to indent before
reflowing the second line, you get:

\begin{env}

x

x
\end{env}

This seems reasonable to me. --Antony

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-04 Fir de Conversatie Coacher
On Wednesday, 2 November 2016 23:50:57 UTC+3, DrChip  wrote:
> Using 8.0.055, I get your expected results.  So, I suggest that you
> check your plugins.

AFAIU since I have '-u NONE' in cmdline, only system-wide plugins are possibly 
in effect and I don't have any, except for plugin manager itself. Since 
~/.vimrc isn't processed, plugin manager is never activated. Please correct me 
if I am wrong, but I don't see how my plugins can change anything here.

> 
> Regards,
> Chip Campbell

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-03 Fir de Conversatie Charles E Campbell
Gary Johnson wrote:
> On 2016-11-02, Charles E Campbell wrote:
>> Coacher wrote:
>>> Consider the following file:
>>>
>>> \begin{env}
>>>  x 
>>>  x
>>> \end{env}
>>>
>>> Open it like this: vim -N -u NONE -c 'filetype plugin indent on' -c 'set ft=
>>> tex' 
>>> Place the cursor at the beginning of the second line.
>>> In Normal mode type 'gqgq' to format it.
>>>
>>> Actual results:
>>>
>>> \begin{env}
>>>  x
>>> 
>>> x
>>> \end{env}
>>>
>>> Expected results:
>>>
>>> \begin{env}
>>>  x
>>>  x
>>> \end{env}
>>>
>>> vim version is 8.0.0055.
>> Using 8.0.055, I get your expected results.  So, I suggest that you
>> check your plugins.
> With my normal setup, I get his expected results, too, but if I
> start Vim with the command shown, I get his actual results.
>
> I'd contact the maintainer of $VIMRUNTIME/indent/tex.vim, whose
> email address is at the top of the file.
>
>
I tried it with both my usual set up and with the command shown from the
shell command line.  Both times I get the "Expected" result.  So this
may be a tough problem to resolve if its dependent somehow on o/s.

Regards,
Chip Campbell

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-02 Fir de Conversatie Gary Johnson
On 2016-11-02, Charles E Campbell wrote:
> Coacher wrote:

> > Consider the following file:
> > 
> > \begin{env}
> >  x 
> >  x
> > \end{env}
> > 
> > Open it like this: vim -N -u NONE -c 'filetype plugin indent on' -c 'set ft=
> > tex' 
> > Place the cursor at the beginning of the second line.
> > In Normal mode type 'gqgq' to format it.
> > 
> > Actual results:
> > 
> > \begin{env}
> >  x
> > 
> > x
> > \end{env}
> > 
> > Expected results:
> > 
> > \begin{env}
> >  x
> >  x
> > \end{env}
> > 
> > vim version is 8.0.0055.

> Using 8.0.055, I get your expected results.  So, I suggest that you
> check your plugins.

With my normal setup, I get his expected results, too, but if I
start Vim with the command shown, I get his actual results.

I'd contact the maintainer of $VIMRUNTIME/indent/tex.vim, whose
email address is at the top of the file.

Regards,
Gary

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [vim/vim] Autoformat with gqgq is broken inside tex environments (#1223)

2016-11-02 Fir de Conversatie Charles E Campbell
Coacher wrote:
>
> Consider the following file:
>
> |\begin{env} 
> x
> 
> x \end{env} |
>
> Open it like this: |vim -N -u NONE -c 'filetype plugin indent on' -c
> 'set ft=tex' |
> Place the cursor at the beginning of the second line.
> In Normal mode type 'gqgq' to format it.
>
> Actual results:
>
> |\begin{env} 
> x
> 
> x \end{env} |
>
> Expected results:
>
> |\begin{env} 
> x
> 
> x \end{env} |
>
> vim version is 8.0.0055.
>
Using 8.0.055, I get your expected results.  So, I suggest that you
check your plugins.

Regards,
Chip Campbell

-- 
-- 
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 vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.