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

colorized areas in buffer show up at the same spot inside of the completion menu #126

Open
LosFarmosCTL opened this issue Oct 21, 2024 · 3 comments

Comments

@LosFarmosCTL
Copy link

When there are highlights inside of the main open buffer, they show up at the exact same spot (line, column) in the nvim-cmp completion menu as well. The conditions under which they show up are a bit weird though, I am not 100% sure what actually causes them to render, since for example in the screenshot below they start showing up once you have typed out red completely (so neither on re or r while typing the first time), stay around even if you delete one character and go back to re, but vanish again once you delete another one and are at only r. I've appended a video of that as well, along with another weird example using white, as well as the CSS file in which I noticed the issue, for reproduction.

This entire issue is happening even without the formatting extension for nvim-cmp, my config for this plugin is also completely empty.

The entire CSS file from the screenshots/video:

body {
  background-color: red;
  background-image: url(background.png);
}
h1 {
  color: rgb(255, 166, 0);
  text-align: center;
  font-family: Bahnschrift;
}

.location-container {
  display: flex;
  flex-direction: column;
}

.location {
  background-color: white;
  width: 300px;
  &:hover {
    background: rgba(173, 173, 173, 0.856);
    animation: cubic-bezier(0.075, 0.82, 0.165, 1);
  }
  text-align: center;
  margin-bottom: 15px;
  font-family: Bahnschrift;
  border-radius: 6px;
  box-shadow:
    0 2px 8px 0 rgba(0, 0, 0, 0.2),
    0 2px 5px 0 rgba(0, 0, 0, 0.19);
  background: ;
}

.location-surrounding {
  display: flex;
  justify-content: center;
}
.add-container {
  display: flex;
  justify-content: center;
  margin-right: 200px;
}
.header {
  display: flex;
  justify-content: space-between;
  margin-left: 43%;
}

image
Screen.Recording.2024-10-21.at.16.12.19.mov
@brenoprata10
Copy link
Owner

I will take a look if more people report this issue, as I am unable to reproduce it on my PC :(

@LosFarmosCTL
Copy link
Author

Oh weird, I'll try to investigate it some more when I have time.

@wingedseraph
Copy link

Same problem, you can get rid of it by disabling the lsp related function: highlight_lsp_document_color (utils.lua:226). lsp related things will stop working, but static elements will be highlighted correctly

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