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

Fix colorizer not working when changing vim.opt.background #94

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

cameronr
Copy link

@cameronr cameronr commented Nov 9, 2024

It seems like USER_DEFAULT_OPTIONS can get changed but the defaults are still needed later. Use a deepcopy to make sure the defaults are preserved.

Fixes #93

Repro:
1. start nvim with an empty buffer
2. open a file with highlights
3. switch to light mode (set vim.opt.background)
4. close the file with highlights
5. reopen that same file

Expected: colors are highlighted
Actual: nothing is highlighted because all rules are turned off
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

Successfully merging this pull request may close these issues.

Bug: Stops working after changing vim.opt.background
1 participant