You are not logged in.
Pages: 1
Topic closed
Hello,
I've just installed vim-latexsuite but can't compile any tex file. When I run the compile command "\ll" and it shows
:silent! call Tex_RunLaTeX()
but nothing happens.
I searched on the FAQ http://vim-latex.sourceforge.net/index. … -compiling and here's what I get
# What does
:echo Tex_CompileRule_dvi
say? This should be a string such as
latex -interaction=nonstopmode $*
Make sure that you can get this command to execute on your operating system via Vim. I
Yes it does. Execution using ":!latex -interaction=nonstopmode %" works well with my document.
# Make sure that
:set makeprg?
shows the same value as Tex_CompileRule_dvi.
It does.
# What happens when you do
:call Tex_RunLaTeX()
from the command line? In normal operation conditions, this should spawn a shell command which looks like Tex_CompileRule_dvi. The shell should call the latex compiler, which should run without user intervention. If this gives any errors, g:Tex_CompileRule_dvi has not been set properly. If the command above gives an error like
E117: Unknown function: Tex_RunLaTeX()
you are using an older Latex-suite. Upgrade!
Here's the problem. I get an error here:
Error detected while processing function Tex_RunLaTeX:
line 7:
E121: Undefined variable: s:target
E15: Invalid expression: s:target
line 10:
E121: Undefined variable: s:target
E116: Invalid arguments for function Tex_Debug
line 12:
E121: Undefined variable: s:target
E116: Invalid arguments for function Tex_GetVarValue('Tex_FormatDependency_'.s:t
arget) != ''
E15: Invalid expression: Tex_GetVarValue('Tex_FormatDependency_'.s:target) != ''
line 21:
E121: Undefined variable: dependency
E116: Invalid arguments for function Tex_Debug
line 25:
E121: Undefined variable: dependency
E116: Invalid arguments for function Tex_Strntok(dependency, ',', i) != ''
E15: Invalid expression: Tex_Strntok(dependency, ',', i) != ''
line 51:
E121: Undefined variable: initTarget
E15: Invalid expression: initTarget
I have the same problem as him: http://ubuntuforums.org/showthread.php?t=577217 , but I can't find vim-addon-manager which managed to solve his problem.
Also I always get some errors when opening a .tex file, but I don't know which errors, they disappear immediately. Don't know how to show them again.
EDIT: Here are these errors, didn't manage to copy them, so I took a scrot:
Uploaded with ImageShack.us
Uploaded with ImageShack.us
Any ideas ? Thanks.
My .vimrc
" .vimrc
" See: http://vimdoc.sourceforge.net/htmldoc/options.html for details
" For multi-byte character support (CJK support, for example):
"set fileencodings=ucs-bom,utf-8,cp936,big5,euc-jp,euc-kr,gb18030,latin1
set tabstop=4 " Number of spaces that a <Tab> in the file counts for.
set shiftwidth=4 " Number of spaces to use for each step of (auto)indent.
set expandtab " Use the appropriate number of spaces to insert a <Tab>.
" Spaces are used in indents with the '>' and '<' commands
" and when 'autoindent' is on. To insert a real tab when
" 'expandtab' is on, use CTRL-V <Tab>.
set smarttab " When on, a <Tab> in front of a line inserts blanks
" according to 'shiftwidth'. 'tabstop' is used in other
" places. A <BS> will delete a 'shiftwidth' worth of space
" at the start of the line.
set showcmd " Show (partial) command in status line.
"set number " Show line numbers.
set showmatch " When a bracket is inserted, briefly jump to the matching
" one. The jump is only done if the match can be seen on the
" screen. The time to show the match can be set with
" 'matchtime'.
set hlsearch " When there is a previous search pattern, highlight all
" its matches.
set incsearch " While typing a search command, show immediately where the
" so far typed pattern matches.
set ignorecase " Ignore case in search patterns.
"set smartcase " Override the 'ignorecase' option if the search pattern
" contains upper case characters.
set backspace=2 " Influences the working of <BS>, <Del>, CTRL-W
" and CTRL-U in Insert mode. This is a list of items,
" separated by commas. Each item allows a way to backspace
" over something.
set autoindent " Copy indent from current line when starting a new line
" (typing <CR> in Insert mode or when using the "o" or "O"
" command).
"set textwidth=79 " Maximum width of text that is being inserted. A longer
" line will be broken after white space to get this width.
set formatoptions=c,q,r,t " This is a sequence of letters which describes how
" automatic formatting is to be done.
"
" letter meaning when present in 'formatoptions'
" ------ ---------------------------------------
" c Auto-wrap comments using textwidth, inserting
" the current comment leader automatically.
" q Allow formatting of comments with "gq".
" r Automatically insert the current comment leader
" after hitting <Enter> in Insert mode.
" t Auto-wrap text using textwidth (does not apply
" to comments)
set ruler " Show the line and column number of the cursor position,
" separated by a comma.
set background=light " When set to "dark", Vim will try to use colors that look
" good on a dark background. When set to "light", Vim will
" try to use colors that look good on a light background.
" Any other value is illegal.
set mouse=a " Enable the use of the mouse.
filetype plugin on
syntax on
" IMPORTANT: win32 users will need to have 'shellslash' set so that latex
" can be called correctly.
"set shellslash
" IMPORTANT: grep will sometimes skip displaying the file name if you
" search in a singe file. This will confuse Latex-Suite. Set your grep
" program to always generate a file-name.
set grepprg=grep\ -nH\ $*
" OPTIONAL: This enables automatic indentation as you type.
filetype indent on
" OPTIONAL: Starting with Vim 7, the filetype of empty .tex files defaults to
" 'plaintex' instead of 'tex', which results in vim-latex not being loaded.
" The following changes the default filetype back to 'tex':
let g:tex_flavor='latex'
" this is mostly a matter of taste. but LaTeX looks good with just a bit
" of indentation.
set sw=2
" TIP: if you write your \label's as \label{fig:something}, then if you
" type in \ref{fig: and press <C-n> you will automatically cycle through
" all the figure labels. Very useful!
set iskeyword+=:
imap <buffer> <m-c> <Plug>Tex_InsertItemOnThisLine
Last edited by AMA (2010-08-07 20:50:45)
Offline
I think I know where the error comes from: the compiler doesn't know the target format. When I click on Tex-Suite menu -> Target Format, and I type dvi, the compiler works fine.
The problem now is to get the dvi format target at vim startup, but I don't know what to add in .vimrc. Anyone can help me out ?
PS: The errors I get at startup (see scrot of previous post) are still there...
Last edited by AMA (2010-08-08 11:33:32)
Offline
Did you adjust the recommended settings in your ~/.vim/ftplugin/latex-suite/texrc file (see ":help recommended-settings", or ":help latex-suite.txt" and there "Installation and recommended Settings" in vim)?
Especially have a look at the "Rules" section and there at the "Compiler Rules" subsection in the texrc file. Perhaps some tweaking there will help.
To know or not to know ...
... the questions remain forever.
Offline
Guess what, I uninstalled all vim stuff I had, and reinstalled everything. And now everything works like a charm. Strange, but at least I can start "texing". Bye!
Offline
I'm having this error too. I have already reinstalled gvim and laatex-suite several times but the problem persists. It used to work fine until two days ago. It is really strange.
Offline
Offline
Pages: 1
Topic closed