Skip to content

Fix infinite recomposition in Text.foregroundStyle(LinearGradient())#438

Open
dfabulich wants to merge 1 commit into
skiptools:mainfrom
dfabulich:gradient-infinite-recomposition
Open

Fix infinite recomposition in Text.foregroundStyle(LinearGradient())#438
dfabulich wants to merge 1 commit into
skiptools:mainfrom
dfabulich:gradient-infinite-recomposition

Conversation

@dfabulich
Copy link
Copy Markdown
Contributor

Fixes #437

Skip Pull Request Checklist:


  • AI was used to generate or assist with generating this PR. Please specify below how you used AI to help you, and what steps you have taken to manually verify the changes.

Cursor tracked this down and fixed it. I manually tested it with skiptools/skipapp-showcase#107 in Showcase Lite mode.

@cla-bot cla-bot Bot added the cla-signed label May 18, 2026
@dfabulich
Copy link
Copy Markdown
Contributor Author

I think this was caused by #424 … not sure if I'm undoing your fix in this PR.

But… what did it fix, exactly? Was there a bug you were fixing there that I could repro, and test that I didn't just re-break it?

@marcprux
Copy link
Copy Markdown
Member

I think you are right. I've updated the rationale for that earlier (admittedly minimally tested) fix at: #424 (comment)

I had intended to have the brush itself be remember'd — I'm not sure how I missed that. I've confirmed that your fix also fixes the original bug I was seeing.

Comment thread Sources/SkipUI/SkipUI/Graphics/Gradient.swift
@dfabulich dfabulich force-pushed the gradient-infinite-recomposition branch from 380fc83 to a2d969b Compare May 24, 2026 05:56
@dfabulich dfabulich requested a review from marcprux May 24, 2026 05:57
@dfabulich
Copy link
Copy Markdown
Contributor Author

I added remember, but I didn't test against Sirtet.

@dfabulich dfabulich force-pushed the gradient-infinite-recomposition branch from a2d969b to 64e8ef9 Compare May 24, 2026 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Infinite recomposition rendering Text with a .foregroundStyle(LinearGradient())

2 participants