This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
I've got some logging I need to do, and including newlines seemed a pretty reasonable way to do it - basically when malformed HTML is passed to the lightweight renderer, in dev builds, there should be formatted output like: Malformed html: <html>foo <qrzmph> bar </html> ^ To indicate exactly where the problem was for debugging purposes. I was rather surprised to find the only output on the console or in the log was "Malformed html:".
Works for me. ---%<--- import org.openide.ErrorManager; public class Whatever { public static void main(String ignore[]) { ErrorManager.getDefault().log(ErrorManager.WARNING, "Hey there!\nA multiline message."); } } ---%<--- Run w/ internal execution, prints both lines, to both ide.log and console.
Interesting. Definitely doesn't work for me. Are you sure there's nothing different going on with routing output from internal execution?
What doesn't work for me? The attached sample class, or some stuff you are doing? If you are having problems, please reduce them to a reproducible test case. NbErrorManager does not do anything special with multiline messages. It just prints them as it gets them. BTW o.n.c.TopLogging may be of interest. There is some buffering going on for ide.log, which means that log file prints may be delayed by up to 15 seconds (to avoid overhead). However printing to console should be unbuffered.
verified