Massimiliano Mirra wrote: >> In FreeRID we have picked the Fox toolkit *for now*, and we will have >> to provide some abstraction layer that allows us to make the GUI an >> interchangeable plug-in. Have you been discussing SWT, and how it relates to your goals? > They all keep the interface code in a separate file, and are designed > so that one just has to require a different file to get a different > interface. In a way, this is also about writing an abstraction layer, > but you do it on a per-program basis, and then implement the interface > based on that layer. I've thought about this, but in my experience, the UI code can take as many lines of code (or more) than the rest of the app, so aren't you writing the same app three times? Or do you have a way of doing it that avoids this? > What about a meta-language to describe interfaces (much like Glade > uses XML, though Glade is limited to GTK) and then have a program > produce specific code for the various toolkits? Another good idea, but then you're forcing someone to basically learn a new language (XML, admittedly not difficult) and API, rather than just an API. I also have my doubts as to how much you can pull out the logic of the XML description; XUL, for example, has a lot of logic embedded in the UI description file, where it doesn't belong. > This way we wouldn't need Yet Another Library and people could use the > toolkit they like most. They'll still neet Yet Another Library, won't they? For the Glade-ish management? I really, really, like the idea of separating the GUI out into a different file. There are really good reasons for doing this: for example, sometimes just switching the back-end isn't enough; you need to change the complete layout of the application to make it fit on a particular device, like a handheld, or a dumb text terminal (both are very real, and useful, target platforms). At the moment, with *every* toolkit available, you have to rewrite the UI, which can be a lot of work. If something like Glade or XUL is possible in a way that really separates model and control from the view, then I'd say this is the way to go. -- --- SER