Ummmm..
We can also write js code inside the java code file by using JSNI (javascript native interface). there are some sources file with native methods(JSNI) in app inventor.
We should add a style name for it in the TopToolbar.java (I exactly don't know how to)
And make a class for it in Ya.css
And the code will be in (ya.css):
I mean you should add a new style name in the java file of TopToolbar.java because by default it is connected with gwt-button style name so if you add that code CSS code I said directly in the gwt-button class then every button will be invisible
but I exactly don't know how to add a style name in the java file
See this documentation and this method was inherited by Button Class of GWT.
First of all you need to create a simple CSS class as I mentioned in earlier post in ya.css file because ya.css file is load in browser at the runtime now simple you need to call this method in java code so because of style rule the button was created but not show in browser window and it will not couse any error.