diff --git a/src/components/ComponentList.cpp b/src/components/ComponentList.cpp index 9a2d1c1dd..73aa9961a 100644 --- a/src/components/ComponentList.cpp +++ b/src/components/ComponentList.cpp @@ -162,7 +162,7 @@ void ComponentList::render(const Eigen::Affine3f& parentTrans) Eigen::Vector3f dim(mSize.x(), mSize.y(), 0); dim = trans * dim - trans.translation(); Renderer::pushClipRect(Eigen::Vector2i((int)trans.translation().x(), (int)trans.translation().y()), - Eigen::Vector2i((int)round(dim.x()), (int)round(dim.y()))); + Eigen::Vector2i((int)round(dim.x()), (int)round(dim.y() + 1))); // scroll the camera trans.translate(Eigen::Vector3f(0, -round(mCameraOffset), 0)); diff --git a/src/components/MenuComponent.cpp b/src/components/MenuComponent.cpp index 6094547c4..443b847b1 100644 --- a/src/components/MenuComponent.cpp +++ b/src/components/MenuComponent.cpp @@ -50,16 +50,17 @@ void MenuComponent::updateSize() float height = TITLE_HEIGHT + mList->getTotalRowHeight() + getButtonGridHeight() + 2; if(height > maxHeight) { - height = TITLE_HEIGHT + getButtonGridHeight() + 2; + height = TITLE_HEIGHT + getButtonGridHeight(); int i = 0; - while(height < maxHeight && i < mList->size()) + while(i < mList->size()) { float rowHeight = mList->getRowHeight(i); if(height + rowHeight < maxHeight) height += rowHeight; + else + break; i++; } - height += 2; } setSize(Renderer::getScreenWidth() * 0.5f, height);