Rectangle::reduced


#1

Rectangle reduced description is:
/** Returns a rectangle that is smaller than this one by a given amount.
But if i do this getLocalBounds().reduced(3, 4) it actually removes 6 pixels in total from the width and 8 from the height. So it’s smaller twice the amount, or i’m i nitpicking here?


#2

Given that the description explains exactly what the method will return, yes, I think you are nitpicking!

/** Returns a rectangle that is smaller than this one by a given amount.

    Effectively, the rectangle returned is (x + delta, y + delta, w - delta * 2, h - delta * 2).
    @see reduce, expand, expanded
*/