Hiran
Posts: 41
Nickname: jclu
Registered: Mar, 2002
|
|
Re: Help! Creating a user-customizable GUI
|
Posted: Apr 18, 2002 11:57 AM
|
|
Go to http://foundries.sourceforge.net/java/. They have a few projects that contain other GUI interfaces people have created besides the Swing interface. In terms of creating your own, it shouldn't be too hard to do. Have a way (possibly a drop down list) for the user to select the type of component they want. Then you could either ask the user for a variable name, or automatically generate one. You could even have a properties-type panel where the user can specify what constructor to use (if there are more than one constructors), the variable name (so they can change it), etc. You could also allow the user to drag and drop it onto a frame to specify the location. From a code standpoint, you could create a class that represents a user selected component. In that class would be variables that hold the properties specified in the properties panel (including the type of component). Then, when the user saves the file, your app would save the contents of each object that's representing a user selected component. It'll be a lot of work, but it's doable. Hope this helps. Hiran
|
|