GNOME Bugzilla – Bug 552788
Shift + Insert does not paste correctly
Last modified: 2009-06-17 22:23:35 UTC
Please describe the problem: Some strigs which contain underscore, marked and copied to clipboard via keyboard (using Ctrl - Insert sequence), does not paste correctly into application using VTE widget (like gnome-terminal). Strangely, I can observe such behaviour only copying FROM Eclipse IDE (v 3.3) - however pasting to any other app not using VTE works correctly, so I do not blame Eclipse for that. For example: When I mark string like: DOC_NAMESPACE in Eclipse, then copy it to clipboard (via Ctrl-C, or Ctrl_Ins, or context menu), then try to paste into gnome-terminal using Shift-Insert, it paste only first part of string, like: DOC. More weird: part of string which appear after paste operation depends of direction of marking! On the other hand pasting via Ctrl+Shift+Insert, Ctrl+Shift+v or context menu works correctly. I figured out that must be some difference between Ctrl+Shift+Insert and Ctrl+Insert, so I downloaded source code of VTE 0.16.14, and found, that for Ctrl+Insert vte_terminal_paste_primary() is invoked (vte.c line 4362), and for Ctrl+Shift+Insert vte_terminal_paste_clipboard(). So, I changed vte_terminal_paste_primary() to vte_terminal_paste_clipboard() to verify my theory. As you can expect it started to work correctly, however it is obviously just proof-of-concept workaround, thus I submit this issue. Problem is not 100% reproducible (I cannot find more detailed pattern), but 75% can be good figure. Steps to reproduce: 1. Run Eclipse IDE, mark and copy string with underlines in it. 2. Paste into VTE-based app like gnome-terminal using Shift-Insert shortcut 3. Actual results: String is pasted partialy (up to, or from underline) Expected results: complete string would appear Does this happen every time? not always, but close to 100% Other information:
So eclipse sets PRIMARY incorrectly.
OK, I'll follow this path and check it then eventually provide more info.
Have you found out more?
Unfortunately, I was very busy recently and my expertise of Eclipse if rather basic, so I'm not able to investigate this problem in near future. I propose to close this bug for now.
Closing as per comment #4. Please reopen if you have any news!