mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Formspecs: Fix text clipped by scrollbars (#7816)
This commit is contained in:
parent
0e306c0842
commit
3a992ce76d
2 changed files with 4 additions and 0 deletions
|
@ -1401,6 +1401,8 @@ void GUIEditBoxWithScrollBar::createVScrollBar()
|
||||||
|
|
||||||
m_scrollbar_width = skin ? skin->getSize(gui::EGDS_SCROLLBAR_SIZE) : 16;
|
m_scrollbar_width = skin ? skin->getSize(gui::EGDS_SCROLLBAR_SIZE) : 16;
|
||||||
|
|
||||||
|
RelativeRect.LowerRightCorner.X -= m_scrollbar_width + 4;
|
||||||
|
|
||||||
irr::core::rect<s32> scrollbarrect = m_frame_rect;
|
irr::core::rect<s32> scrollbarrect = m_frame_rect;
|
||||||
scrollbarrect.UpperLeftCorner.X += m_frame_rect.getWidth() - m_scrollbar_width;
|
scrollbarrect.UpperLeftCorner.X += m_frame_rect.getWidth() - m_scrollbar_width;
|
||||||
m_vscrollbar = Environment->addScrollBar(false, scrollbarrect, getParent(), getID());
|
m_vscrollbar = Environment->addScrollBar(false, scrollbarrect, getParent(), getID());
|
||||||
|
|
|
@ -1482,6 +1482,8 @@ void intlGUIEditBox::createVScrollBar()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
RelativeRect.LowerRightCorner.X -= m_scrollbar_width + 4;
|
||||||
|
|
||||||
irr::core::rect<s32> scrollbarrect = FrameRect;
|
irr::core::rect<s32> scrollbarrect = FrameRect;
|
||||||
scrollbarrect.UpperLeftCorner.X += FrameRect.getWidth() - m_scrollbar_width;
|
scrollbarrect.UpperLeftCorner.X += FrameRect.getWidth() - m_scrollbar_width;
|
||||||
m_vscrollbar = Environment->addScrollBar(false, scrollbarrect, getParent(), getID());
|
m_vscrollbar = Environment->addScrollBar(false, scrollbarrect, getParent(), getID());
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue