I'm working on a project that makes use of a JTextArea class and I'm saving text written as HTML. I would like to encorporate the ability to format plain text code just as you are doing here on this site using (code)(/code) indicators. I know I'm not showing the square brackets. I'm sure you understand why. Since someone has already created a class or method that does this kind of formatting, I didn't see any point in trying to re-invent the wheel. So, may I request a copy of the class or method responsible for formatting pain text code to HTML?
Aside from being in Perl, the UBB code is a commercial product we bought; I don't believe we're at liberty to give it away to people. However you may be interested in the code developed so far for our prospective open-source replacement for UBB: