{"action":"created","issue":{"url":"https://api.github.com/repos/littlevgl/lvgl/issues/422","repository_url":"https://api.github.com/repos/littlevgl/lvgl","labels_url":"https://api.github.com/repos/littlevgl/lvgl/issues/422/labels{/name}","comments_url":"https://api.github.com/repos/littlevgl/lvgl/issues/422/comments","events_url":"https://api.github.com/repos/littlevgl/lvgl/issues/422/events","html_url":"https://github.com/littlevgl/lvgl/issues/422","id":362856156,"node_id":"MDU6SXNzdWUzNjI4NTYxNTY=","number":422,"title":"Encoder support","user":{"login":"poelstra","id":1025628,"node_id":"MDQ6VXNlcjEwMjU2Mjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1025628?v=4","gravatar_id":"","url":"https://api.github.com/users/poelstra","html_url":"https://github.com/poelstra","followers_url":"https://api.github.com/users/poelstra/followers","following_url":"https://api.github.com/users/poelstra/following{/other_user}","gists_url":"https://api.github.com/users/poelstra/gists{/gist_id}","starred_url":"https://api.github.com/users/poelstra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/poelstra/subscriptions","organizations_url":"https://api.github.com/users/poelstra/orgs","repos_url":"https://api.github.com/users/poelstra/repos","events_url":"https://api.github.com/users/poelstra/events{/privacy}","received_events_url":"https://api.github.com/users/poelstra/received_events","type":"User","site_admin":false},"labels":[{"id":389374647,"node_id":"MDU6TGFiZWwzODkzNzQ2NDc=","url":"https://api.github.com/repos/littlevgl/lvgl/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-09-22T13:12:19Z","updated_at":"2018-09-25T20:28:28Z","closed_at":null,"author_association":"NONE","body":"Hi! Thanks for your excellent graphics library!\r\n\r\nI'm using it to implement a GUI for a room thermostat on an SSD1331 display (96x64 px) in combination with an encoder (turn + push). I noticed a few other issues (#365, #261) about this subject, and switched to `dev-5.2` to try it out.\r\n\r\nIt took me a while to figure out that I had to assign the input driver to a group, but it works now :smile: \r\nI then played a bit with `lv_test_group_1()`.\r\n\r\nA few things that 'surprised' we were:\r\n1. I would expect registering the encoder driver would 'just work', just like e.g. the mouse driver does (including navigating in e.g. popup windows)\r\n2. I expected a short-click to also allow the slider to move\r\n3. Focus/edit mode of a slider on 100% (with Night theme) are invisible\r\n4. Rollers 'open' on focus, which suggests that further rotating would choose another element\r\n\r\n(I hope the terse wording doesn't come across as offending, I certainly appreciate the effort that went into this already!)\r\n\r\nSome random ideas (just to throw them out there)\r\n1. I'm used to e.g. creating Windows GUI's with Delphi (long time ago...), where keyboard focus was handled using e.g. a TabIndex property on each control. When set to a positive value, this would indicate the focus order.\r\n2. For many controls, a single click would probably suffice to 'enter' them, and a long-press could function as a generic way to 'exit' them. E.g. for controls like a slider a short or long click would exit them, for button groups a first short click enters the group, further short clicks operate the buttons, and a long-press exits the group).\r\n3. Maybe (also) restyle the knob on focus/edit? And/or provide a bit of 'glow' around the object?\r\n4. Suggest to keep the roller 'closed' on focus, and only open in edit mode.\r\n\r\nI already experimented a bit in the code myself, and am more than happy to help out with both implementation and testing. Curious what your thoughts on this are, though!"},"comment":{"url":"https://api.github.com/repos/littlevgl/lvgl/issues/comments/424489853","html_url":"https://github.com/littlevgl/lvgl/issues/422#issuecomment-424489853","issue_url":"https://api.github.com/repos/littlevgl/lvgl/issues/422","id":424489853,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNDQ4OTg1Mw==","user":{"login":"poelstra","id":1025628,"node_id":"MDQ6VXNlcjEwMjU2Mjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1025628?v=4","gravatar_id":"","url":"https://api.github.com/users/poelstra","html_url":"https://github.com/poelstra","followers_url":"https://api.github.com/users/poelstra/followers","following_url":"https://api.github.com/users/poelstra/following{/other_user}","gists_url":"https://api.github.com/users/poelstra/gists{/gist_id}","starred_url":"https://api.github.com/users/poelstra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/poelstra/subscriptions","organizations_url":"https://api.github.com/users/poelstra/orgs","repos_url":"https://api.github.com/users/poelstra/repos","events_url":"https://api.github.com/users/poelstra/events{/privacy}","received_events_url":"https://api.github.com/users/poelstra/received_events","type":"User","site_admin":false},"created_at":"2018-09-25T20:28:28Z","updated_at":"2018-09-25T20:28:28Z","author_association":"NONE","body":"I did some more testing (using `lv_test_group_1()`) and I think it's a big improvement! :+1: \r\n\r\nSome smaller things I found:\r\n* ddlist selected item has a nice animation when opening, but then 'jumps' to reposition the selected item in the middle. Probably the animation should try to keep the selected item in the middle all the time, instead of moving it to the top.\r\n* btnm, keyboard, mbox and list all 'highlight' their first button on focus (orange), but clicking the encoder will not press that button, but just enter edit mode. I think it's more clear if that button is only highlighted when edit mode is active.\r\n* page doesn't scroll on edit (I think that's a known issue)\r\n* if the page only contains non-focusable/editable objects, it may make sense for a single click to exit edit mode again.\r\n\r\nI wonder how navigation would work with 'nested' controls, e.g. putting sliders on the tab controls or a page. Didn't try that yet."}}
{"actor":{"display_login":"poelstra"}}