*searchant.txt* Vim plugin for improved search highlighting Author: Tim Schumacher License: MIT Version: 1.1.0 ============================================================================== CONTENTS *searchant-contents* 1. Features ..................................... |searchant-features| 1.1 Highlight current result ................ |searchant-hl-current| 1.2 Stop highlighting ....................... |searchant-hl-stop| 1.3 Toggle highlighting ..................... |searchant-hl-toggle| 1.4 Standard highlighting ................... |searchant-hl-standard| 2. License ...................................... |searchant-license| 3. Bugs ......................................... |searchant-bugs| 4. Contributing ................................. |searchant-contributing| 5. Changelog .................................... |searchant-changelog| ============================================================================== 1. Features *searchant-features* When it comes to searching vim is one of the editors which lacks the feature of highlighting the current search result. Searchant wraps the hacky way to achieve this in vim into a plugin with a clean interface. Additionally it provides a key mapping to stop the search highlighting. ------------------------------------------------------------------------------ 1.1 Highlight current result *searchant-hl-current* Searchant highlights the last search result jumped to using a new highlighting group called `SearchCurrent`. By default the background color is set to red, to set it for example to cyan use: highlight SearchCurrent ctermbg=cyan ------------------------------------------------------------------------------ 1.2 Stop highlighting *searchant-hl-stop* Additionally a new key mapping is added to stop the normal search highlighting as well as the new one added by this plugin. By default is used because it already cancels the current search in command-line mode which makes it fit nicely. Nevertheless you can use another key, for example t: let g:searchant_map_stop = 0 nmap t SearchantStop ------------------------------------------------------------------------------ 1.3 Toggle highlighting *searchant-hl-toggle* You can map a key to toggle search highlighting of the current result on and off. This works similar to the stop binding and does not turn off highlighting permantently, the next search will be highlighted again. This will turn on highlighting again after the stop binding was used. There is no default mapping, this is how you would map it to t: nmap t SearchantToggle ------------------------------------------------------------------------------ 1.4 Standard highlighting *searchant-hl-standard* Searchant enables the standard search highlighting by default, if you only want to see the highlighting of the current result turn the standard highlighting off like this: let g:searchant_all = 0 You can still change the way the standard highlighting looks like normal, for example to change the background color to blue use: highlight Search ctermbg=blue ============================================================================== 2. License *searchant-license* MIT ============================================================================== 3. Bugs *searchant-bugs* Please report bugs on the GitHub issue tracker: http://github.com/timakro/vim-searchant/issues ============================================================================== 4. Contributing *searchant-contributing* If you want to contribute feel free to fork the Searchant repository on GitHub and send a pull request: http://github.com/timakro/vim-searchant ============================================================================== 5. Changelog *searchant-changelog* v1.1.0 * Removed g:searchant_current setting * Added toggle functionality (thanks to andykais) v1.0.7 * Better compatibility with other enhanced search plugins (namely vim-anzu and vim-asterisk, thanks to qxxxb) v1.0.6 * Fixed folds not opening automatically v1.0.5 * Keep user-defined search mappings v1.0.4 * Fixed handling of multiple windows * Fixed highlighting staying when searching for non existing pattern v1.0.3 * Added support for the ignorecase option * Fixed highlighting for patterns using branches * Fixed highlighting for non-GUI (broke with GUI fix) v1.0.2 * Fixed current result highlighting for GUI v1.0.1 * Added requirements to readme v1.0.0 * Initial stable release