summaryrefslogtreecommitdiff
path: root/gtk/gtktextmark.c
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2001-01-12 23:23:40 +0000
committerHavoc Pennington <hp@src.gnome.org>2001-01-12 23:23:40 +0000
commitf4b31ff5e6564e8d07f3ae14f378c6f9a8626203 (patch)
tree1b839b474e3b8a85192bb7e585c1b5e4883a4c53 /gtk/gtktextmark.c
parent8e1a69c28b54d6176339bc375699c34173de2496 (diff)
downloadgtk+-f4b31ff5e6564e8d07f3ae14f378c6f9a8626203.tar.gz
offset the current invalid region, fixes redraw bug while scrolling the
2001-01-12 Havoc Pennington <hp@redhat.com> * gdk/x11/gdkgeometry-x11.c (gdk_window_scroll): offset the current invalid region, fixes redraw bug while scrolling the text widget * gtk/gtktextview.c, gtk/gtktextview.h: Rearrange the scrolling/validation/etc. code in a major way, so it seems to make sense to me. Probably isn't genuinely that much better, but... * gtk/gtktexttag.c (set_fg_color): fix name of property used for notifies * gtk/gtktextmark.c (gtk_text_mark_get_left_gravity): new function
Diffstat (limited to 'gtk/gtktextmark.c')
-rw-r--r--gtk/gtktextmark.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/gtk/gtktextmark.c b/gtk/gtktextmark.c
index f4dae7c996..1f0da6835b 100644
--- a/gtk/gtktextmark.c
+++ b/gtk/gtktextmark.c
@@ -213,6 +213,26 @@ gtk_text_mark_get_buffer (GtkTextMark *mark)
return _gtk_text_btree_get_buffer (seg->body.mark.tree);
}
+/**
+ * gtk_text_mark_get_left_gravity:
+ * @mark: a #GtkTextMark
+ *
+ *
+ *
+ * Return value: %TRUE if the mark has left gravity, %FALSE otherwise
+ **/
+gboolean
+gtk_text_mark_get_left_gravity (GtkTextMark *mark)
+{
+ GtkTextLineSegment *seg;
+
+ g_return_val_if_fail (GTK_IS_TEXT_MARK (mark), FALSE);
+
+ seg = mark->segment;
+
+ return seg->type == &gtk_text_left_mark_type;
+}
+
/*
* Macro that determines the size of a mark segment:
*/