Tu Nguyen
f0e47fd5dc
fix(win): take border into account for window position ( #64 )
...
## Description
<!-- Describe the big picture of your changes to communicate to the
maintainers
why we should accept this pull request. -->
The window position is not correctly centered when position is set to
`float` and border isn't `none`. I found [a similar
issue](https://github.com/folke/lazy.nvim/issues/812 ) in
[lazy.nvim](https://github.com/folke/lazy.nvim ) along with [your
fix](451f217e9b )
there, so I have applied the same fix here. Thank you for your work!
## Related Issue(s)
https://github.com/folke/lazy.nvim/issues/812
<!--
If this PR fixes any issues, please link to the issue here.
- Fixes #<issue_number>
-->
## Screenshots
<!-- Add screenshots of the changes if applicable. -->
### Before
<img width="2240" alt="image"
src="https://github.com/user-attachments/assets/6e5eeb7b-7993-4ab5-a40e-c77021a5ccb0 ">
### After
<img width="2240" alt="image"
src="https://github.com/user-attachments/assets/66ad76ab-8ca2-446f-afce-b18599313319 ">
---------
Co-authored-by: Folke Lemaitre <folke.lemaitre@gmail.com>
2024-11-12 19:57:01 +01:00
Folke Lemaitre
09a6f17ecc
fix(notifier): take title/footer into account to determine notification width. Fixes #54
2024-11-11 11:07:28 +01:00
Folke Lemaitre
eb8ab37f6a
perf(win): don't try highlighting snacks internal filetypes
2024-11-10 09:20:12 +01:00
Folke Lemaitre
cc80f6dc1b
perf(win): prevent treesitter and syntax attaching to scratch buffers
2024-11-08 15:39:17 +01:00
Folke Lemaitre
5ccf72e6d0
docs(win): document width/height behavior for win
2024-11-08 13:20:02 +01:00
Folke Lemaitre
5fd9c426e8
fix(win): update win/buf opts when needed
2024-11-08 09:27:28 +01:00
Folke Lemaitre
61496a3ef0
perf(win): skip events when setting buf/win options. Trigger FileType on BufEnter only if needed
2024-11-08 07:28:27 +01:00
Folke Lemaitre
12077bcf65
feat(win): disable winblend when colorscheme is transparent. Fixes #26
2024-11-07 23:10:39 +01:00
Folke Lemaitre
cc5ee192ca
fix(win): properly resolve user styles as last
2024-11-07 22:22:55 +01:00
Folke Lemaitre
f59237f1dc
fix(win): simpler way to add buffer padding
2024-11-07 18:30:01 +01:00
borgy
f5602e60c3
fix(win): set border to none for backdrop windows ( #19 )
...
## Description
Previously, backdrop windows were being created with the default border
options set in `opts`. I can't imagine this is ever desirable (see
screenshots), so always set the backdrop window border to none.
## Related Issue(s)
N/A
## Screenshots
### Before:

### After:

2024-11-07 14:38:16 +01:00
Folke Lemaitre
d3efb92aa5
feat(win): util methods to handle buffer text
2024-11-07 14:32:34 +01:00
Folke Lemaitre
4991e347dc
fix(win): dont center float when relative="cursor"
2024-11-07 14:32:18 +01:00
Folke Lemaitre
107d10b52e
fix(win): disable sidescroloff in minimal style
2024-11-07 14:31:57 +01:00
Teppei Taguchi
59ae7cf162
docs(readme, lazygit): fix typos ( #16 )
...
## Description
<!-- Describe the big picture of your changes to communicate to the
maintainers
why we should accept this pull request. -->
Fixes minor typos in documentation.
## Related Issue(s)
<!--
If this PR fixes any issues, please link to the issue here.
- Fixes #<issue_number>
-->
## Screenshots
<!-- Add screenshots of the changes if applicable. -->
2024-11-07 13:50:13 +01:00
Folke Lemaitre
cad236f9bb
feat(win): allow setting ft just for highlighting without actually changing the filetype
2024-11-07 00:17:39 +01:00
Folke Lemaitre
e982aabefd
feat(win): equalize splits
2024-11-06 23:40:47 +01:00
Folke Lemaitre
476fb56bfd
feat(win): win:focus()
2024-11-06 23:07:02 +01:00
Folke Lemaitre
8be14c68a7
fix(win): better winfixheight and winfixwidth for splits
2024-11-06 23:07:02 +01:00
Folke Lemaitre
8c0f10b9da
feat(win): added default hl groups for windows
2024-11-06 22:52:43 +01:00
Folke Lemaitre
6c76f91398
fix(config): deepcopy config where needed
2024-11-06 22:36:37 +01:00
Folke Lemaitre
084fdf7d79
docs: more docs...
2024-11-06 17:49:10 +01:00
Folke Lemaitre
82ea3e68c4
docs: moar docs
2024-11-06 11:43:50 +01:00
Folke Lemaitre
66810971b9
fix(win): better implementation of window styles (previously views)
2024-11-06 10:56:08 +01:00
Folke Lemaitre
39a63ce2a3
refactor(win): move opts.win.* to opts.*
2024-11-06 08:07:36 +01:00
Folke Lemaitre
ab96f81574
refactor(notifier): moved padding stuff to win
2024-11-06 07:57:48 +01:00
Folke Lemaitre
efc96996e5
feat(notifier): add 1 cell left/right padding and make wrapping work properly
2024-11-05 20:05:11 +01:00
Folke Lemaitre
a06e3ed8fc
fix(win): dont update win opt noautocmd
2024-11-05 20:05:11 +01:00
Folke Lemaitre
71dd912763
fix(win): backdrop
2024-11-05 20:05:11 +01:00
Folke Lemaitre
2434264446
refactor(win): snacks_float => snacks_win
2024-11-05 17:03:30 +01:00
Folke Lemaitre
f3b69a617a
fix(win): use syntax as fallback for treesitter
2024-11-05 16:54:58 +01:00
Folke Lemaitre
ac1a50c810
feat(win): better api to deal with sizes
2024-11-05 16:54:58 +01:00
Folke Lemaitre
80d9a894f9
perf(win): set options with eventignore and handle ft manually
2024-11-05 16:54:58 +01:00
Folke Lemaitre
8c43597f10
fix(win): dont error when augroup is already deleted
2024-11-05 16:54:58 +01:00
Folke Lemaitre
7a7f221020
fix(win): no need to set EndOfBuffer winhl
2024-11-05 16:54:58 +01:00
Folke Lemaitre
12d6f863f7
feat(win): custom views
2024-11-04 22:17:12 +01:00
Folke Lemaitre
1bdb193139
refactor: float -> win, since it also manages splits
2024-11-04 20:29:25 +01:00