Filters behavior in Filters sidebar

Discussion related to "Everything" 1.5 Alpha.
Post Reply
letmeindude
Posts: 15
Joined: Sat Jun 07, 2014 7:53 am

Filters behavior in Filters sidebar

Post by letmeindude »

(Love the Filters sidebar, thank you very much)

Lets say you have 3 filters (2 extension filters and 1 path filter):

.txt
.url
C:\Music

If you select first 2 filters (using Ctrl) Everything will search for only .txt and .url files. Makes sense.
But if you select all 3 filters Everything will search for .txt and .url files and ALL the files and folders in C:\Music.
I get it, but in my opinion it should search for only .txt and .url files in C:\Music.

What do you think, could be a tweak?

P.S. Double click a filter to edit it. Or right click - Edit Filter context menu item.
void
Developer
Posts: 16735
Joined: Fri Oct 16, 2009 11:31 pm

Re: Filters behavior in Filters sidebar

Post by void »

Thank you for your feedback letmeindude,

Having two filter sidebars might help here.
The two filter sidebars would be ANDed together.
In theory you could select .txt and .url on one and c:\music in the other.


Specify OR and AND groups might be messy and tedious.
P.S. Double click a filter to edit it. Or right click - Edit Filter context menu item.
Right click -> Edit is on my TODO list.
Thank you for your suggestions.
Mizufluffy
Posts: 62
Joined: Sun Jun 13, 2021 10:22 am

Re: Filters behavior in Filters sidebar

Post by Mizufluffy »

letmeindude wrote: Tue Nov 09, 2021 9:34 pm But if you select all 3 filters Everything will search for .txt and .url files and ALL the files and folders in C:\Music.
I get it, but in my opinion it should search for only .txt and .url files in C:\Music.
By this logic selecting ".txt" and ".url" filters would not find any files because no file can be both .txt and .url at the same time.

Let's test this idea with Video and Audio filters. If we select them both on the sidebar and start typing a word, for example "night", in the search field then we get all video and audio files where the search word "night" is in the file name.

The basic filters such as Video and Audio can be typed in the search field like this, audio: video:
However, if we type them exactly like that then it tries to find all files that are simultaneously both audio and video. To make it work with the previous example those filters needs OR operator rather than AND (audio: | video:). Together with a search word it would look like this:

Code: Select all

<audio: | video:> night
Here I have grouped audio and video filters together, otherwise I'd have to type "night" twice (night audio: | night video:).
So far we have two filters and a word search. To have filters working together they are separated by OR but ANDed with the search word.

If we next add a new filter, one that finds files in a path, for example your C:\Music, then the search would look something like this:

Code: Select all

<audio: | video: | path:C:\Music> night
If we open this search a little then we get the following search:

Code: Select all

night audio: | night video: | night path:C:\Music
In other words it can find "night audio:" files anywhere (even outside of "C:\Music"), "night video:" files anywhere and any "night" files under path:C:\Music. This is because all filters receive equal treatment on the sidebar (all are separated by OR operator).

If you want to use filters in the way you described then one way is to assign a macro to a filter and type them in the search field. For example "textfile" macro to filter "ext:txt", "urlfile" macro to filter "ext:url" and "cmusicpath" to filter "path:C:\Music". Then you can search for

Code: Select all

<textfile: | urlfile:> cmusicpath: 
Or, you could type in the search field something like this:

Code: Select all

ext:txt;url C:\Music
which finds all files with extension txt or url in path C:\Music.
void
Developer
Posts: 16735
Joined: Fri Oct 16, 2009 11:31 pm

Re: Filters behavior in Filters sidebar

Post by void »

By this logic selecting ".txt" and ".url" filters would not find any files because no file can be both .txt and .url at the same time.
Each individual sidebar would still OR multiple selected filters.
Selecting .txt and .url in one filter sidebar = ".txt" | ".url"
Selecting C:\Music in the other filter sidebar = C:\music
ANDing these two filter sidebars together = <".txt" | ".url"> C:\music

It's not ideal (have to work with two panes), multiple filter sidebars is just an idea at this stage.
This would also work with multiple filter locations, for example you might have two filters C:\music and D:\music.
Maybe tabs would work? each tab is ANDed.


I have plans to add a favorites to the Folders sidebar too, which would allow you to 'bookmark' locations.
letmeindude
Posts: 15
Joined: Sat Jun 07, 2014 7:53 am

Re: Filters behavior in Filters sidebar

Post by letmeindude »

Great, thank you. Whatever you implement I'll be happy (except maybe tabs).
void
Developer
Posts: 16735
Joined: Fri Oct 16, 2009 11:31 pm

Re: Filters behavior in Filters sidebar

Post by void »

Everything 1.5.0.1285a adds double click to edit a filter in the filters sidebar.

Everything 1.5.0.1285a also adds a right click menu with the option to edit the selected filter in the filters sidebar.
Post Reply