summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/color-profile.cpp6
-rw-r--r--src/dom/svgimpl.cpp2
-rw-r--r--src/sp-conn-end.cpp2
-rw-r--r--src/widgets/eek-preview.cpp11
-rw-r--r--src/widgets/sp-color-icc-selector.cpp6
5 files changed, 16 insertions, 11 deletions
diff --git a/src/color-profile.cpp b/src/color-profile.cpp
index a1e9dd0f1..981d527f0 100644
--- a/src/color-profile.cpp
+++ b/src/color-profile.cpp
@@ -639,9 +639,9 @@ bool ColorProfile::GamutCheck(SPColor color)
cmsUInt8Number outofgamut = 0;
guchar check_color[4] = {
- SP_RGBA32_R_U(val),
- SP_RGBA32_G_U(val),
- SP_RGBA32_B_U(val),
+ static_cast<guchar>(SP_RGBA32_R_U(val)),
+ static_cast<guchar>(SP_RGBA32_G_U(val)),
+ static_cast<guchar>(SP_RGBA32_B_U(val)),
255};
cmsDoTransform(ColorProfile::getTransfGamutCheck(), &check_color, &outofgamut, 1);
diff --git a/src/dom/svgimpl.cpp b/src/dom/svgimpl.cpp
index cf28dfec5..87f43af81 100644
--- a/src/dom/svgimpl.cpp
+++ b/src/dom/svgimpl.cpp
@@ -119,7 +119,7 @@ SVGTableEntry interfaceTable[] =
{ "SVGUnitTypes", SVG_UNIT_TYPES },
{ "SVGURIReference", SVG_URI_REFERENCE },
{ "SVGViewSpec", SVG_VIEW_SPEC },
- { "SVGZoomAndPan", SVG_ZOOM_AND_PAN }
+ { "SVGZoomAndPan", static_cast<int>(SVG_ZOOM_AND_PAN)}
};
diff --git a/src/sp-conn-end.cpp b/src/sp-conn-end.cpp
index f8d5694da..cabda82d3 100644
--- a/src/sp-conn-end.cpp
+++ b/src/sp-conn-end.cpp
@@ -152,7 +152,7 @@ sp_conn_get_route_and_redraw(SPPath *const path,
// Set sensible values incase there the connector ends are not
// attached to any shapes.
Geom::PathVector conn_pv = path->_curve->get_pathvector();
- double endPos[2] = { 0, conn_pv[0].size() };
+ double endPos[2] = { 0.0, static_cast<double>(conn_pv[0].size()) };
SPConnEnd** _connEnd = path->connEndPair.getConnEnds();
for (unsigned h = 0; h < 2; ++h) {
diff --git a/src/widgets/eek-preview.cpp b/src/widgets/eek-preview.cpp
index 953beb69d..72db91373 100644
--- a/src/widgets/eek-preview.cpp
+++ b/src/widgets/eek-preview.cpp
@@ -229,9 +229,14 @@ static gboolean eek_preview_draw(GtkWidget* widget, cairo_t* cr)
GtkAllocation allocation;
gtk_widget_get_allocation(widget, &allocation);
EekPreview* preview = EEK_PREVIEW(widget);
- GdkColor fg = { 0, preview->_r, preview->_g, preview->_b };
- gint insetTop = 0, insetBottom = 0;
- gint insetLeft = 0, insetRight = 0;
+
+ GdkColor fg = { 0,
+ static_cast<guint16>(preview->_r),
+ static_cast<guint16>(preview->_g),
+ static_cast<guint16>(preview->_b)};
+
+ gint insetTop = 0, insetBottom = 0;
+ gint insetLeft = 0, insetRight = 0;
if (preview->_border == BORDER_SOLID) {
insetTop = 1;
diff --git a/src/widgets/sp-color-icc-selector.cpp b/src/widgets/sp-color-icc-selector.cpp
index d04f17a30..b021ac43d 100644
--- a/src/widgets/sp-color-icc-selector.cpp
+++ b/src/widgets/sp-color-icc-selector.cpp
@@ -510,9 +510,9 @@ void ColorICCSelector::_switchToProfile( gchar const* name )
if ( trans ) {
guint32 val = _color.toRGBA32(0);
guchar pre[4] = {
- SP_RGBA32_R_U(val),
- SP_RGBA32_G_U(val),
- SP_RGBA32_B_U(val),
+ static_cast<guchar>(SP_RGBA32_R_U(val)),
+ static_cast<guchar>(SP_RGBA32_G_U(val)),
+ static_cast<guchar>(SP_RGBA32_B_U(val)),
255};
#ifdef DEBUG_LCMS
g_message("Shoving in [%02x] [%02x] [%02x]", pre[0], pre[1], pre[2]);