From a9eb179dc2c1d6583e4b12855e704e0274fdcff0 Mon Sep 17 00:00:00 2001 From: ed Date: Tue, 4 Sep 2018 14:29:52 +0100 Subject: [PATCH] Fixed a warning in the recent Label LookAndFeel changes --- modules/juce_gui_basics/widgets/juce_Label.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/juce_gui_basics/widgets/juce_Label.cpp b/modules/juce_gui_basics/widgets/juce_Label.cpp index 7591df7be8..254b47bbc0 100644 --- a/modules/juce_gui_basics/widgets/juce_Label.cpp +++ b/modules/juce_gui_basics/widgets/juce_Label.cpp @@ -157,19 +157,19 @@ void Label::componentMovedOrResized (Component& component, bool /*wasMoved*/, bo { auto& lf = getLookAndFeel(); auto f = lf.getLabelFont (*this); - auto border = lf.getLabelBorderSize (*this); + auto borderSize = lf.getLabelBorderSize (*this); if (leftOfOwnerComp) { auto width = jmin (roundToInt (f.getStringWidthFloat (textValue.toString()) + 0.5f) - + border.getLeftAndRight(), + + borderSize.getLeftAndRight(), component.getX()); setBounds (component.getX() - width, component.getY(), width, component.getHeight()); } else { - auto height = border.getTopAndBottom() + 6 + roundToInt (f.getHeight() + 0.5f); + auto height = borderSize.getTopAndBottom() + 6 + roundToInt (f.getHeight() + 0.5f); setBounds (component.getX(), component.getY() - height, component.getWidth(), height); }