diff --git a/src/osgWidget/Input.cpp b/src/osgWidget/Input.cpp index bdda2f48c..d230ae5ad 100644 --- a/src/osgWidget/Input.cpp +++ b/src/osgWidget/Input.cpp @@ -165,8 +165,11 @@ bool Input::keyDown(int key, int mask, WindowManager*) { void Input::setCursor(Widget*) { } -unsigned int Input::calculateBestYOffset(const std::string& s) { - const osgText::FontResolution fr(_text->getCharacterHeight(), _text->getCharacterHeight()); +unsigned int Input::calculateBestYOffset(const std::string& s) +{ + + const osgText::FontResolution fr(static_cast(_text->getCharacterHeight()), + static_cast(_text->getCharacterHeight())); osgText::String utf(s);