summaryrefslogtreecommitdiffstats
path: root/src/dyna-draw-context.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/dyna-draw-context.cpp')
-rw-r--r--src/dyna-draw-context.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/dyna-draw-context.cpp b/src/dyna-draw-context.cpp
index ebabeef31..ff570fb62 100644
--- a/src/dyna-draw-context.cpp
+++ b/src/dyna-draw-context.cpp
@@ -46,6 +46,7 @@
#include "context-fns.h"
#include "sp-item.h"
#include "inkscape.h"
+#include "color.h"
#define DDC_RED_RGBA 0xff0000ff
@@ -806,9 +807,10 @@ fit_and_split_calligraphics(SPDynaDrawContext *dc, gboolean release)
SPCurve *curve = sp_curve_copy(dc->currentcurve);
sp_canvas_bpath_set_bpath(SP_CANVAS_BPATH (cbp), curve);
sp_curve_unref(curve);
- guint32 fillColor = sp_desktop_get_color_tool(SP_ACTIVE_DESKTOP, "tools.calligraphic", true);
- sp_canvas_bpath_set_fill(SP_CANVAS_BPATH(cbp), fillColor , SP_WIND_RULE_EVENODD);
+ guint32 fillColor = sp_desktop_get_color_tool (SP_ACTIVE_DESKTOP, "tools.calligraphic", true);
+ double opacity = sp_desktop_get_opacity_tool (SP_ACTIVE_DESKTOP, "tools.calligraphic");
+ sp_canvas_bpath_set_fill(SP_CANVAS_BPATH(cbp), ((fillColor & 0xffffff00) | SP_COLOR_F_TO_U(opacity)), SP_WIND_RULE_EVENODD);
sp_canvas_bpath_set_stroke(SP_CANVAS_BPATH(cbp), 0x00000000, 1.0, SP_STROKE_LINEJOIN_MITER, SP_STROKE_LINECAP_BUTT);
/* fixme: Cannot we cascade it to root more clearly? */
g_signal_connect(G_OBJECT(cbp), "event", G_CALLBACK(sp_desktop_root_handler), SP_EVENT_CONTEXT(dc)->desktop);