{"comment":{"url":"https://api.github.com/repos/cyril-steimer/Envision/comments/11788272","html_url":"https://github.com/cyril-steimer/Envision/commit/14110efce9e0ef37e47de61fb73e9dae3d977deb#commitcomment-11788272","id":11788272,"user":{"login":"dimitar-asenov","id":1152976,"avatar_url":"https://avatars.githubusercontent.com/u/1152976?v=3","gravatar_id":"","url":"https://api.github.com/users/dimitar-asenov","html_url":"https://github.com/dimitar-asenov","followers_url":"https://api.github.com/users/dimitar-asenov/followers","following_url":"https://api.github.com/users/dimitar-asenov/following{/other_user}","gists_url":"https://api.github.com/users/dimitar-asenov/gists{/gist_id}","starred_url":"https://api.github.com/users/dimitar-asenov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimitar-asenov/subscriptions","organizations_url":"https://api.github.com/users/dimitar-asenov/orgs","repos_url":"https://api.github.com/users/dimitar-asenov/repos","events_url":"https://api.github.com/users/dimitar-asenov/events{/privacy}","received_events_url":"https://api.github.com/users/dimitar-asenov/received_events","type":"User","site_admin":false},"position":55,"line":55,"path":"VisualizationBase/src/utils/Drawing.cpp","commit_id":"14110efce9e0ef37e47de61fb73e9dae3d977deb","created_at":"2015-06-22T07:24:15Z","updated_at":"2015-06-22T07:24:15Z","body":"The lines below are mostly identical with the lines above in the previous if. With 3 or more, mostly identical lines, it's probably a good idea to extract these into a function. It's best to do this in a local lambda:\r\nauto drawArrow = [&painter, ...] (QPointF arrow) { ...} // or something similar."}}