Unable to select text in SonarLint Rule Description view / Text is rendered as an image

  • Operating system: Debian Trixie
  • Eclipse version: 2024-03 (4.31.0)
  • SonarLint plugin version: 10.0.1.81733
  • Programming language you’re coding in: Java
  • Is connected mode used: no

Description

It is not possible to select most text in the SonarLint Rule Description view by dragging over it with a mouse, or by any other means really. Text inside of a code block can be selected, but is rendered with a proportional font, which irks me a little.

For example:

It seems to me that all text outside of code blocks is rendered as an image - it also disappears momentarily when resizing the view, while text inside of code blocks does not. I am not sure if this is fallback behaviour due to a problem with my setup, but I couldn’t find anything in the logs.

I was able to reproduce this issue in a fresh workspace.

Steps to reproduce

  1. Find a SonarLint marker
  2. Open the rule description, either by hover popup or the quick fix menu
  3. Try selecting (dragging over) text in the SonarLint Rule Description view

Hi,

Welcome to the community and thanks for this report!

Would you mind sharing why you want to copy the rule text?

 
Thx,
Ann

Hi,
copying rule text is not a very big concern to me, but I believe I first noticed this when I tried to copy the rule title to search for the rule in the preferences, though I forgot to mark the rule title as non-selectable in my example image.
However, besides selecting text, there are other issues which I believe are caused by this:

  • weird pop-in of rule text when opening the view, I imagine because the image has to be generated
  • graphical issues with resizing as I’ve mentioned before
  • inability to follow hyperlinks in rules, including the “More Info” tab which usually contains only links
1 Like

Hi,

Thanks for the details. I’ve flagged this for the team.

 
Ann

1 Like

Hey @anon82108692,

thanks for reaching out. The SonarLint Rule Description view is currently built partly using the browser that is configured for Eclipse and native elements. This is will eventually be removed and replaced with only native elements - the ones that are selectable for you.
In that case you’re right that it looks like an image that needs to be generated while in the background it is actually generating the HTML.

But that outgoing links do not work anymore seems new to me and therefore a regression. I’ve created a TICKET for that to be fixed soon.

Best,
Tobias

Hi,
thanks a lot!