diff options
author | Timm Bäder <mail@baedert.org> | 2016-10-05 17:07:08 +0200 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2016-10-16 18:17:21 +0200 |
commit | 281c1e4fe547973df320c68836713b9ecd3f9688 (patch) | |
tree | ee64bcdc536c4a3881284ca00b6703a2bf941745 /gtk/gtktextview.c | |
parent | 08c1c584b3c9644bf96968437cf55d816c8ef5b0 (diff) | |
download | gtk+-281c1e4fe547973df320c68836713b9ecd3f9688.tar.gz |
widget: Remove cursor-aspect-ratio style property
Diffstat (limited to 'gtk/gtktextview.c')
-rw-r--r-- | gtk/gtktextview.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/gtk/gtktextview.c b/gtk/gtktextview.c index f6be78bfe8..191deaa313 100644 --- a/gtk/gtktextview.c +++ b/gtk/gtktextview.c @@ -145,6 +145,7 @@ #define SCREEN_HEIGHT(widget) text_window_get_height (GTK_TEXT_VIEW (widget)->priv->text_window) #define SPACE_FOR_CURSOR 1 +#define CURSOR_ASPECT_RATIO (0.04) #define GTK_TEXT_VIEW_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), GTK_TYPE_TEXT_VIEW, GtkTextViewPrivate)) @@ -10125,7 +10126,6 @@ text_window_invalidate_cursors (GtkTextWindow *win) GdkRectangle strong; GdkRectangle weak; gboolean draw_arrow; - gfloat cursor_aspect_ratio; gint stem_width; gint arrow_width; @@ -10150,11 +10150,7 @@ text_window_invalidate_cursors (GtkTextWindow *win) draw_arrow = (strong.x != weak.x || strong.y != weak.y); - gtk_widget_style_get (win->widget, - "cursor-aspect-ratio", &cursor_aspect_ratio, - NULL); - - stem_width = strong.height * cursor_aspect_ratio + 1; + stem_width = strong.height * CURSOR_ASPECT_RATIO + 1; arrow_width = stem_width + 1; strong.width = stem_width; @@ -10176,7 +10172,7 @@ text_window_invalidate_cursors (GtkTextWindow *win) if (draw_arrow) /* == have weak */ { - stem_width = weak.height * cursor_aspect_ratio + 1; + stem_width = weak.height * CURSOR_ASPECT_RATIO + 1; arrow_width = stem_width + 1; weak.width = stem_width; |