vim icon indicating copy to clipboard operation
vim copied to clipboard

Support for LspReferenceRead (native LSP symbol highlight)

Open samhh opened this issue 3 years ago • 3 comments

Nord doesn't appear to support LspReferenceRead (or its siblings, though I'm unclear when those are relevant).

At the moment I'm doing this to hack in highlight support.

samhh avatar Jan 02 '21 13:01 samhh

From the spec

The document highlight request is sent from the client to the server to resolve a document highlights for a given text document position. For programming languages this usually highlights all references to the symbol scoped to this file. However we kept ‘textDocument/documentHighlight’ and ‘textDocument/references’ separate requests since the first one is allowed to be more fuzzy. Symbol matches usually have a DocumentHighlightKind of Read or Write whereas fuzzy or textual matches use Textas the kind.

If it is a location where it's being written to the found reference then it should be highlighted with LspReferenceWrite, if it's being read from LspReferenceRead, and if it's unclear it's LspReferenceText

jan-xyz avatar Jul 10 '21 17:07 jan-xyz

Thank you for your patience! 🙏🏼 It‘s been a while since I had free time to focus more on Nord, and my open source projects in general, and invest time in this issue due to work-life balance.

I recently published the first “Northern Post — The state and roadmap of Nord“ announcement which includes all details about the plans and future of the Nord project, including the goal of catching up with the backlog. This issue is part of the backlog and therefore I want to triage and process it to get one step closer to a “clean state“. Read the announcement about reaching the “clean“ contribution triage state in Nord‘s discussions for more details about the goal.

Therefore it has been added for triage in the central and single-source-of-truth project board that is also described in more detail in the roadmap announcement.


@samhh Thanks again for your contribution and example implementation. I guess this has been implemented in the meantime through #284 and the LspReferenceRead syntax group is now supported, next to other LSP features. Would be nice if you could quickly check if this solves this issue :smile:

svengreb avatar Jun 04 '23 08:06 svengreb

Hey @svengreb! Totally resonate with how the outside world can affect the velocity of open source contributions. Certainly focus on you and your life first.

In my case I've moved on from Nord to Kanagawa, so I'm no longer in a place to verify.

samhh avatar Jun 04 '23 10:06 samhh