Double clicking over a word function works great, but it can be much greater than ever
-
@W-TX said in Double clicking over a word function works great, but it can be much greater than ever:
When double clicking left button over a word, I hope that the function is enhanced to the current function and followed by 2 key strokes “Ctrl”+“F3”, so the 2 key strokes can skip, it will greatly save time. I double click a word only to implement search function.
Have you considered how other users use double-clicking, and how your suggested change might negatively impact them? No? I thought not. :-)
when 1 document is showed on 2 windows by using “clone to other view”, only the same words in the clicked window are highlighted , not on both windows.
Just tick this box to enable that behavior:
-
@W-TX said in Double clicking over a word function works great, but it can be much greater than ever:
- Can it add a single key stroke to reverse search a word, for example, “F4”?
There are three “Find Previous”, akin to the three “Find Next”, already built in and listed in the Find menu:
I’m not sure how those three don’t meet your needs for “reverse search a word”.
If you don’t like the default keystrokes, you can change them using Settings > Shortcut Mapper:
-
@Alan-Kilborn Thank you for your advice. But how to pop up the “smart highlights” window?
-
@W-TX said in Double clicking over a word function works great, but it can be much greater than ever:
But how to pop up the “smart highlights” window?
Settings > Preferences > Highlighting
-
@PeterJones Great! Thank you very much!
Notepad++ is the best software for editing a source code file!
-
@Alan-Kilborn said in Double clicking over a word function works great, but it can be much greater than ever:
how your suggested change might negatively impact them? No? I thought not.
Could you please give an example to support your opinion: I thought not.
-
@W-TX said in Double clicking over a word function works great, but it can be much greater than ever:
Could you please give an example to support your opinion: I thought not.
It’s really easy to give an example of it breaking someone’s workflow, even by someone else than the person who brought up the point.
I rarely use the “Select and Find Next” or “Find (Volatile) Next” actions. But I quite frequently double-click. For example, I double-click then type over the selection (or paste over the selection, or what have you). If double-click automatically selected the word, then found the next occurrence of that word, then when I started typing (or pasting) to overwrite that word, it would edit the wrong instance of that word. ⇒ QED: I was able to supply an example to support @Alan-Kilborn’s (and my) opinion that changing the double-click behavior as you describe would negatively impact my double-click general use-case.
Also, assuming you haven’t re-mapped the keys,
Ctrl+F3
is the “Select and Find Next” command, as shown in my screenshot above. Note that the first part of that command is “Select”: it already starts by selecting the active word, which is equivalent to the double-click you are doing first. So if you really wanted to make things more efficient for you, just typeCtrl+F3
rather than double-click-then-Ctrl+F3
. -
Further, Notepad++'s double-click behavior is the expected behavior, to anyone who has used MS Notepad, or MS Word, or any other word processing or text editing software I’ve used … and even other software, such as my web-browsers or my linux terminal programs: it selects the active word. Making it behave differently just in Notepad++, would break the expectation of many people.
-
@PeterJones said in Double clicking over a word function works great, but it can be much greater than ever:
I rarely use the “Select and Find Next” or “Find (Volatile) Next” actions. But I quite frequently double-click. For example, I double-click then type over the selection (or paste over the selection, or what have you). If double-click automatically selected the word, then found the next occurrence of that word, then when I started typing (or pasting) to overwrite that word, it would edit the wrong instance of that word. ⇒ QED: I was able to supply an example to support @Alan-Kilborn’s (and my) opinion that changing the double-click behavior as you describe would negatively impact my double-click general use-case.
Also, assuming you haven’t re-mapped the keys, Ctrl+F3 is the “Select and Find Next” command, as shown in my screenshot above. Note that the first part of that command is “Select”: it already starts by selecting the active word, which is equivalent to the double-click you are doing first. So if you really wanted to make things more efficient for you, just type Ctrl+F3 rather than double-click-then-Ctrl+F3.Sorry I have made a mistake. What I really want is to include “Ctrl” + “F3” and leaving cursor position unchanged, so your mentioned inconvenience really does not exist, and if you type further or go to find next word, it will not cause any conflict.
-
@W-TX said in Double clicking over a word function works great, but it can be much greater than ever:
What I really want is to include “Ctrl” + “F3” and leaving cursor position unchanged
It appears you are still under a misunderstanding of what
Ctrl+F3
does. It is a highlight-and-find-next command. If you do not want it to find the next instance, then the behavior you want is notCtrl+F3
, and you should stop calling it that. Inherent in theCtrl+F3
is moving the cursor.If you have behavior that you would like to replicate, you are going to have to describe the actual behavior of what state cursor, selection, and find-buffer should be in, rather than relying on your understandings as to what the keyboard shortcuts do.
-
Of course, one could write a script to do something special on the double-click notification. Like grab the selected text and so a find-next on it.
EDIT: Well, I guess I haven’t kept up with this thread…but when I try to I get really confused.
-
@Alan-Kilborn said in Double clicking over a word function works great, but it can be much greater than ever:
Of course, one could write a script to do something special on the double-click notification. Like grab the selected text and so a find-next on it.
EDIT: Well, I guess I haven’t kept up with this thread…but when I try to I get really confused.What I want is to enhance double click function not only to highlight the word as usual, but also to trig a find function to get the word into search target without moving cursor position, saving two key strokes “Ctrl”+“F3”. So after that , one can press “F3” to start searching next.
This is a practice of paid Textpad software I used before and find the function really useful.
-
@W-TX ,
get the word into search target without moving cursor position
Thank you for the better description.
Personally, I still think it’s a bad idea: if I already have something I want in the search target so that F3 will find the next instance of that search, but want to double-click a word to type over it in the meantime, I’d be pretty upset if the developers decided that suddenly my desired F3 target would be replaced just because I happened to use the mouse double-click to select a word.
find the function really useful.
I don’t, as described above; but I can see how someone with a different standard workflow might. We can disagree on this opinion.
to enhance double click function
This Forum is not the feature request / bug tracker for Notepad++ … we are here to help others use the software. Development is tracked in github, as mentioned in the FAQs on this Forum.
That said, you may feel free to make a feature request in the official location, as described in the Forum FAQ: if you do make a feature request as a result of this discussion, it’s considered polite to paste a link to that request here in the discussion. However, I would personally not want to see this implemented, because it will interfere with my standard workflow.
As an alternative, and thus avoiding messing up the application for me and many others who want search to remain independent of selection, @Alan-Kilborn gave an idea for a way to customize the behavior for yourself: use PythonScript or another of the scripting plugins to hook into the double-click notification, and insert the contents of the current word into the search buffer. If you don’t have the skills to research how to do that yourself, someone here might take pity on you if you ask nicely – but please remember that this isn’t a code-writing forum, and anything you might get will be from the generosity of volunteers.
-
You seem to be in love with this idea.
You first brought it up over a year ago HEREAlso Ctrl+F3 isn’t 2 keystrokes, it is 1.
Nobody would call “A”, which you get by pressing Shift+a, two keystrokes.
But if you insist that Ctrl+F3 is two keystrokes, use the Shortcut Mapper to reassign it to a “single” keystroke.As I read it, you’ve got two actions you want to do here:
- double-click to select a word
- press a keycombo (when you are ready) to do a find-next
I would do it this way:
- click the desired word (or move the caret to it)
- execute a Select and Find Next operation, again, when I’m ready (of course after assigning it to a single keycombo of my liking)
The differences seem, well, just semantics.
-
Considering it a bit more, I’ve changed my mind about a script doing it.
I was thinking that it was all wanted in one step via the double-click, but as more discussion has occurred, it appears to be a two-step thing.Thus, I’ve already given what I think is an acceptable solution (which is really no more than standard N++ already does).
Plus, there is no way to “set the search buffer term” via a script, without bringing up the Find window, and I don’t think that would be deemed desirable here.
-
@Alan-Kilborn said in Double clicking over a word function works great, but it can be much greater than ever:
But if you insist that Ctrl+F3 is two keystrokes, use the Shortcut Mapper to reassign it to a “single” keystroke.
Could you please tell where to find Shortcut Mapper.
-
@W-TX said in Double clicking over a word function works great, but it can be much greater than ever:
Could you please tell where to find Shortcut Mapper.
Peter told you about Shortcut Mapper, including where to find it, 7 hours ago. But maybe pictures work where the written word apparently fails:
-
@Alan-Kilborn Thank you. I changed F4 key from searching previous result to CTRL+F4, and SHIFT +F3 to F4, so F4 key, one stroke, does searching previous word function. Work great!
Through this post, I really get my 2 requests satisfied:
-
Find a way to show the highlighted word in 2 windows.
-
Find a way to use F4 key to search previous word!
I remember that last time I visited this site, no shortcut mapper was available. But now it works great! I want to know on which version the shortcut mapper was added.
Thank you for everyone who helps.
-
-
@W-TX said in Double clicking over a word function works great, but it can be much greater than ever:
Through this post, I really get my 2 requests satisfied
I am absolutely stunned by this statement. :-)
I remember that last time I visited this site, no shortcut mapper was available.
This is not a true statement.
I want to know on which version the shortcut mapper was added.
TBH, I’m not sure (and it isn’t worth looking through really old/ancient versions to find exactly where), but it has been around at the very least 7 years, and I’d believe, a lot longer than that. Maybe the Research Dept. will figure out the answer.
-
@Alan-Kilborn said in Double clicking over a word function works great, but it can be much greater than ever:
Maybe the Research Dept. will figure out the answer.
- 7.0 from 2016 has Shortcut Mapper
- 6.0 from 2012 has Shortcut Mapper
- 4.0 from 2006 has Shortcut Mapper
@W-TX joined May 21, 2019, when v7.7 (May 19) was brand new, and asked the earlier question in Nov 2019 (when v7.8.1 was the newest).
Because I was curious:
IiIiIGRvdWJsZWNsaWNrRXh0cmEucHkNCg0KaHR0cHM6Ly9jb21tdW5pdHkubm90 ZXBhZC1wbHVzLXBsdXMub3JnL3RvcGljLzE5ODc5L2RvdWJsZS1jbGlja2luZy1v dmVyLWEtd29yZC1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