Closed andydotxyz closed 1 year ago
As a side note, I think it could make sense for Fyne to only create one Font object per byte slice, since it is a rather costly operation (like Gioui does). That would only reduce the leak, not remove it though, so this PR seems still required ;)
As a side note, I think it could make sense for Fyne to only create one Font object per byte slice, since it is a rather costly operation (like Gioui does).
I agree, I thought Fyne basically did the same. The leak was when changing theme at which point we do need to read new font data.
Move plan cache to the buffer object so we don't leak if the shaper / font is not needed any more
Fixes #47