Skip to content

Commit

Permalink
Enough room for the bounding rect
Browse files Browse the repository at this point in the history
  • Loading branch information
baconpaul committed Sep 2, 2024
1 parent 9a93356 commit 1d70174
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/sst/jucegui/components/TabbedComponent.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,15 @@ struct TabbedComponent : juce::TabbedComponent, style::StyleConsumer

const auto &st = parentComp->style();

auto b = getLocalBounds().withHeight(getHeight() + 10).reduced(1);

if (isFrontTab())
{
if (hover)
g.setColour(
st->getColour(Styles::styleClass, Styles::tabSelectedFillColor_hover));
else
g.setColour(st->getColour(Styles::styleClass, Styles::tabSelectedFillColor));
auto b = getLocalBounds().withHeight(getHeight() + 5);
g.fillRoundedRectangle(b.toFloat(), 4);
g.setColour(st->getColour(Styles::styleClass, Styles::tabSelectedFillColor_hover));
g.drawRoundedRectangle(b.toFloat(), 4, 1);
Expand All @@ -99,7 +100,6 @@ struct TabbedComponent : juce::TabbedComponent, style::StyleConsumer
else
{
g.setColour(st->getColour(Styles::styleClass, Styles::tabUnselectedOutlineColor));
auto b = getLocalBounds().withHeight(getHeight() + 5);
g.drawRoundedRectangle(b.toFloat(), 4, 1);

if (hover)
Expand Down

0 comments on commit 1d70174

Please sign in to comment.