In Sublime expand selection across open files or project - sublimetext3

What I wish to do: Select an occurrence of a word/variable in a file (python) and then expand the selection across all open files or within the project (so that I can replace the word/variable with something else).
What I know: With ctrl+d I can go to the next occurrence and with alt+F3 I can expand the selection in the current file. I know I can use search and replace, but it is not very intuitive. So I'm looking for a variant of alt+F3 with the addition that text is selected over all open files or within the project.
Any plugin? possible to customize settings or keybindings?

Related

Anyway to highlight words which match selected word in VBA like Notepad++

While using NotePad++, on selecting a certain word, it automatically highlights all matched words
Is it possible to highlight all matching selected words in VBA? Is there any hidden environment setting that can do this or any Addins available to achieve it?
Notepad++ Editor Highlighting feature

how do I do global substitutions?

In vsvim for visual studio, I can highlight a selection and type :s/hello/world/g to get all occurrences of hello inside my selection with world but this isn't working in VsCode Vim, is this a feature not in this version of vim or is the special key sequence different?
After selecting some lines and pressing : you should find that the Vim command line has been defaulted to '<,'> - this is a Vim range that refers to the selected lines. You need to keep this range as part of the command and type the s/... afterwards i.e.
:'<,'>s/hello/world/g
or if you just want to replace all occurrences across the whole file you can skip highlighting the lines and use the % range which indicates the whole file:
:%s/hello/world/g
If curious, you can learn more about some of the other ranges that can be used.

StringReplace unable to identify and replace string copied into clipboard from web pages?

What I am trying to do is very simple: copying selected text into clipboard and replacing every occurrence of some words with others.
StringReplace replaces the specified substring with a new string, so it would be what I am actually looking for.
This small script should copy the text highlighted by user into clipboard, look for every occurrence of the strings <name>, <class> and <race> and replace them with strings Aerien, Paladin and Human:
^q::
{
Send, ^c
ClipWait
StringReplace, clipboard, clipboard, <name>, Aerien, All
StringReplace, clipboard, clipboard, <class>, Paladin, All
StringReplace, clipboard, clipboard, <race>, human, All
Sleep, 250
Send, ^v
}
Return
At the end, it pastes the new content.
Well, said that... try to use it on the contents of this web page as instance, especially where it's written:
I hope you strapped your belt on tight, young <class>, because
there is work to do here in Northshire.
Aforementioned script returns me always <class> instead of replacing that string with Paladin. Using the same script within Notepad instead of within that web page sometimes work but more often not.
I am guessing some issues with < and > symbols.
Always use AutoHotkey from http://ahkscript.org/ (current version, new official website)! AutoHotkey from autohotkey.com is outdated and you may have some problems running scripts with it!
Your script works as intended. When you press CTRL+q script copies to clipboard selected text (so you have to select text before pressing CTRL+q), then in a text that is in clipboard it searches for <name>, <class>, <race> and replaces them respectively to Aerien, Paladin, Human. After it pastes the content of clipboard to the current active window.
1. If you need to paste the content of clipboard in specific input field of current active window, then in my opinion the best way to do that is to use ImageSearch command to get coordinates of that input field, after make click in theses coordinates and after paste the content of clipboard. But also keep in mind that there can be other solutions to do the some.
2. If you need to paste content of clipboard in some other window, activate that window with WinActivate command and then paste the content of clipboard.

Plain text editor (or plugin) with ability to copy line into clipboard in just one mouse click

I'm looking for plain text editor (or plugin) with ability to stay on top and copy entire single line into clipboard by just clicking somewhere within this line. Without need to make a selection or press any key(s) first, just click and get line copied into clipboard. Next click inside editor's window gets another line from opened file copied into clipboard, and so on. Thanks.
I don't think such app exists. Coz single click always changes caret position only.
In SynWrite editor u can click line, AND press Ctrl+C. (First set option "Copy current line if no selection made" on).

Mark/search a word in closed folding

In Notepad++, when all my foldings (created by using "define language as") are close, then the search and mark functions don't look into the hidden text.
Is there a way to make these functions look into the hidden text (instead of having to open all folding with Alt+1)?
If you do a 'Find all in current document' it will show you the results in a new pane on the bottom side. Perhaps that will help.
Actually it's working the search/mark function open the folding.It was a mistake I checked "Macth whole word only".

Resources