{"action":"created","issue":{"url":"https://api.github.com/repos/spyder-ide/spyder/issues/2217","labels_url":"https://api.github.com/repos/spyder-ide/spyder/issues/2217/labels{/name}","comments_url":"https://api.github.com/repos/spyder-ide/spyder/issues/2217/comments","events_url":"https://api.github.com/repos/spyder-ide/spyder/issues/2217/events","html_url":"https://github.com/spyder-ide/spyder/pull/2217","id":59407479,"number":2217,"title":"[WIP] Emacs keybindings","user":{"login":"blink1073","id":2096628,"avatar_url":"https://avatars.githubusercontent.com/u/2096628?v=3","gravatar_id":"","url":"https://api.github.com/users/blink1073","html_url":"https://github.com/blink1073","followers_url":"https://api.github.com/users/blink1073/followers","following_url":"https://api.github.com/users/blink1073/following{/other_user}","gists_url":"https://api.github.com/users/blink1073/gists{/gist_id}","starred_url":"https://api.github.com/users/blink1073/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/blink1073/subscriptions","organizations_url":"https://api.github.com/users/blink1073/orgs","repos_url":"https://api.github.com/users/blink1073/repos","events_url":"https://api.github.com/users/blink1073/events{/privacy}","received_events_url":"https://api.github.com/users/blink1073/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/spyder-ide/spyder/labels/Editor","name":"Editor","color":"d4c5f9"},{"url":"https://api.github.com/repos/spyder-ide/spyder/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/spyder-ide/spyder/milestones/5","html_url":"https://github.com/spyder-ide/spyder/milestones/v3.0","labels_url":"https://api.github.com/repos/spyder-ide/spyder/milestones/5/labels","id":982077,"number":5,"title":"v3.0","description":"","creator":{"login":"spyder-issues-migrator","id":11021581,"avatar_url":"https://avatars.githubusercontent.com/u/11021581?v=3","gravatar_id":"","url":"https://api.github.com/users/spyder-issues-migrator","html_url":"https://github.com/spyder-issues-migrator","followers_url":"https://api.github.com/users/spyder-issues-migrator/followers","following_url":"https://api.github.com/users/spyder-issues-migrator/following{/other_user}","gists_url":"https://api.github.com/users/spyder-issues-migrator/gists{/gist_id}","starred_url":"https://api.github.com/users/spyder-issues-migrator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/spyder-issues-migrator/subscriptions","organizations_url":"https://api.github.com/users/spyder-issues-migrator/orgs","repos_url":"https://api.github.com/users/spyder-issues-migrator/repos","events_url":"https://api.github.com/users/spyder-issues-migrator/events{/privacy}","received_events_url":"https://api.github.com/users/spyder-issues-migrator/received_events","type":"User","site_admin":false},"open_issues":253,"closed_issues":56,"state":"open","created_at":"2015-02-16T23:17:23Z","updated_at":"2015-04-21T19:36:32Z","due_on":null,"closed_at":null},"comments":25,"created_at":"2015-03-01T17:25:05Z","updated_at":"2015-04-21T22:13:10Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/spyder-ide/spyder/pulls/2217","html_url":"https://github.com/spyder-ide/spyder/pull/2217","diff_url":"https://github.com/spyder-ide/spyder/pull/2217.diff","patch_url":"https://github.com/spyder-ide/spyder/pull/2217.patch"},"body":"Adds the following Emas-like keybindings, which were modeled after the bash (and IPython) behavior.\r\n\r\n```python\r\n\"editor/start of line\": \"Meta+A\",   # go to first character on line\r\n\"editor/end of line\": \"Meta+E\",\r\n\"editor/previous line\": \"Meta+P\",\r\n\"editor/next line\": \"Meta+N\",\r\n\"editor/previous char\": \"Alt+B\",\r\n\"editor/next char\": \"Alt+F\",\r\n\"editor/previous word\": \"Meta+B\",\r\n\"editor/next word\": \"Meta+F\",\r\n\"editor/Kill to Line End\": \"Meta+K\",\r\n\"editor/Kill to Line Start\": \"Meta+U\",\r\n\"editor/select all\": \"Ctrl+A\",\r\n```\r\n\r\nSince the shortcuts interfere with some of the built in shortcuts, I added a preference toggle for Emacs shortcuts, which automatically sets these shortcuts to the ones used in the terminal, and de-conflicts the defaults.\r\n\r\nLeft to do:  \r\n\r\n- [x] Allow `Ctrl+A` to be overridden by another shortcut\r\n- [x] Fix the Emacs keybinding toggle\r\n- [ ] Add more shortcuts based on feedback\r\n- [ ] Add handling of keyboard shortcuts with multiple letter keys?  (e.g. `C-xs` for save).\r\n\r\nI think that in order to do the last one, we'd have to alter the way the user inputs keyboard shortcuts, to actually allow the user to press the desired key sequence.  \r\n\r\nCloses #1212.  Closes #729."},"comment":{"url":"https://api.github.com/repos/spyder-ide/spyder/issues/comments/94958283","html_url":"https://github.com/spyder-ide/spyder/pull/2217#issuecomment-94958283","issue_url":"https://api.github.com/repos/spyder-ide/spyder/issues/2217","id":94958283,"user":{"login":"blink1073","id":2096628,"avatar_url":"https://avatars.githubusercontent.com/u/2096628?v=3","gravatar_id":"","url":"https://api.github.com/users/blink1073","html_url":"https://github.com/blink1073","followers_url":"https://api.github.com/users/blink1073/followers","following_url":"https://api.github.com/users/blink1073/following{/other_user}","gists_url":"https://api.github.com/users/blink1073/gists{/gist_id}","starred_url":"https://api.github.com/users/blink1073/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/blink1073/subscriptions","organizations_url":"https://api.github.com/users/blink1073/orgs","repos_url":"https://api.github.com/users/blink1073/repos","events_url":"https://api.github.com/users/blink1073/events{/privacy}","received_events_url":"https://api.github.com/users/blink1073/received_events","type":"User","site_admin":false},"created_at":"2015-04-21T22:13:10Z","updated_at":"2015-04-21T22:13:10Z","body":"I'd also like an IPython option that mimics the shell behavior. "}}