SpartanJ / ecode

Lightweight multi-platform code editor designed for modern hardware with a focus on responsiveness and performance.
MIT License
919 stars 13 forks source link

Unable to view the full diagnostic by clangd #335

Closed Curculigo closed 1 week ago

Curculigo commented 1 week ago

The diagnostic by clangd is in red color. There is no horizontal scrollbar.

SpartanJ commented 1 week ago

You're referring to the code lens (code lens is the thing in the right, tooltip is the thing in the left)? Because code lens are just a preview of the full information that can be accessed from the tooltip displayed when you hover the error over the text, or you press F1 with cursor positioned over the error. Code Lens will never have enough space to display a huge error, and adding horizontal scroll doesn't make sense since it's not part of the document (it's literally a quick preview). The issue you mentioned was about the tooltip, which wasn't wrapping text. If issue is different please provide a screenshot so I can understand.

Screenshot_20240923_113006

Curculigo commented 1 week ago

Yes, I mean code lens. Btw, is it possible to turn off code lens?

SpartanJ commented 1 week ago

Btw, is it possible to turn off code lens?

Sure, it's a linter feature so you need to go to Tools -> Plugin Manager -> Select "Linter" -> click "Preferences" and then set enable_error_lens to false.

All plugins options are explained in ecode's README here. You have plenty of configuration there, but lacks some visibility, that needs to be improved.

For the moment I won't change its current behavior, it's intentional to be just a quick preview, I don't like changing the document view-port size over something that it's not part of the document, I could add a mouse hover over the lens zone and display the same error than the text zone, but I don't see a good reason to do it, I might add it though.