mridgers / clink

Bash's powerful command line editing in cmd.exe
mridgers.github.io/clink
GNU General Public License v3.0
3.22k stars 284 forks source link

text based ui lining gets screwed up when run from a prompt with clink injected #77

Closed ghost closed 10 years ago

ghost commented 10 years ago

From push....@gmail.com on December 04, 2012 12:25:20

What steps will reproduce the problem? 1. Open a command prompt, make sure clink has injected

  1. Run some ncurses-like text ui application from the said prompt

2.a [irssi] 2.a.1 Write text beyond line width 2.a.2 Press HOME button 2.a.3 Edit\Write some more 2.a.4 Get ui lining screwed up

2.b [mcabber] 2.b.1 /screen_refresh 2.b.2 Get ui lining screwed up What is the expected output? What do you see instead? Expected it not to be screwed up What version of the product are you using? On what operating system? clink 0.2.1 installed through a setup app on Windows 2003 x86 Please provide any additional information below. It seems that when a text based ui application is called from the prompt which has clink injected, its output is written to the window created by that prompt and gets modified by clink which shouldn't happen if not intended. The described steps to reproduce also show that issue 50 seems to be taking place, which makes the described problem severe. Requesting for a priority boost for issue 50 . Thanks.

Attachment: irssi.png mcabber.PNG

Original issue: http://code.google.com/p/clink/issues/detail?id=78

ghost commented 10 years ago

From push....@gmail.com on December 04, 2012 03:40:56

Suddenly can't reproduce with fixed buffer width prompt and must add that the above takes place in conemu-maximus5.121128

ghost commented 10 years ago

From martin.r...@gmail.com on December 04, 2012 04:57:45

Clink only hooks the cmd.exe process and does not hook new process created by cmd.exe. So if you're having problems with child processes it certainly isn't Clink that is at fault. You can verify this by using Process Explorer and observing there are no Clink DLLs in the child process you're having trouble with.

In the screenshots it looks like you are using something like ConEmu or Console2? If so it's almost certainly your choice of console host that is at fault. ConEmu for example is invasive and will hook all processes spawned by cmd.exe as well as the modules loaded. It does this so that it can catch all reads and writes to the console. Having used the pdcurses lib I can say that it uses the Console APIs in an unusual manner. In short; speak to your console host's developers.

Regarding issue 50 . This is underway but not trivial.

Status: Invalid