What I can think so far is
1 Make a transparent box, but with solid line segment at eight corners of one box.
2 Once an obect selected by cursor, scale the box acoording to the size of the selected object, and postion the box to the selected object.
This method is kind of ugly, because the solid line segmane also can be scaled, it goes thin or thigh.
renderLine is part of immediate rendering functionality, means it will only render once after executing the function, and will not preserve the object. So it is easier to use it for debugging and arbitrary rendering on demand.
Here comes the problems!
Those lines are implemented using WebGL which is based on native support by GPU and driver, and sad story, in OpenGL and DirectX support for lines wider than 1px is very inconsistent, leading to it be unsupported virtually.
So if you need fat lines, then you would need to implement own line renderer…
Looks like you have miss-configured VSM shadows bias.