{"action":"closed","issue":{"url":"https://api.github.com/repos/garybernhardt/selecta/issues/90","repository_url":"https://api.github.com/repos/garybernhardt/selecta","labels_url":"https://api.github.com/repos/garybernhardt/selecta/issues/90/labels{/name}","comments_url":"https://api.github.com/repos/garybernhardt/selecta/issues/90/comments","events_url":"https://api.github.com/repos/garybernhardt/selecta/issues/90/events","html_url":"https://github.com/garybernhardt/selecta/issues/90","id":89968633,"number":90,"title":"Render Selecta less intrusively","user":{"login":"rschmitt","id":3725049,"avatar_url":"https://avatars.githubusercontent.com/u/3725049?v=3","gravatar_id":"","url":"https://api.github.com/users/rschmitt","html_url":"https://github.com/rschmitt","followers_url":"https://api.github.com/users/rschmitt/followers","following_url":"https://api.github.com/users/rschmitt/following{/other_user}","gists_url":"https://api.github.com/users/rschmitt/gists{/gist_id}","starred_url":"https://api.github.com/users/rschmitt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rschmitt/subscriptions","organizations_url":"https://api.github.com/users/rschmitt/orgs","repos_url":"https://api.github.com/users/rschmitt/repos","events_url":"https://api.github.com/users/rschmitt/events{/privacy}","received_events_url":"https://api.github.com/users/rschmitt/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-06-21T22:27:32Z","updated_at":"2016-02-07T22:11:33Z","closed_at":"2016-02-07T22:11:33Z","body":"Currently, Selecta renders itself according to the following procedure:\r\n\r\n1. Upon startup, determine the dimensions of the Terminal window\r\n2. Draw Selecta on the bottom of the screen, using up to 21 lines (20 visible choices plus one prompt)\r\n3. After a selection is made, move the cursor to the bottom of the screen\r\n\r\nThis works fine for a Command-T replacement, but it's fairly jarring when using Selecta as an extension of the shell. Ideally, summoning Selecta with Ctrl-S should look like this:\r\n\r\n1. Selecta renders itself directly beneath the current prompt line, moving the screen down only as far as necessary\r\n2. When a selection is made, Selecta vanishes\r\n3. The cursor moves back to the _original_ prompt line, with the selection added in place, as if the user had typed in the selection manually\r\n\r\nI've drawn up a comparison using Heatseeker. The below demos show the following use cases, in order:\r\n\r\n1. Writing a selection directly to stdout\r\n2. Saving a selection to an environment variable\r\n3. Appending a selection to the command line using Ctrl-S\r\n\r\nHere is Selecta:\r\n\r\n![capture](https://cloud.githubusercontent.com/assets/3725049/8273585/49be7604-1829-11e5-8ff7-cb69f633b2be.gif)\r\n\r\nHere is Heatseeker:\r\n\r\n![capture](https://cloud.githubusercontent.com/assets/3725049/8273576/ecce4226-1828-11e5-9269-e017b54755fa.gif)\r\n\r\nThe vim integration looks the same in either case, so I did not include it here."}}