void (@NotNull ComponentStyle componentStyle, @NotNull Component comp) { if (!(comp instanceof JComponent c)) { return; } if (isUnderAquaBasedLookAndFeel()) { c.putClientProperty("JComponent.sizeVariant", Strings.toLowerCase(componentStyle.name())); } FontSize fontSize; if (componentStyle == ComponentStyle.MINI) { fontSize = FontSize.MINI; } else if (componentStyle == ComponentStyle.SMALL) { fontSize = FontSize.SMALL; } else { fontSize = FontSize.NORMAL; } c.setFont(getFont(fontSize, c.getFont())); Container p = c.getParent(); if (p != null) { SwingUtilities.updateComponentTreeUI(p); } }