• Home
  • About
  • J1 Session Blog: Swing Rocks – A Tribute to Filthy Rich Clients

    June 4th, 2009
    The two speakers (Pär Sikö, Martin Gunnarsson) showed off an RSS reader (Feedjii) built with Swing which looked a lot like the pimped up applications of Romain Guy. They started off  by presenting some real world examples of horribly looking Swing applications. Then they revealed their recipe for cool looking Swing applications: subtle effects, smooth animations, and custom components. For each ingredient they showed how surprisingly easy it is to implement it. They also covered the area of performance and gave a few hints on making a user interface really smooth. For this, developers have to look into: hardware acceleration flags, timing issues, caching images, image compatibility, and avoiding unnecessary transparency. They didn’t have a lot of material to talk about, though, and after 45 min they already started taking questions. Therefore, on the one hand I got confirmation again that one can build very nice user interfaces with Swing and it is not too hard provided a good UI designer is at hand. On the other hand I was slightly disappointed because I was expecting a lot more. BTW, there is a blog about developing Feedjii and it can be found here: http://www.swing-rocks.com/

    J1 Session Blog: Extreme GUI makeover: Hybrid Swing and JavaFX

    June 4th, 2009

    In the past years the Extreme GUI Makeover sessions proved extremely informative, entertaining and popular. Every year I was curious to see whether they were able to keep up to the level of the previous year or even top it. Last year the session showed first signs of wearing out. This year a completely new team (Amy Fowler, Jasper Potts etc) took over from Romain Guy and Chet Haase. With JavaFX being a big topic at this years JavaOne it was quite obvious to use this for the makeover.

    And they did a pretty good job by taking the Swing-based mail application of the 2006 session and employed JavaFX to pimp it up even more. It is obviously not too hard to integrate Swing components into a JavaFX user interface (the other way round is not really feasible). JavaFX is simply the stage and Swing components can be included as a node (after wrapping them into some kind of JavaFX component). However, hooking up the event handlers is fairly cumbersome and does not really scale for complex applications with lots of event handlers.

    One highlight of the session was the address book of the mail application. They used JavaFX and Java2D to give a 3D impression of turning the pages with the mouse. Visually stunning although the user interface is totally impractical for everyday usage.

    The culmination of the session was certainly their idea of junk mail removal. They were using an animation which launched a rocket and on impact the spam mail exploded and disappeared accordingly. Being both funny and pointless this also perfectly illustrated how easy it is to add animation to a Java application and how difficult it will be to enhance productivity of business applications by means of JavaFX.

    Interview with Canoo Fellow Dierk König

    June 4th, 2009

     

    Scott Davis interviewed Dierk König, Canoo Fellow and Grails/Groovy-Evangelist for Thirsty Head at blip.tv. In the interview, Dierk gives an inside-view about new Grails improvements, about his JavaOne talk, JavaFX and the impact of Canoo Webtest. Enjoy this interesting chat about “beauty and code”!

     

     


    Canoo @ WJAX/SOACon 2008

    November 17th, 2008

    This is just a quick note about the WJAX Java developer conference that take place last week in Munich.

    The conference program was quite balanced and beside the main stream topics about SOA (ServiceOrientedArchitektur – represented by the SOACon conference), Spring, Application Security and OSGi there was a huge number of different topics, which were addressed by several talks.

    Most interesting from my point of view were following sessions:

    • Keynote from Jonas Jacobi: Re-architecting the Web with HTML 5 Communication.
    • Talk from Karsten Lentzsch: Efficient design of swing UI’s.
    • Talk from Angelika Langer: Java programming in the age of multicore.
    • Talk from Dierk Koenig: RESTful JEE with Grails.


    Canoo was exhibiting on a booth, which gave the great opportunity to present and talk about our products UltraLightClient (ULC), the just released language application for the IPhone (using canoo.net), our demo for the new JavaFX platform and fancy UltraLightClient / Swing rich client applications. In addition Canoo members used the presence to keep in touch with existing costumers, contact new ones or presented the company to potential new staff members.

    Canoo Online Quiz

    All the visitors on the booth and all other interested software developers had and still have the possibility to join an online quiz. Its possible to win an iPod touch or one of ten ‘Groovy in Action’ books. The quiz can be found at www.canoo.com/quiz and will end at the 30.11.2008.

    Dierk König, Canoo fellow and author of the ‘Groovy in Action’ book, was holding a groovy workshop and was giving a talk about RESTful JEE with Grails.


    Scene Graph library announced at JavaPolis 2007

    December 13th, 2007

    One of the many interesting talks I attended at the JavaPolis 2007 conference was the Swinging RIA talk. At the end of the talk Chet Haase announced the brand new Java Scene Graph library. Scene Graph gives you a new way to implement your visual output in Swing. It will replace the Jazz library that provides the Java2D stuff in the current JavaFX implementation. In the current release, the API is a little bit verbose but I expect this to change as the API is not final yet.

    Screen Graph Snippet

    How does Scene Graph work? With Scene Graph, instead of subclassing a Swing component and providing your Java2D drawing instructions in a custom paint() method, you build up a data structure that declares your visual output, i.e old Java2D is the procedural approach to do graphics, whereas Scene Graph is the declarative approach.

    How does this look in practice? In Scene Graph you amazingly build up a scene graph! Each scene graph is composed of nodes and each node represents a graphics operation, e.g.

    • Painting a primitive
    • Performing an effect
    • Doing a transformation
    • Playing an animation

    So, for painting text, instead of

     protected void paintComponent(Graphics g) {
      super.paintComponent(g);
      
      Graphics2D g2 = (Graphics2D) g.create();
      g2.setFont(new Font("Arial", Font.BOLD, 128));
      g2.setRenderingHint(KEY_TEXT_ANTIALIASING, VALUE_TEXT_ANTIALIAS_ON);
      g2.drawString("Java2D", 50, 150);
      g2.dispose();
    }

    you will have

      SGText result = new SGText();
      result.setText("Scene");
      result.setFont(new Font("Arial", Font.BOLD, 128));
      result.setAntialiasingHint(VALUE_TEXT_ANTIALIAS_ON);
      result.setLocation(new Point(50, 180));
    

    My impression is that a programmer familiar with Java2D is immediately productive with the Scene Graph library. Great! And as a bonus he gets good effect and animation support for free! Wow! I hope this is just a first step to:

    • Powerful effect libraries
    • Good animation libraries
    • Visual scene graph tools
    • Integrations into existing visual tools like PhotoShop

    Another thing that makes building good-looking Swing applications easy! Good!