Bug 286468 - [feature-request] kate should remember search query across files (KDE3-style)
Summary: [feature-request] kate should remember search query across files (KDE3-style)
Status: RESOLVED DUPLICATE of bug 203969
Alias: None
Product: kate
Classification: Applications
Component: search (other bugs)
Version First Reported In: unspecified
Platform: Fedora RPMs Linux
: NOR wishlist
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-13 07:20 UTC by Technologov
Modified: 2011-12-09 17:35 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
demo / mockup screenshow of how to improve the search toolbar. (16.47 KB, image/png)
2011-12-07 13:34 UTC, Technologov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Technologov 2011-11-13 07:20:21 UTC
Version:           unspecified (using KDE 4.7.2) 
OS:                Linux

If I search several times, in several files, I need to manually copy+paste the query.
It should be copied automatically.

This problem exists in all KDE4-series, including latest KDE 4.7.2 in Fedora 16. (kate 3.7.2) It works correctly with KDE3.

Reproducible: Always

Steps to Reproduce:
1. create (or open) 2 files
A. abc.txt with text "abc"
B. bcd.txt with text "bcd"

2. search file abc.txt with "bc" contents
3. click to move to bcd.txt file and start search

Actual Results:  
It resets search field, so I must re-type the query.

Expected Results:  
It should automatically use latest query. I do not want for per-file query, but one global query, like in KDE3.
At least you should make it optional.


Works with KDE3 kate.
Comment 1 Kåre Särs 2011-11-13 10:39:33 UTC
If I understand you correctly you want to search for a specific string in multiple open documents. That functionality is available in the "Search in Files" plugin :)
Comment 2 Technologov 2011-12-07 08:22:04 UTC
No no no. "Search in Files" plugin is nice, but not what I need.

What is needed is KDE3-kate behavior (optional).
In Kate (3+4) there is a side list of opened files.

When searching text in file 1 then moving to file 2 also wanna search for same term, in Kate3, the search remembers what I searched for.

In Kate4, the search is per-file, and it forgets what I searched for.
"Search in Files" plugin won't help -- as I need to search in 2 or 3 files, not in 100+ opened files.

What is needed is Kate3-like search behavior.

-Technologov
Comment 3 Technologov 2011-12-07 08:26:17 UTC
This problem is actually a big regression of KDE4, that reduces my productivity by 10%.
Comment 4 Technologov 2011-12-07 08:26:54 UTC
I want the search field to keep results of the last search.
Comment 5 Anne-Marie Mahfouf 2011-12-07 08:30:45 UTC
After talking to him on IRC:
He wants to search specific files that he chooses manually (a few in more than 100 opened) for the same word so after the first search, he would like the searched string to be kept when he reopens the search field.
Comment 6 Kåre Särs 2011-12-07 09:07:40 UTC
Technologov:

I understand that you are not interested in the results in all those other files just those selected 2-3.

In KDE 4.8 the "Search & Replace" (Previously "Search in Files") plugin will highlight all hits and add a marker on the scrollbar. This is not exactly what you wanted, but I urge you to test it and see if it fulfills your needs. After the search you just jump to the files you are interested in and there the results are already highlighted.
Comment 7 Technologov 2011-12-07 09:10:24 UTC
No please. It is not optimal to my workflow.

It is like forcing people using "virtual desktops" when they want 2 windows side-by-side. Please don't force me to use non-optimal workflow.
Comment 8 Kåre Särs 2011-12-07 09:33:18 UTC
The problem here is that some people find having different searches for different files a good feature.

I'm not taking any sides on which is better, just pointing out that with the S&R plugin you get a workflow that is quite close to what you want. Added in 4.8 will also be the possibility to jump to the next match with a shortcut.

The shortcuts for S&R are not assigned to any keys by default but can easily be set :)

Have you tried S&R from trunk?
Comment 9 Technologov 2011-12-07 10:07:01 UTC
> Have you tried S&R from trunk?
No, but it is not what I need.

>The problem here is that some people find having different searches for
different files a good feature.

OK, then please at least make it optional in Kate settings.
Comment 10 Technologov 2011-12-07 12:29:09 UTC
You can find me as 'technologov' on Free node IRC #kde channel.

---
I have tested kate-master. The new Search & Replace plugin.

This is not what I need. Two BIG problems:
1. "F3" (next search) doesn't work with it (esp. when I jump across files using side bar). I can't use your own bar to jump across files, because it wastes my desktop space, preventing me to edit my file.

2. there is no 'close' button, so it stucks forever stealing my desktop space, when I don't need it. Standard KDE searcher has 'close' button as small red "X". Adding close button will improve your search-tool, but it will not solve my problem.

-Technologov
Comment 11 Technologov 2011-12-07 13:34:28 UTC
Created attachment 66476 [details]
demo / mockup screenshow of how to improve the search toolbar.
Comment 12 Technologov 2011-12-07 13:37:23 UTC
The new screenshot of demo mockup shows what can be improved over current design:

'close' button', then search field', then 'new' button', then 'search' button', then 'prev match in file' button', then 'next match in file' button.

'search' and 'new' can be swapped however... Maybe put 'search' button near the edit field.

Add Qt Tooltips to each action/button. Alternatively make 2 levels of buttons, but this will hurt NetBook experience, so Qt tooltips are preferrable.

-Technologov, 7.12.2011.
Comment 13 Christoph Feck 2011-12-07 13:42:51 UTC
I often have to explicitely copy the search string to the clipboard, just to avoid typing it again when switching to a different file. It would be nice if the old search string was available with "cursor down" or pre-filled/-selected, so unless you start typing a different string, the old string will be kept.
Comment 14 Technologov 2011-12-07 13:45:55 UTC
New search plugin: (KDE 4.8)
Also 'text highlight' must become optional - in "Options" button.

In addition I recommend to remove word options from 'options' button to save
desktop space. (leave just icon)
Comment 15 Dominik Haumann 2011-12-09 17:35:48 UTC
Technologov: please only report one issue per report.

Remember search across files is the same as bug #203969, so this is already a known issue.
And the other points (e.g. screen shot) are already in one of your other reports.

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