Page 1 of 2

Quick search - search for filesize

Posted: 2018-08-06, 09:49 UTC
by deus-ex
I'd like to request a simple enhancement of the quick search feature. Presently you can quick search for filenames in the filewindow by typing in letters and numbers into the quick search field. I'd like to be able to quick search by filesize, too. This is especially useful in branch view on a huge set of files, allowing to quickly move the cursor to a file(s) with a certain filesize. I imagine a second input field next to the quick search field, which accepts numbers only, would by sufficient.

Re: Quick search - search for filesize

Posted: 2018-08-06, 13:02 UTC
by Vochomurka
First, if you switch to "Advanced" tab in "Find Files" dialog, you will see the "File size" controls with many options.
Second, in branch view you mention it is easy to visually find specific size.

I don't see any sense in adding the "Size" field in quick search window

Re: Quick search - search for filesize

Posted: 2018-08-06, 14:02 UTC
by deus-ex
Vochomurka wrote: 2018-08-06, 13:02 UTC First, if you switch to "Advanced" tab in "Find Files" dialog, you will see the "File size" controls with many options.
Second, in branch view you mention it is easy to visually find specific size.
I do now this functionality very well, however this does not belong here at all. This topic is about expanding the quick search functionality.
I don't see any sense in adding the "Size" field in quick search window
Then reread my request which includes a usage example, you might find a sense then.

Re: Quick search - search for filesize

Posted: 2018-08-06, 14:24 UTC
by Dalai
deus-ex wrote: 2018-08-06, 09:49 UTCI imagine a second input field next to the quick search field, which accepts numbers only, would by sufficient.
And the next person imagines a third input field for date, and the next an input field for attributes, and the next ...? I hope you get the idea.

You could make use of the search function, maybe saving them so you can access them via Num+ and/or Ctrl+F12 (Show > Custom).

Regards
Dalai

Re: Quick search - search for filesize

Posted: 2018-08-06, 15:46 UTC
by deus-ex
Dalai wrote: 2018-08-06, 14:24 UTCAnd the next person imagines a third input field for date, and the next an input field for attributes, and the next ...? I hope you get the idea.
And if so, what's the problem? That is hardly a argument against my suggestion. By default the quick search input box isn't visible until the user calls the functionality. Furthermore, any additional search field can be implemented either as optional field that could be toggled via an configuration dialog, or the existing quick search dialog could be reused and expanded by some radio-button logic allowing to switch between filename, filesize and what-not search.

If anybody would be so reluctant to additions and improvements, we would still be running Window Commander v1.0. There are many functions and options available in TC that I do not use and require and never asked for, but I understand that there are many other users who requested and are grateful for those. If nothing else, it is the plethora of options and functionality which makes TC stand out from the competition.

Dalai wrote: 2018-08-06, 14:24 UTCYou could make use of the search function, maybe saving them so you can access them via Num+ and/or Ctrl+F12 (Show > Custom).
Running a normal search for a certain filesize, you are presented with the files matching the search criteria, all other files are inaccessible (not visible in the filewindow) at this moment, until you reset the search criteria and reread the source. This is inconvenient and time consuming, especially when working with a huge set of files in branch view, like I described in the example of my initial post. Also, this time consuming search has to be reprocessed for each and every individual filesize. For the same reason the quick search for filenames was invented in the first place, with the label "quick" being key.

Re: Quick search - search for filesize

Posted: 2018-08-06, 16:11 UTC
by Hacker
deus-ex,
This can be done using QuickSearch eXtended.

Roman

Re: Quick search - search for filesize

Posted: 2018-08-06, 18:08 UTC
by deus-ex
Hacker wrote: 2018-08-06, 16:11 UTCThis can be done using QuickSearch eXtended.
Hi Roman,

thanks for the tip. I already had a look at this tool earlier this day but could not find any hints in the manual whether it supports quick search for filesize. So I installed it now, yet I can't seem to figure out how to do a quick search for filesize. As you seem to know how, can you please provide a little guidance?

Re: Quick search - search for filesize

Posted: 2018-08-06, 21:18 UTC
by Hacker
deus-ex,
Sure. Not out of the box, unfortunately, but you can write a very simple WDX using WinScript Advanced, this should not take longer than 30 minutes from start to end, if you know a little bit of AHK (you need 2 lines of script). Then take a look at how to filter by content plugins using QSX.

HTH
Roman

Re: Quick search - search for filesize

Posted: 2018-08-06, 23:18 UTC
by deus-ex
Well, that's quite a far cry from what one could expect when you wrote "This can be done using QuickSearch eXtended". Thank you for trying to help, much appreciated. So my initial request to expand TCs quick search feature remains active.

Re: Quick search - search for filesize

Posted: 2018-08-06, 23:35 UTC
by petermad
2deus-ex
yet I can't seem to figure out how to do a quick search for filesize
I don't use QSE myslef, but acording to the manual you can use any wdx plugin, so you can just use a wdx that provides filesize (there are many) and set it up under the tab "Content plugins" - page 4 and 6 in the manual.

Re: Quick search - search for filesize

Posted: 2018-08-10, 17:08 UTC
by Usher
I think that most users don't know exact file size, so such quick search is useless for them. I prefer to save selection defined for search and use it as a custom view (f.e. show files larger than 1 GiB). But it's not a perfect solution as I cannot define filesize range (f.e. between 1 GiB and 2 GiB). And such a feature would be welcome by many users, I think.

Re: Quick search - search for filesize

Posted: 2018-08-10, 17:30 UTC
by Horst.Epp
Usher wrote: 2018-08-10, 17:08 UTC I think that most users don't know exact file size, so such quick search is useless for them. I prefer to save selection defined for search and use it as a custom view (f.e. show files larger than 1 GiB). But it's not a perfect solution as I cannot define filesize range (f.e. between 1 GiB and 2 GiB). And such a feature would be welcome by many users, I think.
This can be done using Everything sytax in TC search.
The following finds all entries between 100 and 200mb for example:
ev:size:>100mb size:<200mb
or
ed:size:>100mb size:<200mb
Look on the Everything search syntax for more info.

Re: Quick search - search for filesize

Posted: 2018-08-10, 18:18 UTC
by Dalai
Usher wrote: 2018-08-10, 17:08 UTC[...] as I cannot define filesize range (f.e. between 1 GiB and 2 GiB).
Yes, you can with the Plugins tab:

Code: Select all

tc | size | > | 1 | Gbytes
tc | size | < | 2 | Gbytes
You can reduce the rules by one when combining it with the size option on the Advanced tab.

Regards
Dalai

Re: Quick search - search for filesize

Posted: 2018-08-11, 10:11 UTC
by Usher
Dalai wrote: 2018-08-10, 18:18 UTC Yes, you can with the Plugins tab
You can reduce the rules by one when combining it with the size option on the Advanced tab.
Ahaaa… Thanks for a very good hint.

Re: Quick search - search for filesize

Posted: 2018-08-21, 00:01 UTC
by Hacker
deus-ex,
WinScript Advanced 1.7

options.ini

Code: Select all

[Script] 
ActiveScripts=FileSize

[FileSize]
Script=FileSize.ahk
content=FileSize
extensions=*
FoldersPaths=1
FileSize.ahk

Code: Select all

#NoTrayIcon
SetBatchLines, -1

FileGetAttrib, Attributes, %FileName%
IfInString, Attributes, D
{
	DirSize = 0
	Loop, Files, %FileName%\*.*, FR
		DirSize += %A_LoopFileSize%
	Content = %DirSize%
}
Else
	FileGetSize, Content, %FileName%
tcmatch64.exe
Content Plugins
- Choose content plugin file - C:\Totalcmd\Plugins\Content\WinScript Advanced\WinScriptsAdv.wdx64
- Fields of the content plugin - FileSize
- Choose group - 2
- Add
- VV

QuickSearch eXtended
/123456789
(where 123456789 is the filesize being searched for in bytes)

HTH
Roman