虐出新高度:老外对三星S8+用锤子和刀子进行测试
350 questions with no upvoted or accepted answers
8
votes
0
answers
912
views
Highlight line number of folded lines
I want to have uniform highlighting of line numbers (provided by the LineNr and CursorLineNr hl-groups) but the line numbers of folded lines don't obey a particular group (as far as I know), but obey ...
6
votes
0
answers
686
views
How to get bold comments in vim
I am trying to add bold comments to my vim files. What i mean, is to be able to get something like this:
I saw other articles like this that allow to toggle bold comment.
The proposed solutions from ...
6
votes
2
answers
369
views
How can I decide whether a file should be opened in Vim or not?
I want to create a script using FZF (Fuzzy Finder), and I want to list only those files that should be opened with Vim. I don't want to list mp4, jpg, pdf, etc. files in FZF.
Is there any way to ...
6
votes
0
answers
713
views
Syntax highlighting: what is the difference between :syntax match and :match?
Simple question -- what is the difference between the two? When I try, for example, to highlight characters on every line after the 80th with highlight link OverLength Error (OverLength being an ...
6
votes
0
answers
4k
views
Using GNU GLOBAL and gtags-cscope in vim
Now I am learning how to use GNU GLOBAL in vim. I have installed gtags.vim. I have gtags the kernel source directory. The .vimrc includes the following lines:
set cscopetag
set csprg=gtags-cscope ...
5
votes
1
answer
75
views
Preserve manual folds when saving file under different name
I'm using manual folds. I issued the command :mkview before I exited a file just now, and found that, when I reopened it, the folds appear to be preserved as I left them.
But when I issue the command :...
5
votes
0
answers
45
views
How to factor fold status with scrollbind?
I'd like two scroll bound windows to factor in fold status when scrolling the other window. For example if a fold is closed, the other window would be scrolled by only 1 line rather than the size of ...
5
votes
0
answers
201
views
Is it possible to use syn match dynamically
I know that syn match can work with the regular expression to do some custom highlight settings.
I'm thinking if it can work dynamically.
For example, I'm doing a c++ project and I want to highlight ...
5
votes
0
answers
3k
views
ftplugin not loading
This is my .vimrc
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle....
5
votes
0
answers
2k
views
Vim Equivalent of Spyder's Variable Explorer
I am used to coding python in Spyder IDE and wanted to change to vim. I started using vim not long ago, but I miss the variable explorer implemented in Spyder. For those not familiar with Spyder, the ...
5
votes
0
answers
269
views
Set line breaks, word wraps and word searching for Thai and other non-latin languages
I can set the text width and can manually line break imported paragraphs with the following as an example.
set textwidth=72
gqq
I can also navigate English text files with the standard 'w' 'b' 'e' '*'...
4
votes
1
answer
259
views
How to use different rules for highlighting trailing whitespace inside a gitcommit diff?
In my ~/.vimrc, I have:
highlight TrailingWhitespace ctermbg=blue
autocmd BufReadPost * syn match TrailingWhitespace /\s\+\%#\@<!$/
This highlights trailing spaces, except when I am still typing ...
4
votes
0
answers
201
views
How does expression folding actually work?
The following is a stripped down version of my folding function for LaTeX documents:
setlocal foldmethod=expr
setlocal foldexpr=LaTeXFoldsExpr(v:lnum)
" Sections to be folded
let g:...
4
votes
0
answers
473
views
Unicode in vimrc no longer displaying correctly
I'm using VIM 8.1.2234 with +multi_byte and +multi_lang
In my vimrc file, I have set listchars=tab:?\ ,trail:· (Notice the "?" and the "·")
When I cat or less my vimrc, the text ...
4
votes
0
answers
1k
views
Vim adding blank line after each line when pasting from clipboard
When I copy-paste multiple lines from clipboard into my vim, it inserts a blank line after every line. But when I copy in into a text editor first and then copy-paste it into vim, the blank lines are ...