Open sekelsta opened 7 months ago
This looks like an upstream bug with Gtk's TextBuffer class (or something more basic than that). See:
import sys
import gi
gi.require_version("Gtk", "3.0")
gi.require_version("GtkSource", "4")
from gi.repository import Gtk, GtkSource
buffer = Gtk.TextBuffer()
with open(sys.argv[1], "r") as f:
t = f.read()
print(len(t))
buffer.set_text(t)
source_view = Gtk.TextView.new_with_buffer(buffer)
sv = Gtk.ScrolledWindow()
sv.add(source_view)
win = Gtk.Window()
win.add(sv)
win.connect("destroy", Gtk.main_quit)
win.show_all()
Gtk.main()
In Gtk+ 4, the line simply does not render instead.
Also note that although it's not really an excuse, the line in question is 2727232 characters long. Again, not an excuse, but it's pretty uncommon :slightly_smiling_face:
Expected behaviour
Plaintext file should look like plaintext
Actual behaviour
This one line looks crazy
Steps to reproduce the behaviour
Open this file with pluma: server-debug.txt (had to trim a bit off the end to get it to upload)
MATE general version
1.26.0
Package version
1.26.0
Linux Distribution
Ubuntu 22.04.4 LTS 64 bit
Link to bugreport of your Distribution (requirement)