aboutsummaryrefslogtreecommitdiff
path: root/runtime/autoload/man.vim
Commit message (Collapse)AuthorAge
* man.vim: revert "completion now respects 'wildignorecase'" (#5839)Anmol Sethi2016-12-27
| | | | Instead, a note was added to `:h man.vim` on how 'fileignorecase' controls the case sensitivity of completion.
* man.vim, provider.vim: Avoid shell syntax. #5734ooora2016-12-27
| | | | | | - Improves compatibility with shell=tcsh. - man.vim: split read_page into get_page, put_page. Do not split the window until we know there is going to be output.
* man.vim: properly handle manpage names with spacesAnmol Sethi2016-12-27
|
* man.vim: completion now respects 'wildignorecase'Anmol Sethi2016-12-27
|
* man.vim: when completing a fpage, always show sectionAnmol Sethi2016-12-26
|
* man.vim: do not assume ftplugin is sourced before syntaxAnmol Sethi2016-11-19
| | | | Fixes #5574
* man.vim: no guarantee that the first line contains anything usefulAnmol Sethi2016-11-18
| | | | Fixes #5628
* man.vim: prevent bell in ':wincmd w' when only one window (#5328)Anmol Sethi2016-09-11
|
* [RFC] man.vim: remove <Plug> mappings (#5290)Anmol Sethi2016-09-04
| | | | | | - :Man with no arguments opens the manapage for the <cWORD> (man buffers) or <cword> (non-man buffers). - remove now irrelevent comment about -P flag
* man.vim: Avoid hard redraw.Justin M. Keyes2016-09-03
| | | | Use system() instead of :read to avoid a hard redraw.
* man.vim #5249Anmol Sethi2016-09-03
| | | | | | | | | | | - fix synopsis highlighting in other locales. Cannot always rely on the first line for the section in some locales; instead, use the file path and explicitly set b:man_sect to the actual section. - eliminate separate s:man_args function - simplify logic: do not reuse buffer content - introduce b:man_default_sects Fixes #5233 - introduce <Plug>(man_vsplit), <Plug>(man_tab) - simplify regexps
* Merge #5210 'vim-patch:7.4.1898 + :Man modifiers support'.Justin M. Keyes2016-08-25
|\
| * man.vim: if reusing a buffer, do not use noautocmdAnmol Sethi2016-08-24
| | | | | | | | | | The commit that added support for modifiers regressed #5168 causing #5172. This commit fixes it again.
| * man.vim: slight refactoringAnmol Sethi2016-08-24
| | | | | | | | Addresses problem one in #5240
| * man.vim: set window local options when reusing bufferAnmol Sethi2016-08-24
| | | | | | | | | | | | This is necessary incase the buffer was previously opened in a different tab, in which the window options there do not carry over. It is not explicitly documented in ':help local-options' but that is how it works.
| * man.vim: support for command modifiersAnmol Sethi2016-08-24
|/ | | | Closes #5235
* man.vim: handle empty identifier from mapping (#5187)Anmol Sethi2016-08-08
| | | | | Regression from #5168. Also changed the Man command's nargs to '+' so that man#open_page does not need to handle 0 arguments, because that will never occur.
* man.vim: handle 'gdefault' (#5182)Anmol Sethi2016-08-07
| | | Fixes #5181
* man.vim: refactoring and autocmd fixAnmol Sethi2016-08-07
| | | | | | - man#open_page_command and man#open_page_mapping are now a single function - New autocmd to fix #5172
* man.vim: default K mappingAnmol Sethi2016-08-06
| | | | - Also some small improvements in other parts.
* man.vim: doc, UX tweaksJustin M. Keyes2016-08-04
| | | | s:error: Convention is to highlight the entire message, so stick to that.
* man.vim: rewriteAnmol Sethi2016-08-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Smart autocomplete. It's automatically sorted, filtered for duplicates and even formats the candidates based on what is needed. For example, `:Man 1 printf<TAB>` will show the pages that are in section 1m as 'page(sect)' to let you know they are in a more specific section. - Instead of trying to unset $MANPAGER we use the -P flag to set the pager to cat - Always use the section arg '-s', it makes the code much simpler (see comment in s:man-args). - A manpage name starting with '-' is invalid. It's fine for sections because of the use of '-s'. - The tagstack is an actual stack now, makes it much simpler. - By using v:count and v:count1, the plugin can explicitly check whether the user set a count, instead of relying on a default value (0) that is actually a real manpage section. - Extraction of a manpage reference is much more simple. No giant long complicated regexes. Now, the plugin lets `man` handle the actual validation. We merely extract the section and page. Syntax regexes are a bit more specific though to prevent highlighting everything. - Multilingual support in the syntax file. Removed the cruft that was only relevent to vim. Also simplified and improved many of the regexes. - Using shellescape when sending the page and sect as arguments - In general, the code flow is much more obvious. - man#get_page has been split up into smaller functions with explicit responsibilties - ':help' behavior in opening splits and manpages - Comments explaining anything that needs explaining and isn't immediately obvious. - If a manpage has already been loaded but if it were to reloaded at the current width which is the same as the width at which it was loaded at previously, it is not reloaded. - Use substitute to remove the backspaced instead of `col -b`, as the latter doesn't work with other languages. - Open paths to manpages - It uses cWORD instead of cword to get the manpage under the cursor, this helps with files that do not have (,) in iskeyword. It also means the plugin does not set iskeyword locally anymore. - <Plug>(Man) mapping for easy remapping - Switched to single quotes wherever possible. - Updated docs in $VIMRUNTIME/doc/filetype.txt (still need to update user-manual) - Always call tolower on section name. See comment in s:extract_page_and_sect_fpage - Formatting/consistency cleanup - Automatically map q to ':q<CR>' when invoked as $MANPAGER - It also fully supports being used as $MANPAGER. Setting the name and stuff automatically. - Split up the setlocals into multiple lines for easier readability - Better detection of errors by redirecting stderr to /dev/null. If an error occured, stdout will be empty. - Functions return [sect, page] not [page, sect]. Makes more sense with how man takes the arguments as sect and then page. - Pretty prints errors on a single line. - If no section is given, automatically finds the correct section for the buffer name. It also gets the correct page. See the comment in s:get_page - If $MANWIDTH is not set, do not assign directly to $MANWIDTH because then $MANWIDTH will always stay set to the same value as we only use winwidth(0) when the global $MANWIDTH is empty. Instead we set it locally for the command. - Maintainer notes on all files.
* man.vim: prefer cmd-line to normal-mode commandsNoah Frederick2016-03-05
|
* man.vim: clean up regex/string comparisonsNoah Frederick2016-03-05
| | | | | - Explicitly specify case sensitivity when comparing strings - Clean up unnecessarily complex `if` statements
* man.vim: fixes to argument handling and parsingNoah Frederick2016-03-05
| | | | | | | | | | | - Define a collection of legal characters when parsing page and section in `s:parse_page_and_section()` instead of relying on 'iskeyword', which is unreliable. - Allow non-numeric section names (e.g., `3c`). - Simplify argument handling in `man#get_page()` to accommodate non-numeric section names. Fixes #4165.
* Respect $MANWIDTHGeorge Brown2016-02-01
| | | | If $MANWIDTH is set do not override it otherwise use winwidth.
* man.vim: avoid creating extra blank buffers.Justin M. Keyes2015-09-25
|
* man.vim: accept [count] for section number.Justin M. Keyes2015-09-23
|
* man.vim: window-local optionsJustin M. Keyes2015-09-23
| | | | | Set window-local options only on a newly-created "man" tab or if we're already in one.
* man.vim: man#get_page(): parse page and section.Justin M. Keyes2015-09-23
| | | | | - Eliminate man#pre_get_page(). - Temporarily remove () from 'iskeyword' to avoid spurious \k match.
* man.vim: convert ftplugin to actual plugin.Justin M. Keyes2015-09-23
- do not create leader maps - :norm! instead of :norm - :keepjumps during layout - use blackhole reg to avoid polluting unnamed reg - format buffer name as "man://foo(2)" - simulate behavior of `man` - buffer-local mapping of q to quit - open in new tab instead of new window - set 'nolist' - set tabstop=8