392 questions
8
votes
3
answers
5k
views
In Vim, how to I set an autocommand to be run after a plugin has loaded?
One of the Vim Plugins I use has a bug, causing it to set :syntax spell notoplevel. The bug is easily mitigated if I run the command :syntax spell toplevel after opening a file. However, I'm lazy and ...
1
vote
2
answers
436
views
NeoVim Highlight .ts template as HTML / JSX
Update:
The closest I am able to get is by using an hmtl tagged template string. (This highlighting works even if html is undefined in the file.)
But this doesn't work for trying to do something like:
...
15
votes
2
answers
10k
views
Syntax coloring with Vim and Fish-Shell
What is the best editor for fish scripts? I mean an editor which can properly highlight, indent and syntax check.
I found the vim-fish project, but I am still scratching my head as to how to install ...
0
votes
2
answers
414
views
Remove tab highlighting in vim
When I write .f90 or .f file I have the problem that vim always highlight the first number of empty columns with red See figure. I have tried to use :noh but did not work. If I use "set list" they ...
168
votes
7
answers
129k
views
Enable Vim Syntax Highlighting By Default
I know how to turn syntax highlighting on and off in vim by running this in the editor:
:syntax on/off
But I want syntax highlighting to be enabled by default, so I don't have to turn it on every ...
1
vote
1
answer
94
views
How do I change vim's syntax highlighting for multiline comment in *.py files?
How do I change syntax color of multiline comment in python source codes?
Line
hi def link pythonComment Comment
in /usr/share/vim/vim82/syntax/python.vim seems to cover only singleline ...
20
votes
2
answers
7k
views
Vim syntax and Latex math inside markdown
I write documentation in markdown using ViM and I also put math using the latex $$ symbol (I compile using pandoc). The thing is that ViM syntax wouldn't ignore the underscores _ inside the dollar ...
2
votes
0
answers
63
views
Syntax highlighting of nested braces in vim
I am writing a vim syntax file for a yacc-like language, which contains another language in blocks delimited by braces. My problem stems from the inner language also using braces as part of its own ...
1
vote
2
answers
542
views
vim can't recognize Podfile and podspec file as Ruby file
How to make vim recognize Podfile and podspec file (some file without extension) as ruby file, so that vim can make syntax highlight.
5
votes
4
answers
3k
views
VIM loses syntax highlighting when using split command
So I have created my own syntax highlighting file and it works well if there is only one file opened. However, if I do :split otherFile, the other buffer that gets opened does not have syntax ...
2
votes
2
answers
1k
views
vim syntax highlighting: region that starts with "#" and end with either "#" or end of line
The situation
I am in the process of writing a vim syntax file for a language that allows inline comments following this scheme:
This is code # and here is comment # but this is code again
The ...
13
votes
5
answers
11k
views
How to override default syntax highlight in vim?
In VIM, I need to perform a simple task - highlight "(" and ")". I can do this easily by issuing two commands:
:syn match really_unique_name display "[()]"
:hi really_unique_name guifg=#FF0000
But if ...
0
votes
3
answers
1k
views
Should I avoid using "str" as a variable name in Python?
I've noticed that certain variable names in Python get flagged up by Vim in blue highlight, whereas others do not. I'm familiar with the concept of reserved words, per this question, but from looking ...
-4
votes
1
answer
584
views
How to turn off Auto highlight text in Vim editor? [closed]
In VIM text editor, everytime whenever I type ''typedef '', it gets highlighted automatically. How to fix this?
I want to turn off word highlighting property in vim.
94
votes
13
answers
91k
views
How to highlight Bash scripts in Vim?
My Vim editor auto highlights PHP files (vim file.php), HTML files (vim file.html) and so on.
But when I type: vim file and inside it write a Bash script, it doesn't highlight it.
How can I tell Vim ...
0
votes
2
answers
113
views
Can I cascade vim syntax highlighting rules like in nano?
I have a custom file type, which contains lots of fields like
FieldName: FieldValue
I'm trying to create syntax highlighting for this filetype, in nano and vim, such that "Fieldname" ...
0
votes
2
answers
754
views
My conceal options are not loading in vim
I have some conceal options (syntax match Normal '\.md\]' conceal cchar=]) added in a $HOME/.vim/after/syntax/base.vim.
They are not loaded when I open a file. But if i do :source $HOME/.vim/after/...
1
vote
1
answer
314
views
Vim highlight a set of words in different colors each in all files
I need vim/Gvim to highlight a set of keywords each with mentioned color in all files (it may be a text file, c source file, or anything else).
For example TODO, FIXME are highlighted in C files. Like ...
3
votes
1
answer
1k
views
Why is line highlighting not working in vim?
I am trying to use dracula theme for vim and have installed it successfully using vundle on my gnome-terminal.
The issue that I am facing is that the current line and line numbers aren' translucently ...
0
votes
0
answers
265
views
Semantic hilight function names in vim
I have a file with some subroutines.
The syntax is like
subroutine sub_name_1
...
endsub
/* or optionally */
subroutine sub_name_2 {
...
}
There are called like call sub_name_1.
I can't ...
-3
votes
1
answer
416
views
create syntax checker vim plugin for a new Programming language [closed]
I want to create a new vim syntax checker for a new programming language that is not used widely, first i tried to read the code of the follwing plugins neomake, syntastic
, and Ale in order to ...
0
votes
0
answers
765
views
How to disable vim markdown syntax highlight
I am using a setup where I keep a journal in markdown and have latex code. The trouble is that inside the latex code there are signs that are read as markdown operations and this causes vim to draw ...
1
vote
2
answers
4k
views
Comments have an ugly background color in vim solarized theme
My Configurations
iTerm2 - with Solarized theme with xterm-256color as Report terminal type.
zsh - with theme set to agnoster
Solarized vim - My vim theme is solarized, here're the settings:
set ...
1
vote
1
answer
5k
views
Issues with Markdown Syntax Highlighting in Neovim
I am currently trying to start writing Markdown in Neovim. However, the syntax highlighting is messed up. Specifically, whenever I have a less than sign inside a LaTeX block, everything after it is ...
1
vote
1
answer
598
views
VIM - Syntax classes and colorscheme - Which class controls variable usage delimiters?
This is a sample of the colouring which is provided by the "darkbone.vim" colour scheme (updated):
On the "TMP=" line, the "${ }" delimiters are different from the "...