private static List < String > parseFontFamily ( String val ) { List < String > fonts = null ; TextScanner scan = new TextScanner ( val ) ; while ( true ) { String item = scan . nextQuotedString ( ) ; if ( item == null ) item = scan . nextTokenWithWhitespace ( ' ' ) ; if ( item == null ) break ; if ( fonts == null ) fonts = new ArrayList <> ( ) ; fonts . add ( item ) ; scan . skipCommaWhitespace ( ) ; if ( scan . empty ( ) ) break ; } return fonts ; }
Parse a font family list