After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 580603 - gedit newline search causes a pango warning
gedit newline search causes a pango warning
Status: RESOLVED OBSOLETE
Product: gtk+
Classification: Platform
Component: Widget: GtkTextView
2.16.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2009-04-28 13:39 UTC by Pedro Villavicencio
Modified: 2018-02-10 04:35 UTC
See Also:
GNOME target: ---
GNOME version: 2.25/2.26



Description Pedro Villavicencio 2009-04-28 13:39:31 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,
Comment 1 Paolo Borelli 2009-05-08 22:25:36 UTC
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.



Comment 2 Matthias Clasen 2009-05-08 22:32:25 UTC
Yeah, we have an open bug about issues with \r\n handling, I think
Comment 3 Matthias Clasen 2018-02-10 04:35:30 UTC
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.