{"action":"opened","issue":{"url":"https://api.github.com/repos/spyder-ide/spyder/issues/5973","repository_url":"https://api.github.com/repos/spyder-ide/spyder","labels_url":"https://api.github.com/repos/spyder-ide/spyder/issues/5973/labels{/name}","comments_url":"https://api.github.com/repos/spyder-ide/spyder/issues/5973/comments","events_url":"https://api.github.com/repos/spyder-ide/spyder/issues/5973/events","html_url":"https://github.com/spyder-ide/spyder/issues/5973","id":281713665,"number":5973,"title":"shift-del delete line only when empty selection, otherwise clipboard cut","user":{"login":"prof7bit","id":1401589,"avatar_url":"https://avatars0.githubusercontent.com/u/1401589?v=4","gravatar_id":"","url":"https://api.github.com/users/prof7bit","html_url":"https://github.com/prof7bit","followers_url":"https://api.github.com/users/prof7bit/followers","following_url":"https://api.github.com/users/prof7bit/following{/other_user}","gists_url":"https://api.github.com/users/prof7bit/gists{/gist_id}","starred_url":"https://api.github.com/users/prof7bit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/prof7bit/subscriptions","organizations_url":"https://api.github.com/users/prof7bit/orgs","repos_url":"https://api.github.com/users/prof7bit/repos","events_url":"https://api.github.com/users/prof7bit/events{/privacy}","received_events_url":"https://api.github.com/users/prof7bit/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-12-13T11:21:21Z","updated_at":"2017-12-13T11:21:21Z","closed_at":null,"author_association":"NONE","body":"## Description of your problem\r\n\r\n**What steps will reproduce the problem?**\r\n\r\n1.  select some text\r\n2.  press shift-del\r\n\r\n**What is the expected output? What do you see instead?**\r\nselected text should be removed and inserted to clipboard so that shift-ins brings it back. (cut & paste)\r\n\r\ninstead it just deletes all lines that were part of the selection and one line more without putting any of it to the clipboard.\r\n\r\nproposed solution:\r\n* when the selection is empty then delete the line and put it to the clipboard\r\n* when the selection is not empty then fall back to the standards conforming behavior of cut exactly the selected text to the clipboard.\r\n\r\nGenerally it should be expected that after the sequence shift-del, shift-ins the text should be in the same state as it was before, as it is in **any** other code editor out there. \r\n\r\nMany people wo use both hands on the keyboard use these keys as a replacement for the alternative Crtl-X, Ctrl-V because when selecting text with the keyboard (shift and cursor keys) instead of using the mouse then the left hand is already sitting on the shift key while the right index finger is conveniently near del and ins.\r\n\r\nWhen not using it for cutting selected text and instead just deleting the current line without a selection then it should be put to the clipboard anyways, as this is also standard practice in many code editors that have line delete function, there is a corresponding paste key that brings back the line. In spyder it is just lost, not useful when rearranging lines.\r\n\r\nPlease do not close this bug too quickly, if nobody wants to work on this then I might give it a try myself, this odd behavior of spyder has caused me so much annoyance already I really want to find a solution to make the standard keys behave more standards conforming.\r\n"}}
{"actor":{"display_login":"prof7bit"}}