{"action":"created","issue":{"url":"https://api.github.com/repos/Strilanc/Quirk/issues/406","repository_url":"https://api.github.com/repos/Strilanc/Quirk","labels_url":"https://api.github.com/repos/Strilanc/Quirk/issues/406/labels{/name}","comments_url":"https://api.github.com/repos/Strilanc/Quirk/issues/406/comments","events_url":"https://api.github.com/repos/Strilanc/Quirk/issues/406/events","html_url":"https://github.com/Strilanc/Quirk/issues/406","id":339636532,"node_id":"MDU6SXNzdWUzMzk2MzY1MzI=","number":406,"title":"Drag qubit lines","user":{"login":"afowler","id":1313740,"node_id":"MDQ6VXNlcjEzMTM3NDA=","avatar_url":"https://avatars0.githubusercontent.com/u/1313740?v=4","gravatar_id":"","url":"https://api.github.com/users/afowler","html_url":"https://github.com/afowler","followers_url":"https://api.github.com/users/afowler/followers","following_url":"https://api.github.com/users/afowler/following{/other_user}","gists_url":"https://api.github.com/users/afowler/gists{/gist_id}","starred_url":"https://api.github.com/users/afowler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/afowler/subscriptions","organizations_url":"https://api.github.com/users/afowler/orgs","repos_url":"https://api.github.com/users/afowler/repos","events_url":"https://api.github.com/users/afowler/events{/privacy}","received_events_url":"https://api.github.com/users/afowler/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-07-09T23:04:21Z","updated_at":"2018-07-09T23:34:27Z","closed_at":null,"author_association":"NONE","body":"Wouldn't it be awesome to be able to rearrange circuits by dragging qubit lines up and down? Suggest making the initial |0> a draggable object."},"comment":{"url":"https://api.github.com/repos/Strilanc/Quirk/issues/comments/403652217","html_url":"https://github.com/Strilanc/Quirk/issues/406#issuecomment-403652217","issue_url":"https://api.github.com/repos/Strilanc/Quirk/issues/406","id":403652217,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMzY1MjIxNw==","user":{"login":"Strilanc","id":79941,"node_id":"MDQ6VXNlcjc5OTQx","avatar_url":"https://avatars1.githubusercontent.com/u/79941?v=4","gravatar_id":"","url":"https://api.github.com/users/Strilanc","html_url":"https://github.com/Strilanc","followers_url":"https://api.github.com/users/Strilanc/followers","following_url":"https://api.github.com/users/Strilanc/following{/other_user}","gists_url":"https://api.github.com/users/Strilanc/gists{/gist_id}","starred_url":"https://api.github.com/users/Strilanc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Strilanc/subscriptions","organizations_url":"https://api.github.com/users/Strilanc/orgs","repos_url":"https://api.github.com/users/Strilanc/repos","events_url":"https://api.github.com/users/Strilanc/events{/privacy}","received_events_url":"https://api.github.com/users/Strilanc/received_events","type":"User","site_admin":false},"created_at":"2018-07-09T23:34:27Z","updated_at":"2018-07-09T23:34:27Z","author_association":"OWNER","body":"One of the tricky things here is what should happen to multiqubit operations.\r\n\r\n![image](https://user-images.githubusercontent.com/79941/42481091-6d057786-8395-11e8-9e2a-80ea1fd33218.png)\r\n\r\nHere's what I think the rules would be:\r\n\r\n- The multi-qubit operation is only associated with its first qubit. As far as all other qubits it touches are concerned, it doesn't exist. So, if you drag the last qubit of a QFT downward, the QFT stays behind.\r\n- When you drag a qubit with a single-qubit gate on it into the middle of a multi-qubit operation, the single-qubit gate gets displaced into a new column to the right.\r\n- When you drag a qubit with a control on it into the middle of a multi-qubit operation, the operation is disabled (by the existing \"control inside gate\" check) until you release, at which point the control is pushed into a new column to the right.\r\n- When a multi-qubit operation is pushed downward so far that it would push past the 16 qubit limit (either due to its first qubit being moved or a qubit being moved from inside it to above it), the operation will shrink in size to accomodate. If there is not a small enough version of the operation to fit, it is placed as low as possible. If this causes it to overlap with existing operations, it is pushed rightward into a new column.\r\n"}}
{"actor":{"display_login":"Strilanc"}}