{"action":"created","issue":{"url":"https://api.github.com/repos/omz/Pythonista-Issues/issues/221","repository_url":"https://api.github.com/repos/omz/Pythonista-Issues","labels_url":"https://api.github.com/repos/omz/Pythonista-Issues/issues/221/labels{/name}","comments_url":"https://api.github.com/repos/omz/Pythonista-Issues/issues/221/comments","events_url":"https://api.github.com/repos/omz/Pythonista-Issues/issues/221/events","html_url":"https://github.com/omz/Pythonista-Issues/issues/221","id":184629333,"number":221,"title":"__init__ of subclassed ui.Views does not appear to work for frame attr - 301011","user":{"login":"Phuket2","id":11646675,"avatar_url":"https://avatars.githubusercontent.com/u/11646675?v=3","gravatar_id":"","url":"https://api.github.com/users/Phuket2","html_url":"https://github.com/Phuket2","followers_url":"https://api.github.com/users/Phuket2/followers","following_url":"https://api.github.com/users/Phuket2/following{/other_user}","gists_url":"https://api.github.com/users/Phuket2/gists{/gist_id}","starred_url":"https://api.github.com/users/Phuket2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Phuket2/subscriptions","organizations_url":"https://api.github.com/users/Phuket2/orgs","repos_url":"https://api.github.com/users/Phuket2/repos","events_url":"https://api.github.com/users/Phuket2/events{/privacy}","received_events_url":"https://api.github.com/users/Phuket2/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-10-22T13:05:32Z","updated_at":"2016-10-22T13:21:15Z","closed_at":null,"body":"@omz, this is great....  However the frame attr appears to work for a ui.View, but not for a ui.Button as below.\r\n\r\n```python \r\nimport ui\r\ndef my_action(sender):\r\n\tprint(sender)\r\n\t\r\nbtn = ui.Button(frame=(0, 0, 150, 64), title='junk',\r\n\t\tborder_color='white', border_width=.5, corner_radius=6,\r\n\t\ttint_color='deeppink', action=my_action)\r\n\t\t\r\nprint(btn.frame)\r\n\r\nv = ui.View(frame=(0, 0, 300, 400))\r\nbtn.center = v.bounds.center()\r\nv.add_subview(btn)\r\nv.present('sheet')\r\n```"},"comment":{"url":"https://api.github.com/repos/omz/Pythonista-Issues/issues/comments/255528073","html_url":"https://github.com/omz/Pythonista-Issues/issues/221#issuecomment-255528073","issue_url":"https://api.github.com/repos/omz/Pythonista-Issues/issues/221","id":255528073,"user":{"login":"Phuket2","id":11646675,"avatar_url":"https://avatars.githubusercontent.com/u/11646675?v=3","gravatar_id":"","url":"https://api.github.com/users/Phuket2","html_url":"https://github.com/Phuket2","followers_url":"https://api.github.com/users/Phuket2/followers","following_url":"https://api.github.com/users/Phuket2/following{/other_user}","gists_url":"https://api.github.com/users/Phuket2/gists{/gist_id}","starred_url":"https://api.github.com/users/Phuket2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Phuket2/subscriptions","organizations_url":"https://api.github.com/users/Phuket2/orgs","repos_url":"https://api.github.com/users/Phuket2/repos","events_url":"https://api.github.com/users/Phuket2/events{/privacy}","received_events_url":"https://api.github.com/users/Phuket2/received_events","type":"User","site_admin":false},"created_at":"2016-10-22T13:21:15Z","updated_at":"2016-10-22T13:21:15Z","body":"@omz , ok sorry. I do remember @jonb pointing this out before.  To be honest though, it does not feel like a feature as you have the size_to_fit method, which I guess is being called internally automatically in this case based on the circumstances.  But it seems if you implicitly pass a frame and a title, the frame should take precedence.  Well, that's just my thoughts. It's still a small issue.  But very happy to have this functionality now 😁 If there were not so many people in the bar now, I would  buy them all a drink 😱\r\n\r\n"}}
{"actor":{"display_login":"Phuket2"}}