Midnight Commander screen corruption w/ built-in editor

Errol Smith errol@ros.com.au
Sun May 2 08:13:00 GMT 2004


 I'm having a problem with mc's editor (4.6.0-4, also tried mc-4.6.0a-20030721 with same issue). (cygwin 1.5.9-1 on 98se)
 If you are editing a file wider than the screen, sometimes the display becomes corrupted, with odd parts of lines appearing at the left screen edge and the display seems to lose left/right alignment with mc's internal idea of where it is (so if you go to insert a character, it actually gets inserted several characters up the line from where you thought).

Test case - make a file like this:
blah blah blah blah blah blah blah blah blah blah blah
<tab>blah blah blah blah blah blah blah blah blah blah blah
<tab><tab>blah blah blah blah blah blah blah blah blah blah blah
<tab><tab><tab>blah blah blah blah blah blah blah blah blah blah blah
.... (you get the idea - make it wider than the screen).

Then move the cursor to one of the longer lines (but not the _longest_ line), hit <END> (or cursor-right along the line) then hit the up-arrow key and see rubbish appear on the left hand side. It seems to be mostly the up-arrow key that does it, but sometimes when the screen shifts left, not all of it moves (some stays where it was, even though mc thinks it moved).

There may be a simpler way of producing the bug, but this is a reliable way I've found. Note that if you use spaces instead of tabs (or have the fill-tabs-with-spaces option on), the problem doesn't appear, so the tabs seem to be part of the cause.
Hitting page-up/page-down doesn't seem to fix it - I would have thought this would refresh the screen so it would then be in the right place, but it doesn't. Basically, once it goes funny, it stays that way and you have to close the file.
I've tried this full screen or windowed, in a normal shell or in rxvt, reinstalled mc and I also tried removing all mc related files/config and going back to default with no change. mc 4.6 on linux doesn't do it (with same test files).
Any ideas?

E


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/



More information about the Cygwin mailing list