Re: [Boa Constr] UML Topological sort, where to put it?
Status: Beta
Brought to you by:
riaan
From: Riaan B. <riaan@e.co.za> - 2001-09-13 09:42:46
|
Hi Mike, "Mike C. Fletcher" wrote: > > I've just put together a very basic class topological sort with the idea of > making the UML view a little more readable on load. Basically it takes a > pointer to a list of class objects and generates a list of generations which > are sorted so that parent classes always show up above child classes. Sounds great! I'm very glad someone has taken up this challenge. > > There is obviously more that would eventually be useful (weighting members > of a generation so that they clump together with hereditarily similar > members being the most obvious first step. Before I start into that, > though, I'm wondering where to stand with my little lever. > > Basically, I'm wondering how to go about creating and registering a view so > that it will show up in the view menu of the editor. View loading seems to > be handled through a lot of abstract calls to other objects from the Editor > frame, I'm wondering if there's somewhere I can just type in the > class/module name and have the class show up. I'm not sure I understand your intention here. This does not sound like a new view to me. To me this sounds like an action, say 'Arrange' that should be added to the current UMLView. See OGLViews.UMLView.__init__. Currently 'Toggle Attributes' and 'Toggle Methods' are such actions, just extend this list. If you do want to add a new view to a model, the best advice (advice I follow myself) is to copy/paste from a similar view and work from there. To have the new view show up in the Views menu, it has to be added to the models associated controller class. There are two view lists attributes in the controller, DefaultViews and AdditionalViews. Usually the new view class would be added to AdditionalViews. > > Suggestions appreciated, > Mike > > _______________________________________________ > Boa-constructor-users mailing list > Boa...@li... > https://lists.sourceforge.net/lists/listinfo/boa-constructor-users Thanks, hope this helps and more questions welcome! -- Riaan Booysen ___________________________________________________ Boa Constructor - RAD GUI building IDE for wxPython http://boa-constructor.sourceforge.net |