Virtual Whitespacing doesn't work on files larger than 128KiB?

Hello all.

Virtual whitespacing stops working when I load a file greater than 128KiB.
When I go past that point inside the editor it still works, but when I save it, kill the buffer and open the file again it converts the virtual whitespacing to actual whitespaces.

Is this intended?
Is there a work around?

Thanks a lot.
Dan Zaidan

Edited by Dan Zaidan on
I know it's not helpful, but I just wanted to let you know that I confirm the same behavior.
A dangerous workaround is to: copy all content of the problematic buffer, kill the buffer, create a file with the same name (4coder doesn't seem to ask that the file already exists) and paste the contents. It does seem to work after that, but as i said it's dangerous and I wouldn't trust it. It only allows to have back virtual whitespace for that session.

If all you want to do is keep working until Allen has a solution (or confirms that is indented), then the aforementioned workaround and a backup copy before each session, should hopefully do the trick.
Thanks, John!
It's nice to know more people are facing this.

But the workaround can't delete the new file, can it?
It would suck to work on the file and lose the changes (even if I have a copy of the old file). :P
I'm not up to date with the 4.1 version, but in previous version this was intended behavior for performance reason. I haven't updated my platform layer to 4.1 yet but in previous version you could just bump the limit in the "file_settings hook". There was a place that looked like:

1
2
3
4
if ( buffer.size >= ( 128 << 10 ) ) {
    wrap_lines = false;
    use_virtual_whitespace = false;
}


And you could just change "128 << 10" to the value that worked for you.
Nice find Simon! I'm also on 4.0.30 and 128 << 10 is indeed the current value. Above that is a commented line with the value set at 192 << 10.

DanZaidan
Thanks, John!
It's nice to know more people are facing this.

But the workaround can't delete the new file, can it?
It would suck to work on the file and lose the changes (even if I have a copy of the old file). :P


I don't know for sure Dan. My guess is that it doesn't seem normal that a newly generated file can overwrite a file with the same name without warning. If you try the workaround you'll see that it works, but it doesn't seem safe!
You better try Simon's finding if you are on the old version.

EDIT: It seems there's another workaround you can do without altering the file_settings value.
After opening your file, just press ALT + X to open the command lister and select toggle_virtual_whitespace.

Edited by John on
Awesome, guys!
Thanks.