question: private void updateFont ( ) { String fontName = fontList . getValue ( ) ; Integer fontSize = FALLBACK_FONT_SIZE ; try { fontSize = Integer . parseInt ( fontSizeList . getValue ( ) ) ; } catch ( NumberFormatException ex ) { } font = new Font ( fontName , Font . PLAIN , fontSize ) ; preview . setFont ( font ) ; }
target:  Creates a new Font based on the current settings and also updates the preview. The created Font is not only used for the preview, but also to return it when requested from the caller.