Show code after theme is applied

Vitaly Ishkulov 12 years ago updated 12 years ago 3
In term of user experience, maybe it's better to display code (when opening file) when the theme is applied?

I know, some of you say that you can start reading unformatted text faster then when you are waiting for the theme to be applied. But when the text is jumpy during the process of "theme application", it's really hard to read it anyway.   
I'm not sure if I understand you correctly, but Textastic displays highlighted source code as soon as the first 100 lines are highlighted in a background thread. Before that, it will display a version of the text without syntax highlighting. I think that's better than displaying nothing before the text is highlighted.
The speed of highlighting also depends on a lot of factors like file size, file type, file complexity and device type. It can't be predicted how long it takes to highlight the first few lines. Also, the app does not just display the plain text, but also starts to layout the text to calculate the line height after word wrap. It's a little more complex than what the user sees on the screen.
Well, I mean that you could replace that jumpy text in the beginning. You can set the alpha to zero until that first 100 lines are highlighted. 
So that will not be too much delay for the user if you wait for the first 100 lines only.
I tested on iPad 2 and new iPad highlighting takes less than a second for 150 lines text. Probably the original iPad is a little bit slower, but anyway from the UX point of view it's much better to show ready text than push plain text and update it to highlighted in 0.5sec after it appears. Trust me :)

PS well, actually if it's hard to implement, just don't worry. Sometimes I'm maniacally attentive to details.