I am a Java developer and have done a fair share of GUI application building in Java. I am new to Groovy, and, quite frankly, I am confused over a few points. Firstly a gentle rant - but there is a point to it because it involves my first question ... while Java has - in my opinion mistakenly, taken on the overly complex generics tack on in the effort to catch every possible error it can in the compile step, Groovy seems to have gone in the entirely opposite direction and made it not only possible, but extremely likely that a clean compile will not run. Why do I say this? Because I am trying to build a very simple GUI using SwingBuilder in the Groovy/Grails Tools Suite, and I constantly get clean compiles that fail on execution.
So my first question is ... how can this be that I am getting the clean compile and then the errors at runtime are so basic; like: "No class found CENTER"?
My next question is that I have the following code. And of all the constrains for Component placement, only the JButton.CENTER is honored. All the others are simply ignored. The top 'apanel' won't display unless I comment out all the code for bpanel. I've tried various other derivations for placement of Components and none work - some compile and error at runtime and some don't error at all - like these - but are not honored. Here is the code. Thank you very much in advance for any help. Also, for those that do GUI work in Groovy, do you use SwingBuilder, or do you code as you would in Java?