In the past couple of week, I have been working in a java project in my 20% time over my normal 100% job time...
It's nothing extraordinary, some xml files holding the data, that I have to parse and present to the user in some "quiz format". The motivation was mainly the fact that I can't memorize facts, mostly in my short to medium term memory. I don't know if it's due to getting older or using computers ( with all the convenience of textpads, copy paste, multiple screens etc ) all the time, but the net effect is the same.
So as I needed to memorize drink recipes for one of my hobbies, I decided to have some fun out of it by writing an application to quiz myself over it and hopefully learn the recipes =) I decided to use Java for the sole purpose that I haven't written Java GUI's in years ( I think it has been since junior year undergrad that I haven't written anything java gui related ) and I was wondering how has the technology evolved.
After some online searching, I found out that thankfully AWT isn't mentioned anywhere anymore, which was a huge relief. I don't think anyone will miss AWT's awkwardness....Unfortunately though, Swing and SWT are in the same sad state that I left them.
I am no front end expert ( sadly, quite the opposite ) but I can't but applaud Apple's approach to designing GUI's through Xcode. It's simple, intuitive and totally WYSIWYG oriented. Of course, iphone's 1 screen size contributes to that, but hell I don't care. I want something that works...
I decided to use SWT, coz it looked more powerful and let's face it, I found more suitable tutorials and books related to it =) After sketching out the initial paper/more like napkin prototype, I started implementing the basic API's. The rest of the application was pretty straightforward, but the GUI part was a hell and mess. I ended up hacking the listener to imitate the flow I wanted to have. Aren't there MVC model for Java? Of course there are. Are there any MVC models that Sun promotes or dictates the way apple does? Of course not. This was one of my best lessons earned to this exercise in Java GUI's....
So now I am liking Apple a little bit more ( and not only because my brand new macbook is totally awesome ) for all the dictatorship like rules it imposes to developers. Maybe I am converting from Perl's "there are 1000 ways to do sth and we won't tell you which one to follow" to Python's "you *have* to write code using indentation and that's an order" mentality....
In any case, if someone wants to have some fun with my java hacking on a Friday late night purple rain powered session, here it is...
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment