Mark Highlight Plugin • Introduction to Plugins
Mark is a vim text highlighting plugin that can highlight different text in different colors at the same time. For example, you can highlight some of the key variables to help understand when reading a large piece of code, and tracking the source will be easier.
• Plug-in installation
? Download Mark.vim,: http://www.vim.org/scripts/script.php?script_id=1238;
? Storage path, under Windows system path is:vim installation path \vimxx\plugin\, the installation path under Linux system is:/usr/share/vim/vimxx/Plugin /;
? Copy the downloaded Mark.vim file to the plugin directory under the storage path .
• Plug-in shortcut keys
Normal mode
• \m : Highlight or Cancel highlighting the current word of the mouse, place the mouse on the word to be highlighted, the word will be highlighted after pressing \M.
\r : Manually input regular expression, highlight the regular expression matching words, use the first input \ r, and then enter the regular expression.
\n : Cancels highlighting of the word that the mouse is in or cancels highlighting of all highlighted words.
visual modes (visual mode)
• \m : Highlight or deselect the highlighted text segment.
\r : Manually enter regular expressions in the selected text, highlighting the text that matches the regular expression.
• Plugin Commands
Command mode
• : Mark regexp : Highlight Regular expression
• : Mark regexp : suppress Regular expression highlighting
• : Mark : Remove all Highlights
Vim highlighting text