Show "PowerShell" inside TC as whole panel

Here you can propose new features, make suggestions etc.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
eugenesv
Junior Member
Junior Member
Posts: 36
Joined: 2016-03-05, 23:30 UTC

Show "PowerShell" inside TC as whole panel

Post by *eugenesv »

In default Windows Explorer there is an option to attach a terminal session (e.g. PowerShell) to the Explorer window instead of opening it in a separate window.
Is there a chance the awesome TC can add this feature as well?

Please see the attached picture for an example of an attached PowerShell session to the bottom of an Windows Explorer window
(due to limitation on link embedding, pasting it as plain text :(
--start img lnk (add dots after each word)
imgur
com
gYig078
--end image link



-edit by mod:
http://imgur.com/gYig078


 
User avatar
Ovg
Power Member
Power Member
Posts: 756
Joined: 2014-01-06, 16:26 UTC

Post by *Ovg »

It's impossible to lead us astray for we don't care even to choose the way.
#259941, TC 11.01 x64, Windows 7 SP1 x64
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

eugenesv,
Seems to be a third-party Explorer extension. Lambda symbol looks familiar to me (there is a command interpreter replacement with such symbol, this one).
eugenesv
Junior Member
Junior Member
Posts: 36
Joined: 2016-03-05, 23:30 UTC

Post by *eugenesv »

@MVV
Yes, you're correct — this is the best console in Windows ConEmu (https://conemu.github.io) with some settings taken from cmder you linked to.
I just don't know how it's implemented, thought it was something of a default Explorer thing that allowed a console to be attached.

@Ovg
Thanks a bunch!!!
Now I'll check with the author of that addon and the author of ConEmu to see if it's possible to connect those two — there are just so many settings already configured with ConEmu that it'd be a waste to start with a blank console again.
eugenesv
Junior Member
Junior Member
Posts: 36
Joined: 2016-03-05, 23:30 UTC

Post by *eugenesv »

After more digging I've found a way how to do that in principle, but still lacking some key pieces.
I've described it in more details in another thread http://ghisler.ch/board/viewtopic.php?t=43673&highlight=
or you can check out some screenshots at https://github.com/Maximus5/ConEmu/issues/122

Just repeating remaining questions here for completeness of the thread:

Two questions remain that would clarify whether ConEmu embedding is possible:
1) Is there an HWND (this is a hex window code of a window object, which can be a panel, status bar, command line etc.) of the middle of the panel that shows folder/files (I couldn't find any in Spy++)?
2) Is there an addon that would allow to spawn an empty "panel" with an HWND that could be hijacked by ConEmu?
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

There is no legal way of creating any windows inside TC window so it may only be done with some sort of hacks. I'm not aware of such tools.

The best way of adding such console that I can imagine would be enlarging bottom TC panel (where command line is placed) for adding another command line linked to custom console, and some shortcut to enlarge/collapse back this console (like Ctrl+O in old good Norton Commander). This sort of hack would require attaching a DLL to TC process (this may be done e.g. with Autorun plugin) and integrating into TC window message processing loop. However I don't know will this be usable (and stable which is more important) or not.
eugenesv
Junior Member
Junior Member
Posts: 36
Joined: 2016-03-05, 23:30 UTC

Post by *eugenesv »

Ok, thank you. To be honest, the only thing I need is that window code HWND, and since it's variable, it's only TC who knows it or the existing terminal addon that was linked to earlier.
If only I could get that HWND internally from TC I could launch ConEmu from within TC and it would work just fine — no need to worry about hacks or anything, everything has already been hacked :), ConEmu has a module that allows it to be embedded into any window with big enough area.
Unfortunately command line is too small, I've only managed to inject ConEmu into the tab-area of regular panels or tree-view. But it's only possible after I've established the dynamic HWND of those windows, and it's a manual process :(
Anyway, I've also asked the author of the terminal addon (http://totalcmd.net/plugring/tconsole.html), maybe he would be kind enough to add an option to launch ConEmu (it's just one line with HWND passed to it) in the additional window he already creates instead of the default cmd/PS.
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Post by *MVV »

Well, TC doesn't support empty tabs for inserting anything into, so you really need some DLL that will do some non-standard handling like creating a child window and managing its size and position (it isn't hard to create child window in any window, you only need to have some code running within that process - like mentioned DLL).

And, since TConsole works as a WFX plugin, it shouldn't embed anything into TC window.
eugenesv
Junior Member
Junior Member
Posts: 36
Joined: 2016-03-05, 23:30 UTC

Post by *eugenesv »

Yeah, I understand TC support it — that's just too bad :(
TC creates a new "network drive" that shows a cmd/PS console in it. Maybe it shouldn't do it, but I'm glad it does :)
I just wish it were one step more flexible and allowed to launch one more process instead of the two predefined cmd/PS ones
Post Reply