Bug 217276 - When copying multiline text, it also copies non-existing trailing spaces
Summary: When copying multiline text, it also copies non-existing trailing spaces
Alias: None
Product: Fedora
Classification: Fedora
Component: slang   
(Show other bugs)
Version: 6
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Miroslav Lichvar
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2006-11-26 12:11 UTC by Raoul
Modified: 2007-11-30 22:11 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-02-23 11:13:46 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Raoul 2006-11-26 12:11:55 UTC
Description of problem:

I think this "feature" is new because i don't remember it in older midnight
commander versions.

Here is the problem by example:

1. open gnome-terminal
2. open a text file that contains more than 1 lines of text with mcedit
3. select 2 or more lines of text with the mouse by holding Shift key on the
4. copy the selected text and paste it to another text editor.
5. it stupidly pastes trailing spaces together with the text.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. already described
Actual results:
copies trailing spaces, which actually do not exist in the text. It assumes that
the empty space between the end of each line of text and the right edge of the
terminal is filled with bloody spaces!

Expected results:
copy the exact portion of text and the actual spaces if any.

Comment 1 Leonard den Ottolander 2006-11-27 21:46:41 UTC
Seems more like an issue with gnome-terminal than mc. Have you tried other
command line editors?

I cannot reproduce this with a fairly recent mc (2006-10-15) with an older
gnome-terminal (on FC4).

Comment 2 Raoul 2006-11-28 00:46:49 UTC
I also use vi, from which the text can be copied correctly.

I had never encountered this issue in FC4. IIRC, it started to be an issue with

If you cannot reproduce it with a recent mc on FC4, then you are absolutely
right that it might be some other application's issue.

However, I tried to copy text from mcedit, while it runs in xterm. The exact

1) mcedit text.file  (in xterm)
2) select 2 or more lines of text while Lshift is pressed on the keyboard
3) paste the text with the middle mouse button in another editor.

It still pastes trailing spaces from xterm.

Comment 3 Raoul 2006-11-28 00:49:24 UTC
I would also like to apologize for the bad language in the initial bug
submission. This was just a moment of anger. I know that these issues happen. :)

Comment 4 Curtis Doty 2006-12-10 04:00:32 UTC
I've seen two similar but distinct symptoms on MS Windows client SecureCRT.
Exact same client platform side-by-side terminals for very old RHL or FC1?
systems work just fine. But more recent FC4+? terminals produce one or both of

 - single trailing space injected on any lines that are colorized as a multiline
context block. I.e. # comments.

 - more recently, selecting multiline blocks in mcedit now is worse, as entire
editor/window width is padded with trailing spaces on every line in the block.

I've always assumed nobody wants to fix due to cross-platform issue. And I'm
completly ignorant of proper termcap usage and debugging. But happy to run tests
if desired.

Comment 5 Jindrich Novy 2006-12-11 09:14:58 UTC
Adding Miroslav to Cc as it doesn't seem to be a fault of mc but some terminal

Comment 6 Miroslav Lichvar 2006-12-13 14:49:41 UTC
It's a bug in slang.

Comment 7 Miroslav Lichvar 2007-02-19 18:48:25 UTC
Fixed in slang-2.0.7-1.fc6.

Note You need to log in before you can comment on or make changes to this bug.