+Sat Mar 13 02:55:51 2004 Matthias Clasen <maclas@gmx.de>
+
+ Fix middle button pasting in the TextView (#81880, reported
+ by Evert Verhellen, patch by Paolo Borelli):
+
+ * gtk/gtktextview.c (gtk_text_view_button_press_event): Retrieve
+ the insert mark and move the cursor to it making sure of also
+ scroll the window if needed.
+
+ * gtk/gtktextbuffer.c (pre_paste_prep): Move the insert mark
+ to the insertion point.
+
Sat Mar 13 01:38:55 2004 Matthias Clasen <maclas@gmx.de>
* gtk/gtkcombobox.c (gtk_combo_box_remove): Add a remove
+Sat Mar 13 02:55:51 2004 Matthias Clasen <maclas@gmx.de>
+
+ Fix middle button pasting in the TextView (#81880, reported
+ by Evert Verhellen, patch by Paolo Borelli):
+
+ * gtk/gtktextview.c (gtk_text_view_button_press_event): Retrieve
+ the insert mark and move the cursor to it making sure of also
+ scroll the window if needed.
+
+ * gtk/gtktextbuffer.c (pre_paste_prep): Move the insert mark
+ to the insertion point.
+
Sat Mar 13 01:38:55 2004 Matthias Clasen <maclas@gmx.de>
* gtk/gtkcombobox.c (gtk_combo_box_remove): Add a remove
+Sat Mar 13 02:55:51 2004 Matthias Clasen <maclas@gmx.de>
+
+ Fix middle button pasting in the TextView (#81880, reported
+ by Evert Verhellen, patch by Paolo Borelli):
+
+ * gtk/gtktextview.c (gtk_text_view_button_press_event): Retrieve
+ the insert mark and move the cursor to it making sure of also
+ scroll the window if needed.
+
+ * gtk/gtktextbuffer.c (pre_paste_prep): Move the insert mark
+ to the insertion point.
+
Sat Mar 13 01:38:55 2004 Matthias Clasen <maclas@gmx.de>
* gtk/gtkcombobox.c (gtk_combo_box_remove): Add a remove
+Sat Mar 13 02:55:51 2004 Matthias Clasen <maclas@gmx.de>
+
+ Fix middle button pasting in the TextView (#81880, reported
+ by Evert Verhellen, patch by Paolo Borelli):
+
+ * gtk/gtktextview.c (gtk_text_view_button_press_event): Retrieve
+ the insert mark and move the cursor to it making sure of also
+ scroll the window if needed.
+
+ * gtk/gtktextbuffer.c (pre_paste_prep): Move the insert mark
+ to the insertion point.
+
Sat Mar 13 01:38:55 2004 Matthias Clasen <maclas@gmx.de>
* gtk/gtkcombobox.c (gtk_combo_box_remove): Add a remove
+Sat Mar 13 02:55:51 2004 Matthias Clasen <maclas@gmx.de>
+
+ Fix middle button pasting in the TextView (#81880, reported
+ by Evert Verhellen, patch by Paolo Borelli):
+
+ * gtk/gtktextview.c (gtk_text_view_button_press_event): Retrieve
+ the insert mark and move the cursor to it making sure of also
+ scroll the window if needed.
+
+ * gtk/gtktextbuffer.c (pre_paste_prep): Move the insert mark
+ to the insertion point.
+
Sat Mar 13 01:38:55 2004 Matthias Clasen <maclas@gmx.de>
* gtk/gtkcombobox.c (gtk_combo_box_remove): Add a remove
if (gtk_text_buffer_get_selection_bounds (buffer, &start, &end))
*insert_point = start;
}
+
+ gtk_text_buffer_move_mark_by_name (buffer, "insert", insert_point);
}
static void
else if (event->button == 2)
{
GtkTextIter iter;
+ GtkTextMark *mark;
gtk_text_layout_get_iter_at_pixel (text_view->layout,
&iter,
event->y + text_view->yoffset);
gtk_text_buffer_paste_clipboard (get_buffer (text_view),
- gtk_widget_get_clipboard (widget, GDK_SELECTION_PRIMARY),
- &iter,
- text_view->editable);
+ gtk_widget_get_clipboard (widget, GDK_SELECTION_PRIMARY),
+ &iter,
+ text_view->editable);
+
+ mark = gtk_text_buffer_get_mark (get_buffer (text_view), "insert");
+ gtk_text_buffer_get_iter_at_mark (get_buffer (text_view),
+ &iter,
+ mark);
+
+ gtk_text_buffer_place_cursor (get_buffer (text_view), &iter);
+
+ DV(g_print (G_STRLOC": scrolling onscreen\n"));
+ gtk_text_view_scroll_mark_onscreen (text_view,
+ gtk_text_buffer_get_mark (get_buffer (text_view),
+ "insert"));
return TRUE;
}
else if (event->button == 3)