Bug 386309 - [package explorer] Dynamic filter for the package explorer based on name
Summary: [package explorer] Dynamic filter for the package explorer based on name
Status: CLOSED DUPLICATE of bug 149110
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.2   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-07-31 08:25 EDT by Lars Vogel CLA
Modified: 2015-03-07 04:50 EST (History)
9 users (show)

See Also:


Attachments
Screenshot (10.56 KB, image/png)
2012-07-31 08:25 EDT, Lars Vogel CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Vogel CLA 2012-07-31 08:25:00 EDT
Created attachment 219362 [details]
Screenshot

Since a while I used a self-written clone of the package explorer. I recently changed that to a modified version of the JDT package explorer. My little enhancements allows to type in filter for the project name and filter the tree.

Screenshot attached.

Is that something you would consider as enhancements for the standard JDT Package Explorer? If yes, I'm happy to contribute it, if not, please feel free to close this bug.
Comment 1 Andrey Loskutov CLA 2012-07-31 09:23:13 EDT
See also bug 226046, where similar request is made for the common navigator (Project Explorer, C++ Projects Explorer etc).

The subtle difference for JDT is that it already provides name filters, but they are hidden in "Filters..." view menu.

It would be nice if we could have one consistent solution for all "explorers" or explorer-like structures like "Problems view", where I also would like to see a quick text filter.

Please consider to make this text filter line optional for those users with limited screen sizes.

Other (bad) example for same functionality is the Error log view, where the "filter text" field was added by default (and you can't turn it off even if you don't need it).
Comment 2 Thorsten Richter CLA 2012-07-31 09:44:06 EDT
@Andrey: The "Filters..." view menu does only support exclusion filters - like a blacklist.
Lars is suggesting an inclusion filter - like a whitelist.
I would love to see this quick filter in JDT. I think it would have saved me a lot of time.

@Lars: Thanks for your feature patch, I'm gonna install it.
Comment 3 Andrey Loskutov CLA 2012-07-31 09:55:36 EDT
(In reply to comment #2)
> @Andrey: The "Filters..." view menu does only support exclusion filters -
> like a blacklist.
> Lars is suggesting an inclusion filter - like a whitelist.

So you see that even experienced Eclipse users (me :-)) are confused by lot of different and partly incompatible/opposite implementations in the standard IDE plugins (not to mention all the 3rd party tools).

So yes, I would like to see quick filter too, implemented for all common views, with common look and feel/behavior (like preference to hide it).
Comment 4 Andrey Loskutov CLA 2012-07-31 09:57:05 EDT
(In reply to comment #3)
> So yes, I would like to see quick filter too, implemented for all common
> views, with common look and feel/behavior (like preference to hide it).

... and in the ideal world the code adding this text filter would be a public common API, so that all 3rd party plugin developers could re-use it for their own views.
Comment 5 Lars Vogel CLA 2012-07-31 10:00:31 EDT
I pushed the changes to a the "filterpackageexplorer" branch in to https://github.com/vogella/jdt-package-explorer/ 

The commit is commit/97a8c0d31938112a6d39e3a7cada8538590f3b58 Looks like I committed a lot of whitespace but the change should be identifiable for people which would like to look at the changes. If there is interest I can redo the change and try to avoid whitespace changes.
Comment 6 Lars Vogel CLA 2012-07-31 10:04:12 EDT
@Andrey, I think it is public API of the JFace TreeViewer, I could have used the ViewerFilter class. Now that I said it I feel bad and most likely will soon change my implementation.
Comment 7 Tobias Preuss CLA 2012-07-31 12:36:25 EDT
I would love to see the white-list filter becoming part of the next Eclipse release, too.
Comment 8 Dani Megert CLA 2012-08-02 03:44:49 EDT
See also bug 69200.

*** This bug has been marked as a duplicate of bug 149110 ***