Subject: bug#56682: Fix the long lines font locking related slowdowns

From: Gerd Möllmann <[email-masked]>
Date: Tue, 26 Jul 2022 15:08:18 +0200

What about the following idea, in general.  Sorry if that is in the
wrong sub-thread, I'm beginning to loose orientation a bit.

While iterating,

- remmember where we started, say it's 'start_pos'.

- when reaching start_pos + X, without reaching a line end, refuse to do
  any complex stuff, no faces, invisible text and so on.

I could think of numerous variations of that theme.

I just loaded long-lines.xml in VSCode, and it seems to do something
like that.  It says that "tokenization has been disabled" in the long
line.  The long line doesn't have the highlighting that the shorter ones
have, and VSCode also wraps the long line instead of truncating it.