Skip to content

Commit

Permalink
feat: set any nvim_open_win option on hint window (#6)
Browse files Browse the repository at this point in the history
Co-authored-by: Mike Iversen <[email protected]>
Co-authored-by: benlubas <[email protected]>
  • Loading branch information
3 people authored Dec 28, 2023
1 parent 854a227 commit 893708f
Show file tree
Hide file tree
Showing 10 changed files with 739 additions and 656 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/panvimdoc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: panvimdoc

on: [push]

jobs:
docs:
runs-on: ubuntu-latest
name: pandoc to vimdoc
steps:
- uses: actions/checkout@v2
- uses: kdheepak/panvimdoc@main
with:
vimdoc: hydra
# The following are all optional
pandoc: "README.md" # Input pandoc file
version: "NVIM v0.9.4" # Vim version number
toc: true # Table of contents
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: "Auto generate docs"
branch: ${{ github.head_ref }}
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# How does it work

Every hydra (except pink) is an infinite chain of `<Plug>(...)` kyebindings.
Every hydra (except pink) is an infinite chain of `<Plug>(...)` keybindings.

To enter Hydra used

Expand Down
18 changes: 15 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -408,10 +408,20 @@ hint.
The offset from the nearest editor border.
- **`border`** `"single" | "double" | "rounded" | "solid" | "shadow" | "none" | string[]` (default: `"none"`)\
- **`float_opts`** `table`
(valid when `type` is `"window"`)
The border of the hint window. See `:help nvim_open_win()`
Options passed to `nvim_open_win()`, see `:h nvim_open_win()`. This is how you set the
border. Values set here are merged with the following defaults:
```lua
{
-- row, col, height, width, relative, and anchor should not be overridden
style = 'minimal',
focusable = false,
noautocmd = true,
}
```
- **`show_name`** `boolean` (default: `true`)
Expand All @@ -421,7 +431,7 @@ hint.
Table where keys are function names and values are functions them self. Each
function should return string. This functions can be required from `hint` with
`%{func_name}` syntaxis.
`%{func_name}` syntax.
### Hydra's heads
Expand Down Expand Up @@ -577,6 +587,8 @@ HydraPink #ff55de

- `HydraHint` — linked to `NormalFloat`, defines the fore- and background of the hint window;
- `HydraBorder` — linked to `FloatBorder`, defines the fore- and background of the border.
- `HydraTitle` — linked to `FloatTitle`, hl for the window title
- `HydraFooter` — linked to `FloatFooter`, hl for the window footer (only in nvim 0.10.0+)

## Keymap utility functions

Expand Down
Loading

0 comments on commit 893708f

Please sign in to comment.