Thread: [Vim-latex-devel] show warnings after compiling
Brought to you by:
srinathava,
tmaas
From: Andreas G. <and...@tu...> - 2013-01-17 17:01:16
|
Hello list, I am new to the vim latex-suite. I set everything up and it works fine so far. But I can not figure out how to show latex warning after compiling the document using \ll. If there are errors they are shown in thw "Quickfix list" with a preview window below. But in the case of warnings (e.g. undefined references) I end up in the normal vim window without having the warnings shown. I set "TCLevel strict" which sets Tex_IgnoreLevel to 0, but it doesn't change anything. Any ideas what I am doing wrong? Or is it the normal way that warnings are not shown? Any help is appreciated. Thanks and best regards. Andreas -- ------------------------------------------------------------------------ Andreas Groh phone : +49-351-463.34974 Institut fuer Planetare Geodaesie fax : +49-351-463.37063 Technische Universitaet Dresden email : and...@tu... D-01062 Dresden, Germany web : tpg.geo.tu-dresden.de ------------------------------------------------------------------------ |
From: Peng S. <sha...@gm...> - 2013-01-17 17:21:28
|
On 01/17/2013 11:59 AM, Andreas Groh wrote: > Hello list, > > I am new to the vim latex-suite. I set everything up and it works fine > so far. But I can not figure out how to show latex warning after > compiling the document using \ll. If there are errors they are shown in > thw "Quickfix list" with a preview window below. But in the case of > warnings (e.g. undefined references) I end up in the normal vim window > without having the warnings shown. I set "TCLevel strict" which sets > Tex_IgnoreLevel to 0, but it doesn't change anything. > > Any ideas what I am doing wrong? Or is it the normal way that warnings > are not shown? Any help is appreciated. > > Thanks and best regards. > > Andreas > Dear Andreas, I just tested on my machine x86_64 arch linux with vim 7.3.754 and what I needed to do was simply putting let g:Tex_IgnoreLevel = 0 in my .vimrc then the undefined references will be listed after compilation. I didn't have to use TCLevel at all. Did you try the line I mentioned? -- Peng Shao |
From: Peng S. <sha...@gm...> - 2013-01-17 17:48:36
|
On 01/17/2013 12:41 PM, Andreas Groh wrote: > Hello, > > thanks for your reply. I also have let g:Tex_IgnoreLevel=0 in my > .vimrc. As far as I understood the TCLevel command is just a short cut > for let g:Tex_IgnoreLevel=x to be used from within vim. However, the > warnings are not shown. In my case the warnings are mainly due to > undefined citations. > > Meanwhile I started working on another latex project without undefined > citations. In this case the warnings for underfull boxes etc. are > shown. That is strange. If I include an undefined citation the > corresponding warning is also not shown. > > Why is that? Are the warnings for undefined citations treated in a > different way? > > Cheers. > > Andreas > Dear Andreas, Here is the warning-level-related settings in my vimrc let g:Tex_IgnoredWarnings = \"Underfull\n". \"Overfull\n". \"specifier changed to\n". \"You have requested\n". \"Missing number, treated as zero.\n". \"Citation %.%# undefined\n". \"Unused\n". \"LaTeX Font Warning:\n" \"There were undefined references\n". " This number N indicates that latex-suite should ignore the first N of the above. let g:Tex_IgnoreLevel = 8 Would you please try to see if it can detect the undefined references? Btw, I cc this mail to the maillist so other people may also see it, just in case in future someone else ran into a similar problem. -- Peng Shao |
From: Andreas G. <and...@tu...> - 2013-01-17 18:02:13
|
Hello Peng Shao, Sorry, my last reply was only to you and not to the list. I tried your settings but it doesn't change the situation. The problem is that the undefined citation warnings are not shown (not references, like I wrote in my initial post, sorry for that). If I include a reference which is not defined the warning is correctly shown. But even for let g:Tex_IgnoreLevel = 0 the undefined citation warnings are still absent. Best Andreas On 01/17/2013 06:48 PM, Peng Shao wrote: > > On 01/17/2013 12:41 PM, Andreas Groh wrote: >> Hello, >> >> thanks for your reply. I also have let g:Tex_IgnoreLevel=0 in my >> .vimrc. As far as I understood the TCLevel command is just a short cut >> for let g:Tex_IgnoreLevel=x to be used from within vim. However, the >> warnings are not shown. In my case the warnings are mainly due to >> undefined citations. >> >> Meanwhile I started working on another latex project without undefined >> citations. In this case the warnings for underfull boxes etc. are >> shown. That is strange. If I include an undefined citation the >> corresponding warning is also not shown. >> >> Why is that? Are the warnings for undefined citations treated in a >> different way? >> >> Cheers. >> >> Andreas >> > Dear Andreas, > > Here is the warning-level-related settings in my vimrc > > > let g:Tex_IgnoredWarnings = > \"Underfull\n". > \"Overfull\n". > \"specifier changed to\n". > \"You have requested\n". > \"Missing number, treated as zero.\n". > \"Citation %.%# undefined\n". > \"Unused\n". > \"LaTeX Font Warning:\n" > \"There were undefined references\n". > " This number N indicates that latex-suite should ignore the first N of > the above. > let g:Tex_IgnoreLevel = 8 > > Would you please try to see if it can detect the undefined references? > > Btw, I cc this mail to the maillist so other people may also see it, > just in case in future someone else ran into a similar problem. > -- ------------------------------------------------------------------------ Andreas Groh phone : +49-351-463.34974 Institut fuer Planetare Geodaesie fax : +49-351-463.37063 Technische Universitaet Dresden email : and...@tu... D-01062 Dresden, Germany web : tpg.geo.tu-dresden.de ------------------------------------------------------------------------ |
From: Peng S. <sha...@gm...> - 2013-01-17 18:28:10
|
On 01/17/2013 01:00 PM, Andreas Groh wrote: > Hello Peng Shao, > > Sorry, my last reply was only to you and not to the list. It is fine, I very often forgot to reply to the list as well :) > I tried your settings but it doesn't change the situation. The problem > is that the undefined citation warnings are not shown (not references, > like I wrote in my initial post, sorry for that). If I include a > reference which is not defined the warning is correctly shown. But even > for let g:Tex_IgnoreLevel = 0 the undefined citation warnings are still > absent. > > Best > Andreas Okay I think I understand your situation: you want latex-suite to raise the warning which was originally undefined. In this case I am sorry since I don't think I can help you very much... I have never encountered an issue like this as what I needed the most was to ignore some undesired warnings. Anyway, could you please send me a sample of latex file and tell me what kind of warning you want to see, so that I may give it a try? But don't expect too much... -- Peng Shao |
From: Alessandro P. <ale...@la...> - 2013-01-17 19:08:26
|
> On 01/17/2013 12:41 PM, Andreas Groh wrote: >> Hello, >> >> thanks for your reply. I also have let g:Tex_IgnoreLevel=0 in my >> .vimrc. As far as I understood the TCLevel command is just a short cut >> for let g:Tex_IgnoreLevel=x to be used from within vim. However, the >> warnings are not shown. In my case the warnings are mainly due to >> undefined citations. >> >> Meanwhile I started working on another latex project without undefined >> citations. In this case the warnings for underfull boxes etc. are >> shown. That is strange. If I include an undefined citation the >> corresponding warning is also not shown. >> >> Why is that? Are the warnings for undefined citations treated in a >> different way? Well, I'm not sure about why the warnings for one of your projects get displayed and those for the other do not, but vim's quickfix mode is known to not play nicely with with latex, since it is unable to parse multi-linear error messages (or warnings). You could try using something like 'rubber' [1], which is a latex wrapper that is able to "sanitize" error and warning messages for vim, i.e. that can print them on a single line. This should also fix the annoying issue of vim opening an .aux file upon compilation errors. Cheers, Alessandro [1] https://launchpad.net/rubber/ |
From: Alessandro P. <ale...@la...> - 2013-01-17 19:12:13
|
2013/1/17 Alessandro Pezzoni <ale...@la...>: > You could try using something like 'rubber' [1], which is a latex > wrapper that is able to "sanitize" error and warning messages for vim, > i.e. that can print them on a single line. This should also fix the > annoying issue of vim opening an .aux file upon compilation errors. Sorry for double-posting, but I forgot to say that to use a different compiler is easy as changing a vim variable, e.g. for dvi or pdf output: let g:Tex_CompileRule_dvi = "rubber -s $*" let g:Tex_CompileRule_pdf = "rubber -s --pdf $*" The '-s' option is there to tell it to display one error message per line. Alessandro |
From: Andreas G. <and...@tu...> - 2013-01-18 08:39:33
|
Dear Alessandro, Thanks for the hint. I will give it a try and report the result. Andreas On 01/17/2013 08:12 PM, Alessandro Pezzoni wrote: > 2013/1/17 Alessandro Pezzoni <ale...@la...>: >> You could try using something like 'rubber' [1], which is a latex >> wrapper that is able to "sanitize" error and warning messages for vim, >> i.e. that can print them on a single line. This should also fix the >> annoying issue of vim opening an .aux file upon compilation errors. > > Sorry for double-posting, but I forgot to say that to use a different > compiler is easy as changing a vim variable, e.g. for dvi or pdf > output: > > let g:Tex_CompileRule_dvi = "rubber -s $*" > let g:Tex_CompileRule_pdf = "rubber -s --pdf $*" > > The '-s' option is there to tell it to display one error message per line. > > Alessandro > -- ------------------------------------------------------------------------ Andreas Groh phone : +49-351-463.34974 Institut fuer Planetare Geodaesie fax : +49-351-463.37063 Technische Universitaet Dresden email : and...@tu... D-01062 Dresden, Germany web : tpg.geo.tu-dresden.de ------------------------------------------------------------------------ |
From: Andreas G. <and...@tu...> - 2013-01-21 09:08:01
|
Hello, I figured out that the missing of the undefined citation warnings depends on my used bibliography package. I use the package natbib which produces a warning starting with "Package natbib Warning: Citation ... on page ... undefined". This warning is not shown by the latex-suite. If I disable natbib the warning looks like "Latex Warning: Citation ...." and this warning is recognised an display by the latex-suite. Is there a way the make the latex-suite sensitive for these kind of warnings (e.g. editing .vim/compiler/tex.vim)? Cheers Andreas On 01/17/2013 05:59 PM, Andreas Groh wrote: > Hello list, > > I am new to the vim latex-suite. I set everything up and it works fine > so far. But I can not figure out how to show latex warning after > compiling the document using \ll. If there are errors they are shown in > thw "Quickfix list" with a preview window below. But in the case of > warnings (e.g. undefined references) I end up in the normal vim window > without having the warnings shown. I set "TCLevel strict" which sets > Tex_IgnoreLevel to 0, but it doesn't change anything. > > Any ideas what I am doing wrong? Or is it the normal way that warnings > are not shown? Any help is appreciated. > > Thanks and best regards. > > Andreas > -- ------------------------------------------------------------------------ Andreas Groh phone : +49-351-463.34974 Institut fuer Planetare Geodaesie fax : +49-351-463.37063 Technische Universitaet Dresden email : and...@tu... D-01062 Dresden, Germany web : tpg.geo.tu-dresden.de ------------------------------------------------------------------------ |
From: Andreas G. <and...@tu...> - 2013-01-21 10:23:58
|
Hi again, I edited .vim/compiler/tex.vim where I added patterns for "Package ... Warning"-like warnings. Hence, I extended the recognised error format setlocal efm+=%+WPackage\ %.%#Warning:\ %.%#line\ %l%.%# setlocal efm+=%+WPackage\ %.%#Warning:\ %m This does the job. Now undefined citation warnings from natbib are shown. But is there a way to extend the error format by changing a local variable in my .vimrc instead of hacking the tex.vim file? Best Andreas On 01/21/2013 10:06 AM, Andreas Groh wrote: > Hello, > > I figured out that the missing of the undefined citation warnings > depends on my used bibliography package. I use the package natbib which > produces a warning starting with "Package natbib Warning: Citation ... > on page ... undefined". This warning is not shown by the latex-suite. If > I disable natbib the warning looks like "Latex Warning: Citation ...." > and this warning is recognised an display by the latex-suite. > > Is there a way the make the latex-suite sensitive for these kind of > warnings (e.g. editing .vim/compiler/tex.vim)? > > Cheers > > Andreas > > On 01/17/2013 05:59 PM, Andreas Groh wrote: >> Hello list, >> >> I am new to the vim latex-suite. I set everything up and it works fine >> so far. But I can not figure out how to show latex warning after >> compiling the document using \ll. If there are errors they are shown in >> thw "Quickfix list" with a preview window below. But in the case of >> warnings (e.g. undefined references) I end up in the normal vim window >> without having the warnings shown. I set "TCLevel strict" which sets >> Tex_IgnoreLevel to 0, but it doesn't change anything. >> >> Any ideas what I am doing wrong? Or is it the normal way that warnings >> are not shown? Any help is appreciated. >> >> Thanks and best regards. >> >> Andreas >> > -- ------------------------------------------------------------------------ Andreas Groh phone : +49-351-463.34974 Institut fuer Planetare Geodaesie fax : +49-351-463.37063 Technische Universitaet Dresden email : and...@tu... D-01062 Dresden, Germany web : tpg.geo.tu-dresden.de ------------------------------------------------------------------------ |