Skip to content

optimize tiled background image rendering#812

Merged
tpae merged 1 commit intomainfrom
perf/optimize-tiled-background
Apr 8, 2026
Merged

optimize tiled background image rendering#812
tpae merged 1 commit intomainfrom
perf/optimize-tiled-background

Conversation

@RaajeevChandran
Copy link
Copy Markdown
Contributor

Summary

  • The previous tiled background implementation created a grid of individual SwiftUI Image views using nested ForEach loops.
  • For large windows with small tile images, this could generate hundreds of views just for a static background.
  • Replaced it with an NSViewRepresentable that uses NSColor(patternImage:) delegates tiling to Core Graphics which renders it as a single pattern fill regardless of window or tile size.

Changes

  • Behavior change
  • UI change (screenshots below)
  • Refactor / chore
  • Tests
  • Docs

Checklist

  • I have read CONTRIBUTING.md
  • I added/updated tests where reasonable
  • I updated docs/README as needed
  • I verified build on macOS with Xcode 16.4+

@tpae tpae merged commit da33e10 into main Apr 8, 2026
5 checks passed
@tpae tpae deleted the perf/optimize-tiled-background branch April 8, 2026 23:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants