0

instable when using reasonable sized files

Sebastian Konietzny 13 years ago updated by Alexander Blach (Developer) 13 years ago 7
the app crashes when using files of a size of 5 mb! that's not acceptable as this size should be no problem at all!
Sorry, a 5 MB is too large to syntax highlight on the iPad - especially on a first generation device. The iPad has no concept of virtual memory, so it's quickly running out of memory and crashing as a result.
maybe a "open without syntax highlighting" option would fix the problem
Try to open the same text file in another editor on iOS - even the built-in Notes app - and you will see that Textastic actually handles large files fairly well compared to other editors.


In order to support this, I would have to completely rewrite the editor to only map those parts of the file into memory that are currently displayed instead of loading and analyzing the whole file. I'm not going to do that, sorry. 

i didn't mean rewriting the whole code. i just mean loading and displaying the content, without analyzing and syntax processing. syntax highlighting takes a huge part of the processing when opening a file, right?
this sounds like a reasonable suggestion. i opened a text file that represents the output of a programm, so there is actua
ly no need for syntax highlighting at all in this case.
In my case, Textastic hang with only 91kb file, jquery 1.7.1 min .js, using iPad2.

For a large file, what about the partial loading or streaming? (of course I totally have no idea about iOS development.)

And, 'mr. staff' had better let us know the limit of file size when Textastic attempt to load a large file, before it crashes or hang.
Hi, minified files are basically just one line of code. If you change one character in this line, Textastic has to highlight and relayout this line due to how the syntax highlighter works.

I don't recommend editing minified files with Textastic.