I was wondering if there was a library or something that could indent and embellish a code in a JTextArea instead of an ugly plain text ?
How sophisticated do you want your formatting to be? RSyntaxTextArea
is very nice but fairly heavyweight; you can instead get HTML formatting in a (standard Swing) JTextPane
.