mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-09 23:34:20 +00:00
Font: Deprecate getStringWidth and getGlyphPositions
This commit is contained in:
parent
eddedc2d13
commit
29213e07a1
21 changed files with 179 additions and 58 deletions
|
|
@ -157,7 +157,8 @@ private:
|
|||
void resized() final
|
||||
{
|
||||
auto bounds = getLocalBounds();
|
||||
const auto labelWidth = label.getFont().getStringWidth (label.getText()) + AnimationEasingDemoConstants::largeGapSize;
|
||||
const auto labelWidth = GlyphArrangement::getStringWidthInt (label.getFont(), label.getText())
|
||||
+ AnimationEasingDemoConstants::largeGapSize;
|
||||
label.setBounds (bounds.removeFromLeft (labelWidth));
|
||||
slider.setBounds (bounds);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1117,7 +1117,7 @@ public:
|
|||
{
|
||||
auto text = rowElement->getStringAttribute (getAttributeNameForColumnId (columnId));
|
||||
|
||||
widest = jmax (widest, font.getStringWidth (text));
|
||||
widest = jmax (widest, GlyphArrangement::getStringWidthInt (font, text));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue