diff options
| author | Alex Valavanis <valavanisalex@gmail.com> | 2012-10-27 11:46:53 +0000 |
|---|---|---|
| committer | Alex Valavanis <valavanisalex@gmail.com> | 2012-10-27 11:46:53 +0000 |
| commit | 5ed9dbd895fa15fa3bb03e8751e834cfa33aa16b (patch) | |
| tree | 5ad7c37524519180fc193b9eb476079a7e6a2a0f /src/widgets/eek-preview.cpp | |
| parent | Fix build error due to bad internal handling of deprecated GTK+ symbols in gt... (diff) | |
| download | inkscape-5ed9dbd895fa15fa3bb03e8751e834cfa33aa16b.tar.gz inkscape-5ed9dbd895fa15fa3bb03e8751e834cfa33aa16b.zip | |
Fix C++11 narrowing conversion errors
(bzr r11834)
Diffstat (limited to 'src/widgets/eek-preview.cpp')
| -rw-r--r-- | src/widgets/eek-preview.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
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; |
