This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Created attachment 139458 [details] Shows the issue ACTUAL: Search results contain the whitespaces from its indentation - see screenshot. Does it makes sense when you search for a non-whitespace text, that you want to see the whitespaces at the left? EXPECTED: Search results are left-trimmed of the whitespaces
Actually, the indentation is currently shown intentionally :-) I think that the white-space at the beginning makes it easier to see where the occurrence is (e.g. in a top-level class vs. in an inner class), and can be helpful sometimes. CCing uireviews. Please, do you have any opinions or ideas?
In my opinion we should left-trim them, but that's speaking solely from the perspective of being consistent with other search results lists I've seen. I think adding the whitespace just makes it so you need to expand the window ever larger to see the line of code.
(In reply to richgunther from comment #2) > In my opinion we should left-trim them, but that's speaking solely from the > perspective of being consistent with other search results lists I've seen. Indeed, Find Usages Results Window also trims the line. Thanks. > I think adding the whitespace just makes it so you need to expand the window > ever larger to see the line of code. I agree, it would be an advantage for smaller displays to trim the results. Anyway, the context of the line is actually shown in tooltip. OK, I'll fix it. Thanks for reporting and your comments.
http://hg.netbeans.org/core-main/rev/9c844c2467d9 Fixed.
Integrated into 'main-silver', will be available in build *201309060001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/9c844c2467d9 User: Jaroslav Havlin <jhavlin@netbeans.org> Log: #235276: Search results should be left-trimmed