aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/CallTip.cxx
diff options
context:
space:
mode:
authorNeil Hodgson <nyamatongwe@gmail.com>2018-04-20 11:40:07 +1000
committerNeil Hodgson <nyamatongwe@gmail.com>2018-04-20 11:40:07 +1000
commit24ebee4c40fff56602bd786d0c1291041a05a6f9 (patch)
tree8fa9c4f1ca3e0db1f280f14ba89376b3e7fc1734 /src/CallTip.cxx
parent9f0aa483ef535c34fb0bb627c71ae99f750b96e9 (diff)
downloadscintilla-mirror-24ebee4c40fff56602bd786d0c1291041a05a6f9.tar.gz
Undo part of last change as Xcode Clang doesn't like assigning long to int without cast.
Diffstat (limited to 'src/CallTip.cxx')
-rw-r--r--src/CallTip.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/CallTip.cxx b/src/CallTip.cxx
index ffd808c66..7b322afeb 100644
--- a/src/CallTip.cxx
+++ b/src/CallTip.cxx
@@ -151,7 +151,7 @@ void CallTip::DrawChunk(Surface *surface, int &x, const char *s,
} else if (IsTabCharacter(s[startSeg])) {
xEnd = NextTabPos(x);
} else {
- xEnd = x + lround(surface->WidthText(font, s + startSeg, endSeg - startSeg));
+ xEnd = x + static_cast<int>(lround(surface->WidthText(font, s + startSeg, endSeg - startSeg)));
if (draw) {
rcClient.left = static_cast<XYPOSITION>(x);
rcClient.right = static_cast<XYPOSITION>(xEnd);
@@ -173,7 +173,7 @@ int CallTip::PaintContents(Surface *surfaceWindow, bool draw) {
PRectangle rcClient(1.0f, 1.0f, rcClientSize.right - 1, rcClientSize.bottom - 1);
// To make a nice small call tip window, it is only sized to fit most normal characters without accents
- const int ascent = lround(surfaceWindow->Ascent(font) - surfaceWindow->InternalLeading(font));
+ const int ascent = static_cast<int>(lround(surfaceWindow->Ascent(font) - surfaceWindow->InternalLeading(font)));
// For each line...
// Draw the definition in three parts: before highlight, highlighted, after highlight
@@ -282,7 +282,7 @@ PRectangle CallTip::CallTipStart(Sci::Position pos, Point pt, int textHeight, co
look = newline + 1;
numLines++;
}
- lineHeight = lround(surfaceMeasure->Height(font));
+ lineHeight = static_cast<int>(lround(surfaceMeasure->Height(font)));
// The returned
// rectangle is aligned to the right edge of the last arrow encountered in