Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FR: customizable yank highlight duration #1

Open
chrisgrieser opened this issue Dec 18, 2023 · 4 comments
Open

FR: customizable yank highlight duration #1

chrisgrieser opened this issue Dec 18, 2023 · 4 comments

Comments

@chrisgrieser
Copy link

Thx for this, been wanting for a more stable yank highlight for a while :)

Would it be possible to customize the duration of the yank highlight?

@aleksey-rowan
Copy link
Owner

Yes, of course. I was thinking about adding some options.

Is there anything else you think would be helpful to make customizable apart from the duration of the animation? I had three things on my list:

  • option to change highlight duration
  • option to change the colour of highlight
  • option to supress in visual mode (cause you already see the selection)

@chrisgrieser
Copy link
Author

  • duration of course makes sense
  • not sure about color – by using one of the built-in Obsidian CSS variables, the highlight inherits the color set by the theme, which already makes sense for me.
  • no highlight in visual would be useful, but highlighting yanks from visual mode is also how nvim does it, and you could argue to keep it consistent with vim.

Rather than providing niche customization options, something which I'd like to have more highlighting operations, such as highlighting paste (done by nvim-yanky) or highlighting undos (done by this plugin)

@aleksey-rowan
Copy link
Owner

Rather than providing niche customization options, something which I'd like to have more highlighting operations, such as highlighting paste (done by nvim-yanky) or highlighting undos (done by this plugin)

These are some good ideas (and plugins). Thank you!

I'll add the duration option first and then try to incorporate something from the plugins you shared.

@HaloGamer33
Copy link

I've added the highlight duration option on this pull request. Amazing plugin btw.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants