Fix corner case of text tool up/down navigation

(gimp_text_tool_move_cursor): really go to the beginning/end of the
buffer when there are no further lines to go up/down to.
This commit is contained in:
Michael Natterer 2009-06-28 17:27:02 +02:00
parent 66cc3e5f22
commit 4c5c158bfa
1 changed files with 2 additions and 2 deletions

View File

@ -1506,12 +1506,12 @@ gimp_text_tool_move_cursor (GimpTextTool *text_tool,
if (line < 0)
{
gtk_text_iter_set_line_offset (&cursor, 0);
cursor = start;
break;
}
else if (line >= pango_layout_get_line_count (layout))
{
gtk_text_iter_forward_to_line_end (&cursor);
cursor = end;
break;
}