{"action":"created","issue":{"url":"https://api.github.com/repos/atom/atom/issues/8730","labels_url":"https://api.github.com/repos/atom/atom/issues/8730/labels{/name}","comments_url":"https://api.github.com/repos/atom/atom/issues/8730/comments","events_url":"https://api.github.com/repos/atom/atom/issues/8730/events","html_url":"https://github.com/atom/atom/pull/8730","id":105583858,"number":8730,"title":"Faster Style Recalculations","user":{"login":"as-cii","id":482957,"avatar_url":"https://avatars.githubusercontent.com/u/482957?v=3","gravatar_id":"","url":"https://api.github.com/users/as-cii","html_url":"https://github.com/as-cii","followers_url":"https://api.github.com/users/as-cii/followers","following_url":"https://api.github.com/users/as-cii/following{/other_user}","gists_url":"https://api.github.com/users/as-cii/gists{/gist_id}","starred_url":"https://api.github.com/users/as-cii/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/as-cii/subscriptions","organizations_url":"https://api.github.com/users/as-cii/orgs","repos_url":"https://api.github.com/users/as-cii/repos","events_url":"https://api.github.com/users/as-cii/events{/privacy}","received_events_url":"https://api.github.com/users/as-cii/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-09-09T12:12:47Z","updated_at":"2015-09-09T16:35:38Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/atom/atom/pulls/8730","html_url":"https://github.com/atom/atom/pull/8730","diff_url":"https://github.com/atom/atom/pull/8730.diff","patch_url":"https://github.com/atom/atom/pull/8730.patch"},"body":"* [ ] Reopen https://github.com/atom/git-diff/issues/71.\r\n* [x] Merge https://github.com/atom/git-diff/pull/73.\r\n* [ ] Merge https://github.com/atom/bookmarks/pull/39.\r\n\r\nIn this PR I have removed inline styles from lines and got rid of a couple of classes that were not used for styling. To do that, I sorted line and line numbers by their screen row.\r\n\r\nBefore (full reflow):\r\n\r\n![before-1](https://cloud.githubusercontent.com/assets/482957/9761178/653b5f3a-56fb-11e5-9236-66e6a5368b67.png)\r\n![before-2](https://cloud.githubusercontent.com/assets/482957/9761179/65403258-56fb-11e5-854a-c05c9f5031d6.png)\r\n\r\nAfter (full reflow):\r\n\r\n![after-1](https://cloud.githubusercontent.com/assets/482957/9761186/6e2d7ff6-56fb-11e5-8eb7-beadac1e1862.png)\r\n![after-2](https://cloud.githubusercontent.com/assets/482957/9761184/6dcf02be-56fb-11e5-9250-3cf452c1de9f.png)\r\n\r\n:racehorse: :racehorse: :racehorse: \r\n\r\nPlease note that this regresses https://github.com/atom/git-diff/issues/71 because we cannot set inline z-indexes anymore on line nodes. @simurai: in the meantime, I feel like I'd be down to have the git deletion marker styled like:\r\n\r\n![deletion-marker](https://cloud.githubusercontent.com/assets/378023/9516321/ed2090d2-4ce2-11e5-8664-08f3f6a019ca.png)\r\n\r\nOr, alternatively, to avoid assigning an opaque background to the cursor line number.\r\n\r\nThoughts? :thought_balloon: \r\n\r\n/cc: @nathansobo @atom/feedback "},"comment":{"url":"https://api.github.com/repos/atom/atom/issues/comments/138965649","html_url":"https://github.com/atom/atom/pull/8730#issuecomment-138965649","issue_url":"https://api.github.com/repos/atom/atom/issues/8730","id":138965649,"user":{"login":"as-cii","id":482957,"avatar_url":"https://avatars.githubusercontent.com/u/482957?v=3","gravatar_id":"","url":"https://api.github.com/users/as-cii","html_url":"https://github.com/as-cii","followers_url":"https://api.github.com/users/as-cii/followers","following_url":"https://api.github.com/users/as-cii/following{/other_user}","gists_url":"https://api.github.com/users/as-cii/gists{/gist_id}","starred_url":"https://api.github.com/users/as-cii/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/as-cii/subscriptions","organizations_url":"https://api.github.com/users/as-cii/orgs","repos_url":"https://api.github.com/users/as-cii/repos","events_url":"https://api.github.com/users/as-cii/events{/privacy}","received_events_url":"https://api.github.com/users/as-cii/received_events","type":"User","site_admin":false},"created_at":"2015-09-09T16:35:38Z","updated_at":"2015-09-09T16:35:38Z","body":"> Still seems like it might be worth it to try dropping tiles and going back to a fixed size single layer that we reposition infrequently at scroll seams.\r\n\r\nYep, that's something we should introduce regardless of the measurement mechanism we will end up choosing. :+1: \r\n\r\nSpeaking about this, I think that with the performance improvements in this PR, we'd still need to keep tiles around, as sorting line nodes wouldn't be enough to properly position lines as we scroll. However, since all the problems related to tiling come from Chrome rules for subpixel anti-aliasing (i.e. background color, fixed height, etc.), we may simply avoid to promote tiles to rendering layers. This would allow to:\r\n\r\n1. Keep this PR's performance optimizations derived from removing inline styles from line/line-number nodes.\r\n2. Avoid problems like overlapping tiles (even if they overlap, they'll have no background).\r\n3. Have a single `.highlights` container.\r\n4. Perform a less invasive refactoring.\r\n\r\n@nathansobo: what do you think? "}}