![]() ![]() You may or may not be aware, but I am co-host of a podcast all about Java called the Java Posse along with three other guys (Tor Norbye, Carl Quinn, and Joe Nuxoll). The source code for this example can be downloaded from here. I also recommend reading or printing out the Matisse GUI Builder Legend at it provides a handy cheat sheet of what the various guidelines mean when creating a GUI in Matisse. ![]() Prerequisitesīefore following along with this article, you will need to grab NetBeans IDE 5.0 from and install it. However, my point here is to show that anyone can use Matisse to make an application-even a server-side hacker like me. I may commit atrocities in this article from a UI perspective and, if I do, apologies. I will also point out that I am not generally a Swing or even a GUI developer. My hope is that this will demonstrate what is possible with Matisse, and whet your appetite to find out more. It details a real application (albeit very small and simple) that I recently wrote to solve a real-world need. This article will outline some of the new features in Matisse and is intended to give you a taster of what is possible with it. It is a GUI builder as easy to use (with a couple of minor exceptions-more on those later) as Visual Basic, but has a huge advantage over VB in that the resulting forms and panels can be re-sized in a meaningful way, without having to write all sorts of resize event handling code. It is familiar, offers drag and drop placement, and sensible defaults that can still be altered and overridden easily for flexibility. This is a new layout manager that is not a part of standard Swing (yet), but can be freely distributed with your application. Matisse is a new GUI builder that uses the GroupLayout manager. In NetBeans 5.0, however, a new option is available. Netbeans, and various other IDEs, already had good support to help with creating grid bag layouts, but these usually involved a different view of the UI from the WYSIWYG one, and it takes a while to learn all the controls and settings even in these helper tools. This is an amazing layout manager that lets you control just about every aspect of every widget placement in every form. Swing learned much from other GUI toolkits available at the time and brought in a lot more flexibility… and some more complexity.įast forward to a year ago and the state of the art for Swing creation revolved around numerous layout managers, the most flexible (and notorious) being the GridBagLayout. To combat this and bring the possibility of richer desktop applications and a higher abstraction to GUI building in Java, Swing was created. ![]() It was also a little limiting-AWT provided a decent way of getting a few buttons and menus put into an applet or even a Java application if you were ambitious, but the results were fairly limited and simple. At the time, the GUI construction was simpler than a lot of the alternatives out there (it was the time of Motif, windows 3.1 and does anyone remember NeWS?). It was the first foothold for the language. ![]() It is a curiosity that when Java was first introduced, it made a name (some would say “became synonymous with”) simple interactive GUIs and animations in applets embedded on Web pages. We may make money when you click on links to our partners. content and product recommendations are editorially independent. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |