Yeah, I agree. The concentric blue rectangles seemed like a good idea when I first started, but they clutter the code up too much. I think I’ll remove them when I get some free time.
Update: changes made
I’ve considered the same question in the past, though I never actually implemented a solution. If I were to do it now, I would probably convert the attributes and ranges to a json string and then save that string. When reopening the app the json could be reconverted to the attributes and applied to the original string.
I have mixed feelings about that. I feel bad that I distracted the Flutter team from more important GitHub issues that they are working on. On the other hand, writing for a popular audience is a way to educate people about aspects of Flutter they might not otherwise think about. And I’m glad it resulted in bringing attention to an issue that I think is important, hopefully not just to me.
Thank you for taking the time to reply, Ian. I’m glad to see the related GitHub issues you had opened. I hadn’t seen the metrics related ones in my earlier research.
My initial despair was because when studying the current API, it appeared to be a design decision to hide the low level text engine API. And if it is a design…
The adapter has a reference to the old list. If you assign a new list to your data, then the adapter will no longer have a reference to the new list. I don’t remember clearly right now but I think it just stops updating the adapter. I made that mistake when I was learning. You can try it out and see for yourself.