Alt+F7 Search results misleading
Moderators: Hacker, petermad, Stefan2, white
Alt+F7 Search results misleading
I think it is related to a previous report - http://www.ghisler.ch/board/viewtopic.php?t=26156
Searching for Load\n or Edit\n gives false results - files without that string and misses files with that string. No options selected, just Alt+F7 inside the folder and that text entered in 'Find text' field.
My test folder is 'ui_igo8' from an Igo skin - Dimka.
Searching for Load\n or Edit\n gives false results - files without that string and misses files with that string. No options selected, just Alt+F7 inside the folder and that text entered in 'Find text' field.
My test folder is 'ui_igo8' from an Igo skin - Dimka.
- ghisler(Author)
- Site Admin
- Posts: 50390
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Unfortunately I cannot reproduce the problem.
I downloaded the file from
http://www.igo8mods.com/diMkaspecter1533a.zip
Only one file containing Edit\n is found (Edit followed by a hard line break):
ui_igo8\common\ui\poi.ui
contains the line:
NEXTSTATE st_ManagePOIEdit
No file containing Load\n is found.
Can you give me examples of files which should be found but aren't?
Maybe you just have "word wrap" enabled, so it looks like the line ends with Edit or Load, but really doesn't?
I downloaded the file from
http://www.igo8mods.com/diMkaspecter1533a.zip
Only one file containing Edit\n is found (Edit followed by a hard line break):
ui_igo8\common\ui\poi.ui
contains the line:
NEXTSTATE st_ManagePOIEdit
No file containing Load\n is found.
Can you give me examples of files which should be found but aren't?
Maybe you just have "word wrap" enabled, so it looks like the line ends with Edit or Load, but really doesn't?
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Sorry, try http://www.igo8mods.com/diMkaWertVRV_1139.rar
Searching for Load\n you get as result
ui_igo8\common\ui\start.ui and speedcam.ui , but none of them contain that string.
You should find this string in \ui_igo8\480_800\ui\advmenu_480_800.ui and 2 more files, line 165.
Searching for the same string, but with Unicode selected, I get 0 results.
Additionally:
Searching for Load\ has as result the 3 files advmenu_***, but if I enable unicode I get 0 results.
Searching for Load\n you get as result
ui_igo8\common\ui\start.ui and speedcam.ui , but none of them contain that string.
You should find this string in \ui_igo8\480_800\ui\advmenu_480_800.ui and 2 more files, line 165.
Searching for the same string, but with Unicode selected, I get 0 results.
Additionally:
Searching for Load\ has as result the 3 files advmenu_***, but if I enable unicode I get 0 results.
- ghisler(Author)
- Site Admin
- Posts: 50390
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
I see - this is just a big misunderstanding. When you use
Load\n
as search string, TC will search for the word "Load" followed by a line break. Also \t will find a tab character. So just look for
Load\\n
instead.
Load\n
as search string, TC will search for the word "Load" followed by a line break. Also \t will find a tab character. So just look for
Load\\n
instead.
The files are not Unicode UTF-16, but UTF-8. So if you check UTF-8, you will get the same results as in text mode, because the search string doesn't contain any Unicode characters.with Unicode selected, I get 0 results
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
I think TC search dialogs should have checkbox 'Use Escapes' so user can disable such non-obvious feature. And, sometimes user just doesn't need to search with escapes but w/o such checkbox he must double all slashes - sometimes it is boring (e.g. I want to search for C:\dir1\dir2\dir3\...\file1.ext).ghisler(Author) wrote:I see - this is just a big misunderstanding. When you use
Load\n
as search string, TC will search for the word "Load" followed by a line break. Also \t will find a tab character. So just look for
Load\\n
instead.
- ghisler(Author)
- Site Admin
- Posts: 50390
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Sorry, it has been like this for many many years, I will not change that now.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
- ghisler(Author)
- Site Admin
- Posts: 50390
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
How do you imagine that? An error dialog each time the user types a backslash? That would be extremely annoying. 

Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Maybe you can add third state for RegEx checkbox and change its caption?
So, unchecked (with caption like 'Esc/RegEx') = search for exact text, grayed (with caption like 'Esc') = search for escaped text, checked (with caption 'RegEx') = search for regular expression. Regex and escapes can't be combined anyway so such way will allow to use same checkbox for both functions (both 'RegEx' checkboxes in search for text Lister's dialog and search files dialog may be modified this way).
I think people will like such modification (especially if you add some INI option with values: '0: two-state regex checkboxes, old-school behaviour' or '1: tho-state regex checkboxes, search for plain text if unchecked' or '2: three-state regex checkboxes').
Maybe this will be a great innovation for TC 8.0?
I think such feature should be easy to realize since you already have all its possibilities, you just need to enable/disable them when needed.
So, unchecked (with caption like 'Esc/RegEx') = search for exact text, grayed (with caption like 'Esc') = search for escaped text, checked (with caption 'RegEx') = search for regular expression. Regex and escapes can't be combined anyway so such way will allow to use same checkbox for both functions (both 'RegEx' checkboxes in search for text Lister's dialog and search files dialog may be modified this way).
I think people will like such modification (especially if you add some INI option with values: '0: two-state regex checkboxes, old-school behaviour' or '1: tho-state regex checkboxes, search for plain text if unchecked' or '2: three-state regex checkboxes').
Maybe this will be a great innovation for TC 8.0?

I think such feature should be easy to realize since you already have all its possibilities, you just need to enable/disable them when needed.