| 12 | |
| 13 | namespace zlgui { |
| 14 | juce::Rectangle<float> UIBase::getRoundedShadowRectangleArea(juce::Rectangle<float> box_bounds, float corner_size, |
| 15 | const FillRoundedShadowRectangleArgs& margs) { |
| 16 | const auto radius = juce::jmax(juce::roundToInt(corner_size * margs.blur_radius * 1.5f), 1); |
| 17 | return box_bounds.withSizeKeepingCentre( |
| 18 | box_bounds.getWidth() - static_cast<float>(radius) - 1.42f * corner_size, |
| 19 | box_bounds.getHeight() - static_cast<float>(radius) - 1.42f * corner_size); |
| 20 | } |
| 21 | |
| 22 | juce::Rectangle<float> UIBase::fillRoundedShadowRectangle(juce::Graphics& g, |
| 23 | juce::Rectangle<float> box_bounds, |