diff options
Diffstat (limited to 'gtk')
-rw-r--r-- | gtk/PlatGTK.cxx | 4 | ||||
-rw-r--r-- | gtk/ScintillaGTK.cxx | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/gtk/PlatGTK.cxx b/gtk/PlatGTK.cxx index 1fbdf4835..bb53bd693 100644 --- a/gtk/PlatGTK.cxx +++ b/gtk/PlatGTK.cxx @@ -457,8 +457,8 @@ void SurfaceImpl::RectangleDraw(PRectangle rc, ColourDesired fore, ColourDesired void SurfaceImpl::FillRectangle(PRectangle rc, ColourDesired back) { PenColour(back); if (context && (rc.left < maxCoordinate)) { // Protect against out of range - rc.left = lround(rc.left); - rc.right = lround(rc.right); + rc.left = std::round(rc.left); + rc.right = std::round(rc.right); cairo_rectangle(context, rc.left, rc.top, rc.right - rc.left, rc.bottom - rc.top); cairo_fill(context); diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx index 2fbeae39c..29cf5d3ac 100644 --- a/gtk/ScintillaGTK.cxx +++ b/gtk/ScintillaGTK.cxx @@ -1681,8 +1681,8 @@ gint ScintillaGTK::PressThis(GdkEventButton *event) { evbtn = gdk_event_copy(reinterpret_cast<GdkEvent *>(event)); buttonMouse = event->button; Point pt; - pt.x = floor(event->x); - pt.y = floor(event->y); + pt.x = std::floor(event->x); + pt.y = std::floor(event->y); PRectangle rcClient = GetClientRectangle(); //Platform::DebugPrintf("Press %0d,%0d in %0d,%0d %0d,%0d\n", // pt.x, pt.y, rcClient.left, rcClient.top, rcClient.right, rcClient.bottom); @@ -1811,12 +1811,12 @@ gint ScintillaGTK::ScrollEvent(GtkWidget *widget, GdkEventScroll *event) { sciThis->smoothScrollY += event->delta_y * smoothScrollFactor; sciThis->smoothScrollX += event->delta_x * smoothScrollFactor;; if (ABS(sciThis->smoothScrollY) >= 1.0) { - const int scrollLines = trunc(sciThis->smoothScrollY); + const int scrollLines = std::trunc(sciThis->smoothScrollY); sciThis->ScrollTo(sciThis->topLine + scrollLines); sciThis->smoothScrollY -= scrollLines; } if (ABS(sciThis->smoothScrollX) >= 1.0) { - const int scrollPixels = trunc(sciThis->smoothScrollX); + const int scrollPixels = std::trunc(sciThis->smoothScrollX); sciThis->HorizontalScrollTo(sciThis->xOffset + scrollPixels); sciThis->smoothScrollX -= scrollPixels; } |