Re: Undo framework

On 9/21/07, Tristan Van Berkom <tvb gnome org> wrote:

> Should be noted here that from my particular experience, writing
> code that is undoable (i.e. filling in the execute()/undo() routines
> for a given undoable command) is far more challenging than writing
> a framework that supports it - but it would be great if a common
> framework could at least be shared.


> About GtkEntry... maybe it would be good to take a step back
> and think MVC, GtkEntry usually effects some internal data in the
> application - I'd much rather see built-in undoability implemented
> in say, a GtkTextBuffer that might be viewed by multiple GtkEntries
> or GtkTextViews... anyway just saying that usually you probably want
> undo to effect the program's internal dataset, not the widgets that
> are showing whatever happens to be current.

Well, Ross and I discussed it. I think his use case is for in dialogs
where the internal state of an object doesn't get changed until the
dialog is closed, but wants to be able to allow the text entries to be
undone in the meantime. The way it works in Cocoa is that entries are
undoable until they lose focus.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]