Status Bar Format

Discussion related to "Everything" 1.5 Alpha.
Post Reply
void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Status Bar Format

Post by void » Thu Oct 21, 2021 5:41 am

To customize the status bar format:
  • In Everything 1.5.0.1281a or later, type in the following search and press ENTER:
    /statusbar_format=format
    where format can include the following:
    • $result-count:
    • $folder-result-count:
    • $file-result-count:
    • $selection-count:
    • $folder-selection-count:
    • $file-selection-count:
    • $total-result-size:
    • $total-selection-size:
    • $total-file-selection-size:
    • $total-result-length: (requires length indexing)
    • $total-selection-length: (requires length indexing)
The Everything Preprocessor is supported.

To format a number with a thousand separator, use the #TEXT: preprocessor function:

Code: Select all

#TEXT:<#result-count:,#,###> objects
Leave format empty to use the default format.



The default format is:
1,234,567 objects

Code: Select all

/statusbar_format=#if:<$result-count:==1,1 object,#TEXT:<$result-count:,#,###> objects>


Examples:
Basic syntax to show usage:
123456 folder(s); 1111111 file(s)

Code: Select all

$folder-result-count: folder(s); $file-result-count: file(s)


Show separate folder and file result counts:
123,456 folders; 1,111,111 files

Code: Select all

/statusbar_format=#if:<$folder-result-count:==1,1 folder,#TEXT:<$folder-result-count:,#,###> folders>; #if:<$file-result-count:==1,1 file,#TEXT:<$file-result-count:,#,###> files


Show total, folder and file result counts:
1,234,567 objects (123,456 folders; 1,111,111 files)

Code: Select all

/statusbar_format=#if:<$result-count:==1,1 object,#TEXT:<$result-count:,#,###> objects> (#if:<$folder-result-count:==1,1 folder,#TEXT:<$folder-result-count:,#,###> folders>; #if:<$file-result-count:==1,1 file,#TEXT:<$file-result-count:,#,###> files>)


To customize the status bar format when a single item is selected:
  • In Everything, type in the following search and press ENTER:
    /statusbar_selected_item_format=format
    where format can include the following:
    • #is-folder: = returns 1 if the selected item is a folder, 0 otherwise. (added in Everything 1.5.0.1281a)
    • $<property-name>: = returns the property value from the property name. (added in Everything 1.5.0.1281a)
    • $$ = A single literal $
    • $f = Full path and file name
    • $n = Name
    • $p = Path
    • $s = Size
    • $e = Extension
    • $t = Type
    • $m = Date modified
    • $c = Date created
    • $a = Date accessed
    • $b = Attributes
    • $d = Date recently changed
    • $r = Run count
    • $u = Date run
    • $l = File list filename
    • $o = Results count
The Everything Preprocessor is now supported.


To customize the status bar format when multiple items are selected:
  • In Everything, type in the following search and press ENTER:
    /statusbar_selection_format=format
    where format can include the following:
    • $result-count:
    • $folder-result-count:
    • $file-result-count:
    • $selection-count:
    • $folder-selection-count:
    • $file-selection-count:
    • $total-result-size:
    • $total-selection-size:
    • $total-file-selection-size:
    • $total-result-length: (requires length indexing)
    • $total-selection-length: (requires length indexing)
The Everything Preprocessor is supported.

Leave format empty to use the default format.

The default format is:
<$selection-count:,#,###> objects selected


Notes:
$total-result-length: and $total-selection-length: require Length property indexing.


TODO:
variations of statusbar_selected_item_format based on 'Kind' (like Windows Explorer)
add a $selection-kind: property to format based on the 'kind' from the selection.

ericgl
Posts: 8
Joined: Tue Apr 28, 2020 7:35 am

Re: Status Bar Format

Post by ericgl » Thu Oct 21, 2021 7:21 am

Thanks, void.
It works. Here's how I like it:

Code: Select all

/statusbar_format=#TEXT:<#folder-result-count:,#,###> folders; #TEXT:<#file-result-count:,#,###> files (#if:<#result-count:==1,1 object,#TEXT:<#result-count:,#,###> total objects>)

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Thu Oct 21, 2021 2:41 pm

nice nice nice nice nice nice nice nice nice nice nice nice

JTB3
Posts: 12
Joined: Fri Apr 08, 2016 7:15 pm

Re: Status Bar Format

Post by JTB3 » Wed Oct 27, 2021 7:28 am

UPDATED (10-Dec-2021): Cleaned-up code and added new code for single-selection status bar.
Thanks for adding this great customization feature, David!

Below are code snippets for my new favorite custom status bar(s):
Features: 1) only shows 'objects' when there are both 'files' and 'folders', 2) doesn't show file or folder counts if they are zero, and 3) properly appends the plural 's' only if there is more than one file(s) or folder(s).

For the standard status bar:

Code: Select all

/statusbar_format= Found: #IF:<#AND:<#folder-result-count:,#file-result-count:>, #TEXT:<#result-count:,#,###> objects |,>#IF:<#folder-result-count:, #TEXT:<#folder-result-count:,#,###> folder#IF:<#folder-result-count:==1,,s>,>#IF:<#file-result-count:,#IF:<#folder-result-count:,#comma:,> #TEXT:<#file-result-count:,#,###> file#IF:<#file-result-count:==1,,s>,>
For the multi-selection status bar:

Code: Select all

/statusbar_selection_format= Selected:  #TEXT:<#selection-count:,#,###> of #TEXT:<#result-count:,#,###> objects |#IF:<#folder-selection-count:, #TEXT:<#folder-selection-count:,#,###> folder#IF:<#folder-selection-count:==1,,s>,>#IF:<#file-selection-count:,#IF:<#folder-selection-count:,#comma:,> #TEXT:<#file-selection-count:,#,###> file#IF:<#file-selection-count:==1,,s>,>
And, for the single-selection status bar: [Note: one might want to customize this for your own specific 'properties']

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#len:<#length:>, | #length: #IF:<#elementcount:<#length:,#colon:>==3,h:,>m:s,>#IF:<#dimensions:, | #dimensions: px,>#IF:<#audiobitrate:, | Audio: #left:<#audiobitrate:,#len:<#audiobitrate:>-3> kbps,>#IF:<#videobitrate:, | Video: #left:<#videobitrate:,#len:<#videobitrate:>-3> kbps,> | Atr: $b | Modified: $m | Created: $c
This took quite a bit of time to perfect...
Give them a try, and enjoy! -JT :)
Last edited by JTB3 on Fri Dec 10, 2021 4:23 pm, edited 11 times in total.

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Wed Oct 27, 2021 7:41 am

Small bug with statusbar_format and alternative bracketing styles in preprocessor functions.

/statusbar_format=#if(:0,1,2)
-> 2)

/statusbar_format=#ifs{:0,1,2,3}
-> 3}

/statusbar_format=#<ifs:0,1,2,3>
-> 3>

/statusbar_format=#ifs:<0,1,2,3>
-> 3

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Wed Oct 27, 2021 7:45 am

This is expected, please try the following syntax:

/statusbar_format=#if(:0,1,2#):
/statusbar_format=#ifs{:0,1,2,3#}:
/statusbar_format=#<ifs:0,1,2,3#>:
/statusbar_format=#ifs:<0,1,2,3>


Syntax is:
#function(:parameter#):

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Wed Oct 27, 2021 8:07 am

void wrote:
Wed Oct 27, 2021 7:45 am
This is expected, please try the following syntax:
Ah hah. My bad. Strangely it doesn't leave a dangly bracket when using /=#... as in /=#ifs{:0,1,2,3}

Feel free to clean up after my thread-vandalism. Thanks!
Last edited by raccoon on Wed Oct 27, 2021 8:10 am, edited 1 time in total.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Wed Oct 27, 2021 8:14 am

Using the search command
/#if[:0,1,2#]:
currently does not expand.

It will expand in the next alpha update.


/=text
is the same as:
/#eval:<text>

For example:
/=1+2 => 3

JTB3
Posts: 12
Joined: Fri Apr 08, 2016 7:15 pm

Re: Status Bar Format

Post by JTB3 » Wed Oct 27, 2021 11:48 pm

JTB3 wrote:
Wed Oct 27, 2021 7:28 am
UPDATED (10-Dec-2021): Cleaned-up code and added new code for single-selection status bar.
Thanks for adding this great customization feature, David!

Below are code snippets for my new favorite custom status bar(s):
Features: 1) only shows 'objects' when there are both 'files' and 'folders', 2) doesn't show file or folder counts if they are zero, and 3) properly appends the plural 's' only if there is more than one file(s) or folder(s).

For the standard status bar:

Code: Select all

/statusbar_format= Found: #IF:<#AND:<#folder-result-count:,#file-result-count:>, #TEXT:<#result-count:,#,###> objects |,>#IF:<#folder-result-count:, #TEXT:<#folder-result-count:,#,###> folder#IF:<#folder-result-count:==1,,s>,>#IF:<#file-result-count:,#IF:<#folder-result-count:,#comma:,> #TEXT:<#file-result-count:,#,###> file#IF:<#file-result-count:==1,,s>,>
For the multi-selection status bar:

Code: Select all

/statusbar_selection_format= Selected:  #TEXT:<#selection-count:,#,###> of #TEXT:<#result-count:,#,###> objects |#IF:<#folder-selection-count:, #TEXT:<#folder-selection-count:,#,###> folder#IF:<#folder-selection-count:==1,,s>,>#IF:<#file-selection-count:,#IF:<#folder-selection-count:,#comma:,> #TEXT:<#file-selection-count:,#,###> file#IF:<#file-selection-count:==1,,s>,>
And, for the single-selection status bar: [Note: one might want to customize this for your own specific 'properties']

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#dimensions:, | #dimensions: px,>#IF:<#length:, | #format-duration:<#length:> #IF:<#elementcount:<#format-duration:<#length:>,#colon:>==3,h:,>m:s,>#IF:<#audiobitrate:, | Audio: #eval:<#audiobitrate:/1000> kbps,>#IF:<#videobitrate:, | Video: #eval:<#framerate:/1000> fps#comma: #eval:<#videobitrate:/1000> kbps,> | Atr: $b | Modified: $m | Created: $c
This took quite a bit of time to perfect...
Give them a try, and enjoy! -JT :)
Just wanted to quote/re-post this for the community since I made many edits to my original custom status bars and added a new code snippet for a custom 'single-selection' status bar.

Thanks for providing this great capability, David!
-JT
:)
Last edited by JTB3 on Fri Dec 10, 2021 4:24 pm, edited 3 times in total.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Thu Oct 28, 2021 5:33 am

Everything 1.5.0.1282a removes #special-result-count: and #special-selection-count:

Everything will now track separate file and folder counts for special items (Run Count, Date Run, Date Recently Change and Mixed file and folder results).


Everything 1.5.0.1282a fixes an issue with search preprocessor text not expanding in search commands.
For example:
/#if[:0,1,2#]:


Everything 1.5.0.1282a adds #result-count:, #folder-result-count:, #file-result-count: etc... to statusbar_selected_item_format.

adamantine
Posts: 179
Joined: Mon Jan 09, 2012 10:56 am

Re: Status Bar Format

Post by adamantine » Tue Nov 02, 2021 11:47 pm

1) thank you for the useful addition to et

2) at present my statusbar_selected_item_format= is:
$f        $s        $m        #length:        #audio-bits-per-sample:  #ifs:<#audio-sample-rate:==7874,7,#audio-sample-rate:==9000,9,#audio-sample-rate:==11025,11,#audio-sample-rate:==12000,12,#audio-sample-rate:==14000,14,#audio-sample-rate:==16000,16,#audio-sample-rate:==18000,18,#audio-sample-rate:==22050,22,#audio-sample-rate:==24000,24,#audio-sample-rate:==28000,28,#audio-sample-rate:==32000,32,#audio-sample-rate:==37800,37,#audio-sample-rate:==44100,44,#audio-sample-rate:==48000,48,#audio-sample-rate:==88200,88,#audio-sample-rate:==96000,96,#audio-sample-rate:==192000,192>  #audio-channels:
i found no simpler way to get the desired displaying of audio-sample-rate
(like i already have in the result list: 44 instead of 44100, 96 instead of 96000...)

the #child-count: property doesn't work: it displays nothing (in et-1281, and in 1282 too)
it's not a big problem for me, but seemingly it deserves to be mentioned here


3) currently my statusbar_selection_format= completely equals to statusbar_format=
#ifs:<#selection-count:==0,0,#selection-count:==1,1,#selection-count:#gt:1,#TEXT:<#selection-count:,#,###>>      #ifs:<#folder-selection-count:==0,0 folder,#folder-selection-count:==1,1 folder,#folder-selection-count:#gt:1,#TEXT:<#folder-selection-count:,#,###> folders>      #ifs:<#file-selection-count:==0,0 file,#file-selection-count:==1,1 file,#file-selection-count:#gt:1,#TEXT:<#file-selection-count:,#,###> files>                                                            #ifs:<#result-count:==0,0,#result-count:==1,1,#result-count:#gt:1,#TEXT:<#result-count:,#,###>>      #ifs:<#folder-result-count:==0,0 folder,#folder-result-count:==1,1 folder,#folder-result-count:#gt:1,#TEXT:<#folder-result-count:,#,###> folders>      #ifs:<#file-result-count:==0,0 file,#file-result-count:==1,1 file,#file-result-count:#gt:1,#TEXT:<#file-result-count:,#,###> files>
this is the newer experimental approach which i use on a daily basis (it will be kept if i don't concoct a better alternative). example:
2021 11 03   00 57 00.png
2021 11 03 00 57 00.png (116.59 KiB) Viewed 17352 times
there are 2 new areas on the left side of status bar. each area consists of 3 parts. so the left side displays:

- selected items
- selected folders
- selected files
- a big delimiter for visual conveniency
- all items
- all folders
- all files

it seems that there's no need to specify the object/objects/item/items word (in status bar): it's obvious in any case

the only thing that must be memorized is: the info about selections is placed before the info about total quantity of items/folders/files

harryray2
Posts: 817
Joined: Sat Oct 15, 2016 9:56 am

Re: Status Bar Format

Post by harryray2 » Thu Nov 11, 2021 8:17 am

I've just discovered that the filter dropdown box can be moved to the left.

As the status bar part box can't yet be moved to the left, can the colour, with the new customisations, be changed?
ie. Make the box Red as an alert that a filter or a search command is active.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Thu Nov 11, 2021 8:44 am

Thank you for the feedback.
i found no simpler way to get the desired displaying of audio-sample-rate
(like i already have in the result list: 44 instead of 44100, 96 instead of 96000...)
Please try the following:

#if:<#audio-sample-rate:,#eval:<#audio-sample-rate:/1000>,>

the #child-count: property doesn't work: it displays nothing (in et-1281, and in 1282 too)
it's not a big problem for me, but seemingly it deserves to be mentioned here
This will be fixed in the next alpha update.
As the status bar part box can't yet be moved to the left, can the colour, with the new customisations, be changed?
ie. Make the box Red as an alert that a filter or a search command is active.
Color customization is on my TODO list.

harryray2
Posts: 817
Joined: Sat Oct 15, 2016 9:56 am

Re: Status Bar Format

Post by harryray2 » Thu Nov 11, 2021 8:47 am

Thanks, any plans to enable the box to be moved?

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Thu Nov 11, 2021 8:56 am

@void Would you be inclined to add the ability to format #total-result-size: and #total-selection-size: from byte format to the automatic KB MB GB TB format as displayed in the bottom-right of the status bar?

I tried defining my own function using ifs: and eval: but invariably came up short with one hangup after another. Might have mucked around with it (with at least 3 different approaches) for 3 or 4 hours.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Thu Nov 11, 2021 9:15 am

Thanks, any plans to enable the box to be moved?
It's on my TODO list.
@void Would you be inclined to add the ability to format #total-result-size: and #total-selection-size: from byte format to the automatic KB MB GB TB format as displayed in the bottom-right of the status bar?
I've added a #format-size:<number[,format-type]> preprocessor function for the next alpha update.

eg:
#format-size:<1234> => 2 KB
#format-size:<1234567> => 1,206 KB
#format-size:<1234567890> => 1,205,633 KB
#format-size:<1,0> => 1 bytes
#format-size:<1234,0> => 1.20 KB
#format-size:<1234567,0> => 1.17 MB
#format-size:<1234567890,0> => 1.149 GB
#format-size:<1234,1> => 1,234
#format-size:<1234567,1> => 1,234,567
#format-size:<1234567890,1> => 1,234,567,890
#format-size:<1234,2> => 2 KB
#format-size:<1234567,2> => 1,206 KB
#format-size:<1234567890,2> => 1,205,633 KB
#format-size:<1234,3> => 0.01 MB
#format-size:<1234567,3> => 1.17 MB
#format-size:<1234567890,3> => 1,177 MB

adamantine
Posts: 179
Joined: Mon Jan 09, 2012 10:56 am

Re: Status Bar Format

Post by adamantine » Thu Nov 11, 2021 11:37 am

#if:<#audio-sample-rate:,#eval:<#audio-sample-rate:/1000>,>
it works, thank you. this shorter line is certainly a better and easier variant:
$f        $s        $m        #length:        #audio-bits-per-sample:  #if:<#audio-sample-rate:,#eval:<#audio-sample-rate:/1000>,>  #audio-channels:
 
 
I've added a #format-size:<number[,format-type]> preprocessor function for the next alpha update
looks like a good addition. because the current approach isn't usable (at least for me). example:
it's the unwanted 980040917 note now (instead of the desired 934 m note)

adamantine
Posts: 179
Joined: Mon Jan 09, 2012 10:56 am

Re: Status Bar Format

Post by adamantine » Sat Nov 13, 2021 9:52 am

1. currently i try to get the following order of notes on the left side of status bar:

- selected items (quantity)
- selected folders (quantity)
- selected files (quantity)
- selected items (size)
           a big delimiter for visual conveniency
- all items (quantity)
- all folders (quantity)
- all files (quantity)
- all items (size)

this is the experimental idea: to have all these 8 notes constantly visible
so that the content of the left side was not horizontally 'jumping' so often (and so much)

so with these ini-lines:...
statusbar_format=
#ifs:<#selection-count:==0,0,#selection-count:==1,1,#selection-count:#gt:1,#TEXT:<#selection-count:,#,###>>
#ifs:<#folder-selection-count:==0,0 folder,#folder-selection-count:==1,1 folder,#folder-selection-count:#gt:1,#TEXT:<#folder-selection-count:,#,###> folders>
#ifs:<#file-selection-count:==0,0 file,#file-selection-count:==1,1 file,#file-selection-count:#gt:1,#TEXT:<#file-selection-count:,#,###> files>
#total-selection-size:

#ifs:<#result-count:==0,0,#result-count:==1,1,#result-count:#gt:1,#TEXT:<#result-count:,#,###>>
#ifs:<#folder-result-count:==0,0 folder,#folder-result-count:==1,1 folder,#folder-result-count:#gt:1,#TEXT:<#folder-result-count:,#,###> folders> #ifs:<#file-result-count:==0,0 file,#file-result-count:==1,1 file,#file-result-count:#gt:1,#TEXT:<#file-result-count:,#,###> files>
#total-result-size:

 
statusbar_selection_format=
#ifs:<#selection-count:==0,0,#selection-count:==1,1,#selection-count:#gt:1,#TEXT:<#selection-count:,#,###>>
#ifs:<#folder-selection-count:==0,0 folder,#folder-selection-count:==1,1 folder,#folder-selection-count:#gt:1,#TEXT:<#folder-selection-count:,#,###> folders>
#ifs:<#file-selection-count:==0,0 file,#file-selection-count:==1,1 file,#file-selection-count:#gt:1,#TEXT:<#file-selection-count:,#,###> files>
#total-selection-size:

#ifs:<#result-count:==0,0,#result-count:==1,1,#result-count:#gt:1,#TEXT:<#result-count:,#,###>>
#ifs:<#folder-result-count:==0,0 folder,#folder-result-count:==1,1 folder,#folder-result-count:#gt:1,#TEXT:<#folder-result-count:,#,###> folders> #ifs:<#file-result-count:==0,0 file,#file-result-count:==1,1 file,#file-result-count:#gt:1,#TEXT:<#file-result-count:,#,###> files>
#total-result-size:
 
2021 11 11   13 07 13.png
2021 11 11 13 07 13.png (121.03 KiB) Viewed 15602 times
 
...strange and huge number appears as the 4th part of status bar:         18446744073709551615

the other big number (980040917) is correct: it's the size in bytes         (it's unwanted to see the size in bytes, but technically the size is correct)

i tried to solve the issue myself by altering the ini-file:
 
 
2. with these ini-lines:...           (in statusbar_format=       the 0 b note was added      instead of the #total-selection-size: note)
statusbar_format=
#ifs:<#selection-count:==0,0,#selection-count:==1,1,#selection-count:#gt:1,#TEXT:<#selection-count:,#,###>>
#ifs:<#folder-selection-count:==0,0 folder,#folder-selection-count:==1,1 folder,#folder-selection-count:#gt:1,#TEXT:<#folder-selection-count:,#,###> folders>
#ifs:<#file-selection-count:==0,0 file,#file-selection-count:==1,1 file,#file-selection-count:#gt:1,#TEXT:<#file-selection-count:,#,###> files>
0 b

#ifs:<#result-count:==0,0,#result-count:==1,1,#result-count:#gt:1,#TEXT:<#result-count:,#,###>>
#ifs:<#folder-result-count:==0,0 folder,#folder-result-count:==1,1 folder,#folder-result-count:#gt:1,#TEXT:<#folder-result-count:,#,###> folders> #ifs:<#file-result-count:==0,0 file,#file-result-count:==1,1 file,#file-result-count:#gt:1,#TEXT:<#file-result-count:,#,###> files>
#total-result-size:

 
statusbar_selection_format=
#ifs:<#selection-count:==0,0,#selection-count:==1,1,#selection-count:#gt:1,#TEXT:<#selection-count:,#,###>>
#ifs:<#folder-selection-count:==0,0 folder,#folder-selection-count:==1,1 folder,#folder-selection-count:#gt:1,#TEXT:<#folder-selection-count:,#,###> folders>
#ifs:<#file-selection-count:==0,0 file,#file-selection-count:==1,1 file,#file-selection-count:#gt:1,#TEXT:<#file-selection-count:,#,###> files>
#total-selection-size:

#ifs:<#result-count:==0,0,#result-count:==1,1,#result-count:#gt:1,#TEXT:<#result-count:,#,###>>
#ifs:<#folder-result-count:==0,0 folder,#folder-result-count:==1,1 folder,#folder-result-count:#gt:1,#TEXT:<#folder-result-count:,#,###> folders> #ifs:<#file-result-count:==0,0 file,#file-result-count:==1,1 file,#file-result-count:#gt:1,#TEXT:<#file-result-count:,#,###> files>
#total-result-size:
 
2021 11 13   07 59 32.png
2021 11 13 07 59 32.png (73.3 KiB) Viewed 15602 times
 
...the trick (with the manual addition of the 0 b note) seems to be working
because i only need to have the 0 b note in that place of status bar (when there are no selected items)
(when selected items exist, their size appears sans problems)

but later i noticed that the same strange and huge number appears as the 8th part of status bar:
when nothing is selected, like in the screen-shot-2 (but also when 2 or more items are selected)

(in the very end of statusbar_format=)      substituting the #total-result-size: note with the 0 b note doesn't help

added in ~10 minutes: the issue (with the 8th part of status bar) seems to be existing only if files are absent in result list

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Mon Nov 15, 2021 12:48 am

.strange and huge number appears as the 4th part of status bar: 18446744073709551615
#format-size: in the next alpha update should fix this.
This value is the largest size value which means the size is unknown.
I'll look into making this 0 instead.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Thu Nov 18, 2021 6:07 am

Everything 1.5.0.1285a makes some changes to the custom statusbar format:

#property: values are now requested in a background thread.


#property: values will now use their raw unformatted values.
For example:
#length: => 1039713437
#attributes: => 8224
#date-taken: => 131404956760000000
#size: => 138810

Use one of the following formatting preprocessor functions:
#format-duration:
#format-file-attributes:
#format-filetime:
#format-size:

For example:
#format-duration:<#length:> => 01:43
#format-file-attributes:<#attributes:> => AI
#format-filetime:<#date-taken:> => 29/05/2017 11:11
#format-size:<#size:> => 136 KB

Unknown values will appear blank/empty.
For example, if #size: is not known, #size: will return blank/empty text. (instead of 18446744073709551615)
Formatting blank/empty text will also return blank/empty text.


Added a #total-selection-length: function.
Added a #total-result-length: function. (needs to be optimized)
#total-result-length: and #total-selection-length: require Length property indexing.


Added support for #child-count:

adamantine
Posts: 179
Joined: Mon Jan 09, 2012 10:56 am

Re: Status Bar Format

Post by adamantine » Thu Nov 18, 2021 11:37 pm

#total-result-length: and #total-selection-length:
thank you for these functions

 
is there a way to remove the following duplications?:
 
2021 11 19   01 14 15.png
2021 11 19 01 14 15.png (252.18 KiB) Viewed 14163 times
 
in the upper instance of et:      the 297 m info is shown twice in status bar (the left copy is desired, the right copy is unwanted)
in the lower instance of et:      the 4 40 g info is shown twice in status bar (the left copy is desired, the right copy is unwanted)

the right copies are always unwanted

deactivation of the show total size in status bar option is not a solution because it leads to a disappearance of both copies

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Thu Dec 02, 2021 12:45 am

In Everything 1.5.0.1286a #total-result-size: and #total-selection-size: will work when show total size in status bar is disabled.

adamantine
Posts: 179
Joined: Mon Jan 09, 2012 10:56 am

Re: Status Bar Format

Post by adamantine » Thu Dec 02, 2021 2:33 am

#total-result-size: and #total-selection-size: will work
thank you. they really work now. it may seem to be a small aspect, but to me this is a substantial improvement

i've partially reconsidered my approach concerning the info in status bar. its current state can be seen here:
 
2021 12 02   03 52 29.png
2021 12 02 03 52 29.png (215.84 KiB) Viewed 10631 times
 
this screen-shot contains 5 instances of et:

1) nothing is selected. status bar displays:
quantity of all items, quantity of all folders, quantity of all files, size of all files (aka total size), duration of all audio-files

2) 1 audio-file is selected. status bar displays:
full path-name, size, date modified, duration, bits, kh, channels

3) 1 folder is selected. status bar displays:
full path-name, size, date modified, quantity of all items that are inside of this folder (the 'contains' word is used here)

 
4) 3 folders are selected. status bar displays 2 areas that are visually separated:
- quantity of all items, quantity of all folders, quantity of all files, size of all files, duration of all audio-files
- quantity of selected items, quantity of selected folders, quantity of selected files, size of selected folders

5) 4 files are selected. status bar displays 2 areas that are visually separated:
- quantity of all items, quantity of all folders, quantity of all files, size of all files, duration of all audio-files
- quantity of selected items, quantity of selected folders, quantity of selected files, size of selected files, duration of selected audio-files

JTB3
Posts: 12
Joined: Fri Apr 08, 2016 7:15 pm

Re: Status Bar Format

Post by JTB3 » Fri Dec 10, 2021 12:22 am

[BUG REPORT] Hi David,
Starting after Everything-1.5 Alpha build 1284, It appears that some of the #<property-name>: values being returned are now getting distorted. I noticed that my custom 'Single-Selection Status Bar' code is now producing erroneous values for the following #<property-name>'s:
  • #dimensions: now returns a value of '4294967295x4294967295' instead of a 'null' value (try selecting a folder or non-media or image file that has no dimensions using my code below).
  • #length: now returns some kind of integer value (for example, .mp3 file with a length of '5:34' is displayed as '3340277551'
These are the two 'property-name' values that I noticed immediately. There may be others that are also negatively being affected. I noticed this behavior all started happening in subsequent Alpha versions after v1284.

Here is my Single-Selection Status Bar code that demonstrates the issue (try selecting any audio or video file and see what happens):

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#len:<#length:>, | #length: #IF:<#elementcount:<#length:,#colon:>==3,h:,>m:s,>#IF:<#dimensions:, | #dimensions: px,>#IF:<#audiobitrate:, | Audio: #left:<#audiobitrate:,#len:<#audiobitrate:>-3> kbps,>#IF:<#videobitrate:, | Video: #left:<#videobitrate:,#len:<#videobitrate:>-3> kbps,> | Atr: $b | Modified: $m | Created: $c
The above code worked perfectly in Alpha versions up to and including v1284.

I hope you can get this functionality working again soon! Let me know if I can help with testing...
-JT :)
Last edited by JTB3 on Fri Dec 10, 2021 4:20 pm, edited 2 times in total.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Fri Dec 10, 2021 1:27 am

Thanks for the bug report JTB3,

1285 added more control over formatting property values.
#property: now returns the raw property value.
Format the property values with one of the formatting functions.

Invalid dimensions showing as 4294967295x4294967295 (or 4294967295x0) will be fixed in the next alpha update.

For now, please replace #dimensions: with:
#if:<#or:<#exact:<#dimensions:,4294967295x4294967295>,#exact:<#dimensions:,4294967295x0>>,,#dimensions:>


For length, please use #format-duration:<#length:>

Fow now, please try the following format:

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#length:, | #format-duration:<#length:> #IF:<#elementcount:<#format-duration:<#length:>,#colon:>==3,h:,>m:s,>#IF:<#if:<#or:<#exact:<#dimensions:,4294967295x4294967295>,#exact:<#dimensions:,4294967295x0>>,,#dimensions:>, | #dimensions: px,>#IF:<#audiobitrate:, | Audio: #left:<#audiobitrate:,#len:<#audiobitrate:>-3> kbps,>#IF:<#videobitrate:, | Video: #left:<#videobitrate:,#len:<#videobitrate:>-3> kbps,> | Atr: $b | Modified: $m | Created: $c

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Fri Dec 10, 2021 4:51 am

Everything 1.5.0.1289a will now return an empty string for invalid dimensions when using the #dimensions: preprocessor function.

Please try the following statusbar format with this version:

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#length:, | #format-duration:<#length:> #IF:<#elementcount:<#format-duration:<#length:>,#colon:>==3,h:,>m:s,>#IF:<#dimensions:, | #dimensions: px,>#IF:<#audiobitrate:, | Audio: #eval:<#audiobitrate:/1000> kbps>#IF:<#videobitrate:, | Video: #eval:<#videobitrate:/1000> kbps> | Atr: $b | Modified: $m | Created: $c

The following might also be useful:

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#length:, | #eval:<#length:/36000000000>h#text:<#eval:<(#length:/600000000)%60>,00>m#text:<#eval:<(#length:/10000000)%60>,00>s>#IF:<#dimensions:, | #dimensions: px,>#IF:<#audiobitrate:, | Audio: #eval:<#audiobitrate:/1000> kbps>#IF:<#videobitrate:, | Video: #eval:<#videobitrate:/1000> kbps> | Atr: $b | Modified: $m | Created: $c

JTB3
Posts: 12
Joined: Fri Apr 08, 2016 7:15 pm

Re: Status Bar Format

Post by JTB3 » Fri Dec 10, 2021 4:32 pm

void wrote:
Fri Dec 10, 2021 1:27 am
Thanks for the bug report JTB3,

1285 added more control over formatting property values.
#property: now returns the raw property value.
Format the property values with one of the formatting functions.

Invalid dimensions showing as 4294967295x4294967295 (or 4294967295x0) will be fixed in the next alpha update.
For length, please use #format-duration:<#length:>
For now, please try the following format:

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#length:, | #format-duration:<#length:> #IF:<#elementcount:<#format-duration:<#length:>,#colon:>==3,h:,>m:s,>#IF:<#if:<#or:<#exact:<#dimensions:,4294967295x4294967295>,#exact:<#dimensions:,4294967295x0>>,,#dimensions:>, | #dimensions: px,>#IF:<#audiobitrate:, | Audio: #left:<#audiobitrate:,#len:<#audiobitrate:>-3> kbps,>#IF:<#videobitrate:, | Video: #left:<#videobitrate:,#len:<#videobitrate:>-3> kbps,> | Atr: $b | Modified: $m | Created: $c
Wow, David! - Thanks so much for the fast response on this! - AND for fixing the null #dimensions issue in v1289...
I incorporated all of your suggestions. Here are my latest tweaks:

Code: Select all

/statusbar_selected_item_format= Selected:  $t | Size: $s#IF:<#dimensions:, | #dimensions: px,>#IF:<#length:, | #format-duration:<#length:> #IF:<#elementcount:<#format-duration:<#length:>,#colon:>==3,h:,>m:s,>#IF:<#audiobitrate:, | Audio: #eval:<#audiobitrate:/1000> kbps,>#IF:<#videobitrate:, | Video: #eval:<#framerate:/1000> fps#comma: #eval:<#videobitrate:/1000> kbps,> | Atr: $b | Modified: $m | Created: $c
Many thx again! (and I'm sorry I slipped and called you 'Andrew' in my earlier post) :)
-JT

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Sun Apr 10, 2022 10:16 pm

$total-result-size: no longer returns any value in /statusbar_selection_format
Using 1305a. Can someone please verify with the current alpha?

test:
/statusbar_selection_format=$total-selection-size: of $total-result-size: selected.

test:
/statusbar_selection_format=#total-selection-size: of #total-result-size: selected.

reset:
/statusbar_selection_format=

Also, $total-selection-size: adds together sizes of files and folders recursively so that the selection can be in the petabytes. It's not terribly useful. And I don't know what an elegant solution would look like, but somehow the Statusbar Size gets a less insane value.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Mon Apr 11, 2022 4:05 am

Thanks for the bug report raccoon,

I have not been able to produce the issue my end.


This can occur if the size for all results is unknown.
For example, search for:

size:unknown



This can occur if you disable size indexing under Tools -> Options -> Indexes -> Index file size.



Does $total-result-size: ever return an empty string where $total-selection-size: returns a non-empty string?


Also, $total-selection-size: adds together sizes of files and folders recursively so that the selection can be in the petabytes. It's not terribly useful. And I don't know what an elegant solution would look like, but somehow the Statusbar Size gets a less insane value.
Previous versions would only add files.
However, I had countless requests to include folder sizes too.

Current versions will just add up the size of each selected item (including the total folder size)

Removing duplicated files from the selection size is unfeasible.

The issue only really exists when you select files and folders.
Usually you are only selecting just files or just folders.

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Mon Apr 11, 2022 5:12 am

void wrote:
Mon Apr 11, 2022 4:05 am
Does $total-result-size: ever return an empty string where $total-selection-size: returns a non-empty string?
This is indeed the issue yes. $total-selection-size: is always non-empty and $total-result-size: is always empty.
I should have given an example.

/statusbar_selection_format=$total-selection-size: of $total-result-size: selected.
123456789 of selected.

I do have Index File Size enabled, with no size:unknown results.
The issue only really exists when you select files and folders. Usually you are only selecting just files or just folders.
Very true, good point.

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Mon Apr 11, 2022 5:17 am

If I sit with items selected for a number of minutes, the status bar updates as monitoring updates arrive. $total-result-size: spews arbitrary huge random numbers that don't correlate with anything, or just 0 (instead of blank). I have tried in small folders, with files only, eg: "T:\test\" files:

after rebuilding index, restarting everything, same condition.
after updating to 1309a, same condition.

New observation: $total-selection-size: rolls over from 9,221,992,108,563 to negative -9,223,131,669,354 when selecting real files. This would appear to be a signed 64-bit value, if we drop the right-six digits. 9,223,372,036,854[,775,800].

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Mon Apr 11, 2022 7:45 am

Thanks for the details.

I'm looking into the issue.

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Mon Apr 11, 2022 4:53 pm

Oh. The 64-bit wrap around happens when using #TEXT:$total-selection-size:,#,### but not when using $total-selection-size: naked. I had only added #TEXT:,#,### to count digits; all the previous observations were with naked variables.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Thu Apr 21, 2022 5:57 am

Everything 1.5.0.1310a fixes an overflow issue with large numbers and the text preprocessor function:

[text:999999999999999,"#,###"]



Everything 1.5.0.1310a fixes an issue with the status bar showing the incorrect total size.

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Fri Apr 22, 2022 5:29 am

Thanks for the fix!

Did anything else change in the statusbar or preprocessor formatting syntax limitations? Am I going to have to become less sloppy?

This now produces errant ">" and "###" strings and eats some "(". Major differences from the previous version.

/statusbar_selection_format=Selected #if:<$selection-count:==$result-count:,all,#TEXT:$selection-count:,#,### of> #TEXT:$result-count:,#,### #ifs:<$folder-result-count:==0,files.,$file-result-count:==0,folders.,1,objects. (#if:<$file-selection-count:==$file-result-count:,all,#TEXT:$file-selection-count:,#,### of> #TEXT:$file-result-count:,#,### files#comma: #if:<$folder-selection-count:==$folder-result-count:,all,#TEXT:$folder-selection-count:,#,### of> #TEXT:$folder-result-count:,#,### folders.)> Size: #if:<$total-selection-size:!=$total-result-size:,#FORMATSIZE:$total-selection-size:,0 of >#FORMATSIZE:<$total-result-size:,0>.#if:<$total-result-size:<=1024, (#if:<$total-selection-size:!=$total-result-size:,#TEXT:$total-selection-size:,#,### of >#TEXT:$total-result-size:,#,### bytes.)>

Code: Select all

/statusbar_selection_format=Selected #if:<$selection-count:==$result-count:,all,#TEXT:$selection-count:,#,### of> #TEXT:$result-count:,#,### #ifs:<$folder-result-count:==0,files.,$file-result-count:==0,folders.,1,objects.  (#if:<$file-selection-count:==$file-result-count:,all,#TEXT:$file-selection-count:,#,### of> #TEXT:$file-result-count:,#,### files#comma: #if:<$folder-selection-count:==$folder-result-count:,all,#TEXT:$folder-selection-count:,#,### of> #TEXT:$folder-result-count:,#,### folders.)>    Size: #if:<$total-selection-size:!=$total-result-size:,#FORMATSIZE:$total-selection-size:,0 of >#FORMATSIZE:<$total-result-size:,0>.#if:<$total-result-size:<=1024,  (#if:<$total-selection-size:!=$total-result-size:,#TEXT:$total-selection-size:,#,### of >#TEXT:$total-result-size:,#,### bytes.)>
Last edited by raccoon on Fri Apr 22, 2022 6:14 am, edited 1 time in total.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Fri Apr 22, 2022 5:54 am

, will now break out of a term if it is in a nested call.

Please try:

Code: Select all

/statusbar_selection_format=Selected #if:<$selection-count:==$result-count:,all,#TEXT:$selection-count:,"#,###" of> #TEXT:$result-count:,"#,###" #ifs:<$folder-result-count:==0,files.,$file-result-count:==0,folders.,1,objects. (#if:<$file-selection-count:==$file-result-count:,all,#TEXT:$file-selection-count:,"#,###" of> #TEXT:$file-result-count:,"#,###" files#comma: #if:<$folder-selection-count:==$folder-result-count:,all,#TEXT:$folder-selection-count:,"#,###" of> #TEXT:$folder-result-count:,"#,###" folders.)> Size: #if:<$total-selection-size:!=$total-result-size:,#FORMATSIZE:$total-selection-size:,0 of >#FORMATSIZE:<$total-result-size:,0>.#if:<$total-result-size:<=1024, (#if:<$total-selection-size:!=$total-result-size:,#TEXT:$total-selection-size:,"#,###" of >#TEXT:$total-result-size:,"#,###" bytes.)>
Note: I have just put all references of #,### in quotes.



I will improve the preprocessor in the next alpha update so your old syntax will still work.
(, shouldn't break when inside a new #text:<> call)

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Fri Apr 22, 2022 6:40 am

Thanks. Yeah, I suspected you changed how #text was being read based on your earlier example of "#,###", but thought it was weird since it worked fine for so long. I had escaped a literal #comma: so it wouldn't ruin an #if, but I guess without brackets (<>) or quotes ("") I guess it puts stress on the parser since #TEXT is a 2-parameter function that should only have 1 comma of its own.

Thanks!

Edit: deleted dumb question.

raccoon
Posts: 719
Joined: Thu Oct 18, 2018 1:24 am

Re: Status Bar Format

Post by raccoon » Wed Apr 27, 2022 5:32 pm

@void: How would you feel about more parity between $total-selection-size: and $total-result-size:? Both do their own thing and it's confusing that they don't behave alike when counting file and folder sizes. I don't have a special preference on whether it be file size only, or file + folder sizes, as long as they're the same.

$total-result-size:
  • Never counts folder sizes. If searching with the folders: verb $total-result-size: is always 0.
$total-selection-size:
  • Counts file + folder sizes. If selecting all results, file sizes and folder sizes are added together to at least double or more the actual index size.
I don't know what's best, but it's annoying that the two numbers are unrelated and never equal unless using the files: verb.

Maybe adding additional $file-*-size: and $folder-*-size: variables could be useful? $folder-result-size:, $file-result-size:, $folder-selection-size, $file-selection-size:.

void
Developer
Posts: 9622
Joined: Fri Oct 16, 2009 11:31 pm

Re: Status Bar Format

Post by void » Thu Apr 28, 2022 10:19 am

Everything 1.5.0.1311a adds a $total-file-selection-size: property.

Thank you for the suggestion.

Post Reply