Font (Font originalFont, int style, float size) { Font derivedFont = originalFont.deriveFont(style, size); if (Font.DIALOG.equals(derivedFont.getFamily()) && !Font.DIALOG.equals(originalFont.getFamily())) { // workaround for JBR-3423 return originalFont.deriveFont(size); } return derivedFont; }