diff --git a/kmtrace/kmtrace.cpp b/kmtrace/kmtrace.cpp index 9cf5267f..9e5007fe 100644 --- a/kmtrace/kmtrace.cpp +++ b/kmtrace/kmtrace.cpp @@ -1,5 +1,8 @@ #include #include +#ifdef Q_OS_SOLARIS +#include /* index(), rindex() */ +#endif #include #include #include diff --git a/umbrello/umbrello/associationwidget.cpp b/umbrello/umbrello/associationwidget.cpp index 9c5f7ba4..0e2ec525 100644 --- a/umbrello/umbrello/associationwidget.cpp +++ b/umbrello/umbrello/associationwidget.cpp @@ -1893,7 +1893,7 @@ void AssociationWidget::constrainTextPos(int &textX, int &textY, const int y0 = p0.y(); const int x1 = p1.x(); const int y1 = p1.y(); - double r = sqrt((x1 - x0) * (x1 - x0) + (y1 - y0) * (y1 - y0)) / 2; + double r = sqrt((double)(x1 - x0) * (x1 - x0) + (y1 - y0) * (y1 - y0)) / 2; if (textWidth > r) r = textWidth; // swap textCenter{X,Y} to convert from TQt coord.system.