Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem with coc.nvim and coc-vimtex: No LaTex Completion #36

Open
GrassiColas opened this issue May 7, 2024 · 0 comments
Open

Problem with coc.nvim and coc-vimtex: No LaTex Completion #36

GrassiColas opened this issue May 7, 2024 · 0 comments

Comments

@GrassiColas
Copy link

I'm having an issue with coc.nvim and coc-vimtex in Vim/Neovim. I only want coc.nvim to work with Python and LaTex files, but coc-vimtex is not providing autocompletion for LaTex. Here's what I've tried so far:

Configuration to Enable coc.nvim Only for Python and LaTex

I have configured my .vimrc to enable coc.nvim only for Python and LaTex files using the following autocommands:
autocmd FileType python,tex let b:coc_enabled = 1 autocmd FileType * if &filetype !=# 'python' && &filetype !=# 'tex' | let b:coc_enabled = 0 | endif

Steps Taken

Installed coc.nvim and coc-vimtex:

I installed coc-vimtex using :CocInstall coc-vimtex.
I checked with :CocList extensions, and coc-vimtex is listed.
Configured coc-settings.json:

I set coc.source.vimtex.enable to true.
I also added 'tex' and other file types to coc.source.vimtex.filetypes.
Restarted Vim/Neovim:

I restarted Vim/Neovim multiple times to apply the changes.
Tested LaTex Autocompletion:

I tried typing common LaTex commands like \begin or \section, but I didn't get any LaTex-specific autocompletion.
Diagnostics:

I used :CocDiagnostics, but there is nothing on the new buffer
I checked :CocCommand workspace.showOutput, but nothing related to coc-vimtex appeared.
Verified vimtex:

Commands like :VimtexCompile work, suggesting that vimtex is functioning properly.
Reinstalled coc-vimtex:

I tried uninstalling and reinstalling coc-vimtex, but it didn't resolve the problem.
Why might coc-vimtex not be providing LaTex-specific autocompletion?
Is there something I might have missed in my configuration or setup?
Any suggestions on additional steps to troubleshoot or fix this issue?
I have acces to coc in tex file but no autocompletion base with doc-vimtex only on my last word I write like basic coc use
when I do :CocList sources

around|[A]||1| |uffer|[B]||1| |ile|[F]||10| |python-import|[PY]||99 python| |pyright|[LS]|
so nothing about latex

I appreciate any help or advice you can offer. Thanks in advance!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant