ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> anygui-devel
anygui-devel
[Anygui-devel] On AnyGUI Core
by Peter Damoc other posts by this author
Aug 5 2005 1:57AM messages near this date
[Anygui-devel] =?ISO-8859-1?Q??= | Re: [Anygui-devel] On AnyGUI Core
Hello list,

I've been looking around at python GUI toolkits just for fun and I came  
across AnyGUI.
It is very impressive but I think it solves the wrong problem. Let me  
explain myself:
People want to create GUIs but there are very few people that want "just"  
an user interface, most of them want their GUI to work flawlessly. The  
fact that it can run on different platforms on different toolkits might  
not be such a great thing if the developers of the app will have to  
continuously "fix" the app for some esoteric combinations of OS  
versions-toolkit versions-python versions. This distracts them from  
solving the real problem: what the app should do.
AnyGUI tries to unify the API and use existing toolkits BUT in this it  
opens not one but many cans of worms, not only will the end user have to  
deal with the quirks of one toolkit but with the quirks of many.

As a programmer I would like to have is an OSS python GUI toolkit that  
looks great everywhere and acts the same on all platforms without custom  
hack in the app code.
There is currently no such thing and my little mind cannot understand why.
Ok... so its a lot of work to create such a thing BUT I could not find any  
project that aims to create such a thing. PyUI looked like it could be  
something in the lines of what I'm looking for but from what I can see....  
the people creating it have a different target.

Here is how I see such a toolkit approached:
- defined the windowing (Frames and Panels)
- defined the layout (Layout managers, for starters something like  
BoxSizer and GidBagSizer from wxpython should do)
- defined the basic events/event loop
- defined the basic widgets (label, textfield, button, list, etc.)
- defined the renderer (this is the thing that actually creates the visual  
part of the widgets based on their attributes)
- the renderer should contain some kind of mechanism for rendering  
individual widgets, for starters a bitmap based one would be enough) think  
of something that could take a archive of PNGs and mimic the appearance of  
Windows, Mac, different themes of GTK or QT.

Advantages:
- once past the basic implementation of the windowing and event system  
people could test it and help implement the widgets (let's say the follow  
the implementation guidelines for let's say Button)
- this is a top-down implementation so in theory it should be less  
buggy.... maybe for starters we could use part of an established toolkit  
for the windowing and drawing only to replace it with a custom system  
written specifically for the job.

Every time I look at a toolkit I try to see how well the developers  
learned from their predecessors. For example... one of the best help  
systems I've come across is the wxPython Demo. In my view this should be  
present in each and every toolkit out there. Most of what I know today I  
learned from the Demo.

Now to the real question of this email.
What should a crazy enough person do to try and build such a toolkit? How  
could he reuse the work that went into AnyGUI?

Thanks for reading so far. :)

Peter.


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
Thread:
Peter Damoc
Magnus Lie Hetland
Peter Damoc
Magnus Lie Hetland
Peter Damoc
Magnus Lie Hetland
Greg Ewing
Peter Damoc
Greg Ewing
Magnus Lie Hetland
Peter Damoc
Donnal Walter
Magnus Lie Hetland
David McNab
Peter Damoc
Magnus Lie Hetland
David McNab
Peter Damoc
David McNab

Privacy Policy | Email Opt-out | Feedback | Syndication
© 2004 ActiveState, a division of Sophos All rights reserved