Let's make sure issue is not already fixed in latest builds first.
Steps to reproduce
Create a text file with the following 3 lines:
ABC
ABCBC
ABCDCDC
Then do a file search on the file and search for "A". The label of the search view says "3 matches in ..." OK
Then repeat the search and search for "B". The label of the search view says "4 matches in ... (showing 3 of 4 matches)" which is NOT OK because all matches are shown.
If you search for "C" the label will be "6 matches in ... (showing 3 of 6 matches)" which is also NOT OK.
Since all matches are shown in the search view the view should not report not shown matches.
Locking at the source code of the label generation in FileSearchPage.getLabel() the problem seams to be an incorrect comparison of lines (leaves in the tree) and matches in the first if branch that generates this label extension.
Tested under this environment:
- OS & version: Windows 11
- Eclipse IDE/Platform version (as shown in Help > About): 4.35
Community
Let's make sure issue is not already fixed in latest builds first.
Steps to reproduce
Create a text file with the following 3 lines:
ABC
ABCBC
ABCDCDC
Then do a file search on the file and search for "A". The label of the search view says "3 matches in ..." OK
Then repeat the search and search for "B". The label of the search view says "4 matches in ... (showing 3 of 4 matches)" which is NOT OK because all matches are shown.
If you search for "C" the label will be "6 matches in ... (showing 3 of 6 matches)" which is also NOT OK.
Since all matches are shown in the search view the view should not report not shown matches.
Locking at the source code of the label generation in FileSearchPage.getLabel() the problem seams to be an incorrect comparison of lines (leaves in the tree) and matches in the first if branch that generates this label extension.
Tested under this environment:
Community