diff options
| author | Alex Valavanis <valavanisalex@gmail.com> | 2012-11-27 23:31:10 +0000 |
|---|---|---|
| committer | Alex Valavanis <valavanisalex@gmail.com> | 2012-11-27 23:31:10 +0000 |
| commit | 083e48b0f1e09b0f9056c6cda5a6f344a457583b (patch) | |
| tree | 03521f8104cbe3e849ba6165901ffbafaa2777ca /src/widgets/ruler.cpp | |
| parent | German translation 100% (diff) | |
| download | inkscape-083e48b0f1e09b0f9056c6cda5a6f344a457583b.tar.gz inkscape-083e48b0f1e09b0f9056c6cda5a6f344a457583b.zip | |
GTK+ 3: Migrate to GdkRGBA
(bzr r11910)
Diffstat (limited to 'src/widgets/ruler.cpp')
| -rw-r--r-- | src/widgets/ruler.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/widgets/ruler.cpp b/src/widgets/ruler.cpp index 72c839b19..5104d5a9d 100644 --- a/src/widgets/ruler.cpp +++ b/src/widgets/ruler.cpp @@ -690,7 +690,14 @@ static void sp_ruler_real_draw_pos(SPRuler *ruler, y = ROUND ((priv->position - priv->lower) * increment) + (ythickness - bs_height) / 2 - 1; } +#if GTK_CHECK_VERSION(3,0,0) + GtkStyleContext *sc = gtk_widget_get_style_context(widget); + GdkRGBA color; + gtk_style_context_get_color(sc, gtk_widget_get_state_flags(widget), &color); + gdk_cairo_set_source_rgba(cr, &color); +#else gdk_cairo_set_source_color(cr, &style->fg[gtk_widget_get_state(widget)]); +#endif cairo_move_to (cr, x, y); |
