Last fall while working on some small class projects I used several different layout managers, but found them somewhat restrictive with respect to what I wanted to do. I noticed in the TOC of the book that you apparently can create customized layout managers. I was unaware of this and was wondering what sort of limitations there might be imposed in creating your own layout manager. Thanks, Mike
Mike<br />SCJP 1.4<br />----------------------------<br />mdcleary@earthlink.net<br />----------------------------<br />There are 10 types of people<br />in the world. Those that <br />understand binary, and those<br />that don't.
Anyone can write or use any custom layout manager, though sometimes it takes a bit of doing to make it work right. You just need to write a class that implements LayoutManager interface (or, optionally, its subinterface LayoutManager2). This page has more information, along with two examples of custom layout managers: http://java.sun.com/docs/books/tutorial/uiswing/layout/custom.html
To give credit to the book, these things are covered. However from experience i have to say that the normal layoutmanagers suffice. Maybe take a look at your design and try to use the standard ones in java. That will be easier maintenance (for others) than creating your own.
Thanks all! While it may be harder to maintain if you write your own, if there are specific things you want to do with the layout, it seems like the only way to go. Thanks, Mike
Mike<br />SCJP 1.4<br />----------------------------<br />mdcleary@earthlink.net<br />----------------------------<br />There are 10 types of people<br />in the world. Those that <br />understand binary, and those<br />that don't.
Evacuate the building! Here, take this tiny ad with you:
a bit of art, as a gift, the permaculture playing cards