You are here: PSPad forum > English discussion forum > Highlighting all occurrences of selected text in the active editor
Posted by: Professor Bernd | Date: 2020-05-05 19:58 | IP: IP Logged
Hello Jan.
I would like to ask you for a very important feature:
Highlighting all occurrences of selected text in the active editor.
Unfortunately I can't create it from the outside. I have tried many things, but there are always unpleasant disadvantages. The feature is not only for AutoIt, but for all languages and many other users would love it.
Description of the feature
- Text can be selected in the editor with the mouse or the keyboard.
- A whole word can be selected (e.g. "StringInStr"), or only a part (e.g. "String").
- If Text is selected, all other occurrences of this text in the document should be highlighted.
- The highlighting starts automatically when text is selected - no shortcut, search function or similar is needed.
Additional options, if possible
- Highlighting also within comments.
- The selected text may contain spaces, e.g. "MsgBox( 0, "
Example screenshot
Could you please be so kind to add the feature? It is really important and I would be very happy.
Best regards,
Professor Bernd.
Edited 2 time(s). Last edit at 2020-05-05 20:03 by Professor Bernd.
Posted by: Vany | Date: 2020-05-11 08:52 | IP: IP Logged
see topic forum.pspad.com
I am afraid it is far from real to be done.
--
Vany
(PSPad 5.5.1.783 x32, W10h/p x64 en/cs)
Posted by: Professor Bernd | Date: 2020-05-11 18:17 | IP: IP Logged
Vany:see topic forum.pspad.comI am afraid it is far from real to be done.
@Vany @feef
Why not? For Jan it is not a big effort, the functions are already there!
I have already programmed this feature for AutoIt Scripts (.au3), and it works! I programmed it from the outside, but there are some drawbacks, e.g. that I lose a whole highlighter section, or that every time I highlight text, the hard drive is accessed, or it only works for AutoIt, but not for other languages, and much more.
It's NOT hard to build this into PSPad internally! Outside I have no events, I have to work with tricks. But Jan has events, it's much easier. The functions are also available to him: Searching inside the active editor, and highlighting "whatever he wants".
From the outside, I used VBScript and AutoIt-Script to monitor if text is highlighted, then I wrote it into the highlighter file and all occurrences were highlighted. If no text was marked, I removed the entry from the highlighter file. This is complicated and requires write access to the file and the hard disk each time.
From inside PSPad this is much easier! No reason not to include such an important feature in PSPad!
@PSPad
Please Jan, I have already sent you several eMails about this feature and have made several requests here in the forum. But you have not answered any. Please build this feature into PSPad. Almost all other editors have this feature, but not PSPad. PSPad has many other strengths that other editors do not have. I love PSPad. But this is a really important feature that PSPad needs, and it's for all languages.
Bernd.
Translated with www.DeepL.com/Translator (free version)
Edited 2 time(s). Last edit at 2020-05-11 18:23 by Professor Bernd.
Posted by: Vany | Date: 2020-05-12 12:37 | IP: IP Logged
I would be happy if this could work, no problém. So it is up to Honza to implement it some day.
--
Vany
(PSPad 5.5.1.783 x32, W10h/p x64 en/cs)
Posted by: Professor Bernd | Date: 2020-05-12 17:46 | IP: IP Logged
Vany:I would be happy if this could work, no problém. So it is up to Honza to implement it some day.
Many users would be happy, because it is a feature for all languages! The users have been asking for it for years (see my thread here and the links in Posting #1). I also don't understand why Honza doesn't answer. Thank you very much for your answer!
Bernd.
Edited 1 time(s). Last edit at 2020-05-12 17:55 by Professor Bernd.
Posted by: pspad | Date: 2020-05-20 16:31 | IP: IP Logged
First version of this functionality will be available in the next build
Posted by: Professor Bernd | Date: 2020-05-20 18:24 | IP: IP Logged
Wow, that's great!
Posted by: brolx | Date: 2020-06-24 10:02 | IP: IP Logged
It's just great!
However, I have a display problem: other highlighted occurences are somehow smaller than the normal characters, leading to something a bit unreadable.
I tried changing the font, same result ...
Edited 1 time(s). Last edit at 2020-06-24 10:02 by brolx.
Posted by: pspad | Date: 2020-06-24 17:42 | IP: IP Logged
brolx:It's just great!
However, I have a display problem: other highlighted occurences are somehow smaller than the normal characters, leading to something a bit unreadable.
I tried changing the font, same result ...
What font do you use?
What font size do you use?
Do you use high DPI settings for your monitor?
I need to simulate it.
Posted by: brolx | Date: 2020-06-26 16:37 | IP: IP Logged
Inconsolata or Lucida Console.
Because you asked, I tried both 11 and 12. The problem only occurs with 11.
My resolution is 1920x1080 (scaling 100%)
Editor PSPad - freeware editor, © 2001 - 2023 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR