Thanks for your report. I'll look into it.
OMG yes, this bug's been here for decades. I think it happens after some time even if main window is not minimized. Every time nothing is found in Editor it is sent back below all other windows, so annoying. You have to press taskbar button multiple times to get it back. And if you press ESC instead, Editor sometimes is brought back to top, but sometimes WinSCP just crashes.
If I have a file open in the Editor and WinSCP is minimized to the notification area (systray) and I search for something in the editor and when the "Could not find the string 'xxxxx'." popups the whole editor window will hide behind other windows.
I have to click the icon in the taskbar to bring the editor to the front again.
WinSCP 6.6.1 beta (build 17216 2026-04-01)
Windows 10