Is the formatting below some kind of convention in Java? I personally found it more difficult to read, than the second example. Am i alone here? And is there a way to make such a custom formatting in NetBeans when choosing Source -> Format?
public boolean handleEvent(Event e) {
if (e.target == quit) System.exit(0);
else if (e.target == parent) {
// Code here
// Bug workaround
}
catch (IOException ex) { infoarea.setText("I/O Error"); }
return true;
}
(second example)
public boolean handleEvent(Event e)
{
if (e.target == quit) System.exit(0);
else if (e.target == parent)
{
// Code here
// Bug workaround
}
catch (IOException ex) { infoarea.setText("I/O Error"); }
return true;
}