On Thu, 24 May 2001, Mario Lang wrote: > What I am thinking about is a Interactive Ruby IDE. > But the interface indepence bothers me a bit. I cant find out > how to structure a program from the grounds up well, so > that different interfaces can be written for it later on without > modification of the core. Let me define both parts, Model and View. The Model is the "core" of a system. What is common to all models is that they all include Observable (from observer.rb) and they implement what is required to make it work: every property that can be seen from outside, when changed, must be announced (after the change) so that observers can know when something has to be done. The View is a layer you put between the Model and the User. It knows a Model (via a property called #model) and it observes that Model, which means the Model knows the View, but only in the way that an Observable knows its observers. When the View decides to update what it presents to the User, it queries the Model about its properties and presents that information. Now I didn't say what is between the View and the User. We could call it a Display and that Display needs not to be visual; it could be X11, NCurses, a command-line interface, a voice-based system, anything. For a given kind of Display you need a set of Views that make a bridge between the Display and a fair amount of Models. > Perhaps some project like this is already on the way (the ruby IDE) I don't remember who planned to do one besides me but I haven't heard of a serious initiative. > If this apllies, I would be happy to join forces. And I would hope to > convince the author of the importance of interface independence. You won't need to convince me. > I have also found the textbuf extension, which I really liked. My hope is that MetaRuby makes it easier to experiment in efficient representations of strings. I'd like that loading a one meg text file in a String results in a thousand actual Strings all linked together through StringMixin. This is doable now but I'm not so hot in efficient data structures so someone else would have to pick up MetaRuby and program such a String class. > Example, currently someone is writing the table.el extension for Emacs, > which allows editing of tabular data. He uses many tricks to If you want a "buffer" really based on a concept other than a String, then probably that making it as general as a Model (see above) is a good idea. I'm very interested in stuff like the Outline mode of Emacs. > BTW: Does Rumacs sound good to you? :) The name I have found for it is "Hybris". matju