Can I use Css within a Swing application?

0

Is it possible to style a java application made in Swing using css or javascript?

    
asked by anonymous 19.12.2016 / 17:42

1 answer

-2

Some things can be done in the component. Here is an example of using CSS and HTML for a JButton:

jbBotao = new javax.swing.JButton();
jbBotao.setText("<html>\n<style>\ndiv {\ncolor: white;\nfont-family:arial;\nbackground-color: black\n}\n</style>\n<div>Teste</div>\n</html>");
    
23.12.2016 / 03:13