GNOME Bugzilla – Bug 580603
gedit newline search causes a pango warning
Last modified: 2018-02-10 04:35:30 UTC
this report has been filed here: https://bugs.edge.launchpad.net/ubuntu/+source/gedit/+bug/366436 "Steps to reproduce : Find a file with Windows-style (\r\n / CR+LF) style newlines and search for the LF character (\n). If you don't have one, hit Enter a few times, and replace \n with \r\n. Output : When I try to search for just \n within the \r\n style newlines, I get this message : sys:1: PangoWarning: pango_layout_get_cursor_pos: assertion `index >= 0 && index <= layout->length' failed" Thanks,
Gtktextview bug: index in gtk_text_layout_get_cursor_locations is obtained by calling line_display_iter_to_index which in turns calls gtk_text_iter_get_visible_line_index the latter contains a loop over the line segments: my guess it's that it doesn't handle \r\n correctly.
Yeah, we have an open bug about issues with \r\n handling, I think
We're moving to gitlab! As part of this move, we are closing bugs that haven't seen activity in more than 5 years. If this issue is still imporant to you and still relevant with GTK+ 3.22 or master, please consider creating a gitlab issue for it.