Custom Event Handler
Ned Konz
ned at bike-nomad.com
Wed Aug 8 14:41:12 UTC 2001
On Wednesday 08 August 2001 07:07 am, Josh wrote:
> > In
> > effect, it raises the question of whether a tool "should be applied" to
> > an object or whether an object "should provide a service" if stimulated
> > with a certain tool. In my understanding, the latter is almost always the
> > better way to go although I do understand that changing existing (e.g.,
> > predefined) classes is not always a good thing to do.
>
> Could you point me at some literature on the topic? The only thing I've
> read wrt tools in object-oriented GUI frameworks was a paper on InterViews.
You should look at HotDraw as well
http://st-www.cs.uiuc.edu/users/brant/HotDraw/HotDraw.html
In HotDraw, changing tools switches the state machine used to respond to user
interaction.
There is an interesting paper about creating tools by composition at
ftp://st.cs.uiuc.edu/pub/papers/HotDraw/HotDrawTools.ps.Z
HotDraw has several kinds of tools that apply to different things:
* CreationTool makes new objects
* DrawingActionTool does something to the whole drawing
* FigureActionTool does something to the next selected (clicked) object.
Each of the kinds of tools also supplies an icon and a cursor (as I recall).
--
Ned Konz
currently: Stanwood, WA
email: ned at bike-nomad.com
homepage: http://bike-nomad.com
More information about the Squeak-dev
mailing list
|