how set Button FontAwesome Icon with string in vaadin -


i want save button icon in db, i'd have like:

button button = new button(); string icon = "fontawesome.cogs"; button.seticon(icon); 

or

button button = new button(); string icon = "fonticon://fontawesome/f013"; button.seticon(new themeresource(icon)); 

what's right way achieve this?

store name of icon in db , load name:

seticon(fontawesome.valueof("cogs")) 

this can fail classnotfoundexception.


Comments

Popular posts from this blog

javascript - Feed FileReader from server side files -

How to Change swipe Tab Title color in java Android -

Using globs in Perl replace one liner in TCL script -