topmostfriend icon indicating copy to clipboard operation
topmostfriend copied to clipboard

Feature request: show hidden windows without title

Open eabase opened this issue 1 year ago • 2 comments

Hi, I'm was hoping to use this to find hidden windows (or windows broken).

But it was not able to find some window. I noticed your code here: https://github.com/flashwave/topmostfriend/blob/master/TopMostFriend/Program.cs#L316-L318

Say:

// i think it's a fair assumption that any visible window worth a damn has a window title
if(!showEmptyTitles && string.IsNullOrEmpty(title))
    continue;

So maybe:

  • add an option to show these.
  • add an option to toggle the WS_EX_TOPMOST bit?
  • Add a way to DestroyWindow (or at least show it's PID)

Many Thanks.

eabase avatar Oct 26 '24 09:10 eabase

There is actually already a setting for this technically but it seems I never bothered to expose this in the UI ^^;

You'll notice the first part of the snippet has a check for showEmptyTitles, this is hooked to a Registry value; Create a DWORD value for ShowEmptyWindowTitles in HKCU\SOFTWARE\flash.moe\TopMostFriend, set it to 1 and it should now show windows without a title in the list.

I'll add a proper toggle for this in the future but in the mean time this should suffice... It would probably need some extra attention, like showing what exe file the window belongs to.

Thank you for bringing this up!

flashwave avatar Nov 03 '24 21:11 flashwave

Hi @flashwave Thank you for looking into this. I'll try the workaround. I keep getting blank "dead" windows on my desktop, that are blocked from closing or moving, and prevents clicking on anything underneath. It would be great to be able to get the PID of the responsible processes creating these.

I noticed that there are a lot (~50%) of windows without any name or icon...

eabase avatar Nov 04 '24 01:11 eabase