sponsor Vim development Vim logo Vim Book Ad

Pinnacle : Highlight group manipulation for Vim

 script karma  Rating 0/0, Downloaded by 1889  Comments, bugs, improvements  Vim wiki

created by
Greg Hurrell
 
script type
utility
 
description
*pinnacle.txt*           Highlight group manipulation for Vim           *pinnacle*

CONTENTS                                                     *pinnacle-contents*

1. Intro             |pinnacle-intro|
2. Installation      |pinnacle-installation|
3. Functions         |pinnacle-functions|
4. Website           |pinnacle-website|
5. License           |pinnacle-license|
6. Development       |pinnacle-development|
7. Authors           |pinnacle-authors|
8. History           |pinnacle-history|

INTRO                                                           *pinnacle-intro*

Pinnacle provides functions for manipulating |:highlight| groups.

INSTALLATION                                             *pinnacle-installation*

To install Pinnacle, use your plug-in management system of choice.

If you don't have a "plug-in management system of choice", I recommend
Pathogen (https://github.com/tpope/vim-pathogen) due to its simplicity and
robustness. Assuming that you have Pathogen installed and configured, and
that you want to install Pinnacle into `~/.vim/bundle`, you can do so with:
>
    git clone https://github.com/wincent/pinnacle.git ~/.vim/bundle/pinnacle
<
Alternatively, if you use a Git submodule for each Vim plug-in, you could do
the following after `cd`-ing into the top-level of your Git superproject:
>
    git submodule add https://github.com/wincent/pinnacle.git ~/vim/bundle/pinnacle
    git submodule init
<
To generate help tags under Pathogen, you can do so from inside Vim with:
>
    :call pathogen#helptags()
<
FUNCTIONS                                                   *pinnacle-functions*

                                                       *pinnacle#sub_newlines()*
pinnacle#sub_newlines() ~

Replaces newlines with spaces.

                                                      *pinnacle#capturel_line()*
pinnacle#capturel_line() ~

Runs a command and returns the captured output as a single line.

Useful when we don't want to let long lines on narrow windows produce
unwanted embedded newlines.

                                                  *pinnacle#capture_highlight()*
pinnacle#capture_highlight() ~

Gets the current value of a highlight group.

                                                  *pinnacle#extract_highlight()*
pinnacle#extract_highlight() ~

Extracts a highlight string from a group, recursively traversing linked
groups, and returns a string suitable for passing to `:highlight`.

                                                         *pinnacle#extract_bg()*
pinnacle#extract_bg() ~

Extracts just the bg portion of the specified highlight group.

                                                         *pinnacle#extract_fg()*
pinnacle#extract_fg() ~

Extracts just the bg portion of the specified highlight group.

                                                  *pinnacle#extract_component()*
pinnacle#extract_component() ~

Extracts a single component (eg. "bg", "fg", "italic" etc) from the
specified highlight group.

                                                               *pinnacle#dump()*
pinnacle#dump() ~

Returns a dictionary representation of the specified highlight group.

                                                          *pinnacle#highlight()*
pinnacle#highlight() ~

Returns a string representation of a dictionary containing bg, fg, term,
cterm and guiterm entries.

                                                          *pinnacle#italicize()*
pinnacle#italicize() ~

Returns an italicized copy of `group` suitable for passing to `:highlight`.

                                                           *pinnacle#embolden()*
pinnacle#embolden() ~

Returns a bold copy of `group` suitable for passing to `:highlight`.

                                                          *pinnacle#underline()*
pinnacle#underline() ~

Returns an underlined copy of `group` suitable for passing to `:highlight`.

                                                           *pinnacle#decorate()*
pinnacle#decorate() ~

Returns a copy of `group` decorated with `style` (eg. "bold", "italic" etc)
suitable for passing to `:highlight`.

WEBSITE                                                       *pinnacle-website*

The official Pinnacle source code repo is at:

http://git.wincent.com/pinnacle.git

Mirrors exist at:

- https://github.com/wincent/pinnacle
- https://gitlab.com/wincent/pinnacle
- https://bitbucket.org/ghurrell/pinnacle

Official releases are listed at:

http://www.vim.org/scripts/script.php?script_id=5360

LICENSE                                                       *pinnacle-license*

Copyright (c) 2016-present Greg Hurrell

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
sell copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
IN THE SOFTWARE.

DEVELOPMENT                                               *pinnacle-development*

Contributing patches ~

Patches can be sent via mail to greg@hurrell.net, or as GitHub pull requests
at: https://github.com/wincent/pinnacle/pulls

Cutting a new release ~

At the moment the release process is manual:

- Perform final sanity checks and manual testing
- Update the |pinnacle-history| section of the documentation
- Verify clean work tree:
>
    git status
<
- Tag the release:
>
    git tag -s -m "$VERSION release" $VERSION
<
- Publish the code:
>
    git push origin master --follow-tags
    git push github master --follow-tags
<
- Produce the release archive:
>
    git archive -o pinnacle-$VERSION.zip HEAD -- .
<
- Upload to http://www.vim.org/scripts/script.php?script_id=5360

AUTHORS                                                       *pinnacle-authors*

Pinnacle is written and maintained by Greg Hurrell <greg@hurrell.net>.

Other contributors that have submitted patches include (in alphabetical
order):

- Cody Buell
- Kyle Poole
 
install details
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
pinnacle-1.0.zip 1.0 2019-03-06 7.0 Greg Hurrell - Added `pinnacle#dump()`.
pinnacle-0.3.1.zip 0.3.1 2017-06-08 7.0 Greg Hurrell - Fix another bug with augmentation of existing highlights.
pinnacle-0.3.zip 0.3 2017-06-07 7.0 Greg Hurrell - Added `pinnacle#extract_bg` and `pinnacle#extract_fg`.
- Fixed bug that could cause existing highlights to be incorrectly augmented.
pinnacle-0.2.zip 0.2 2017-01-09 7.0 Greg Hurrell - Added `pinnacle#underline`.
pinnacle-0.1.zip 0.1 2016-03-30 7.0 Greg Hurrell Initial upload
ip used for rating: 18.210.12.229

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
OSDN