On 11/15/05, Armel Asselin <[EMAIL PROTECTED]> wrote: > > Hello, > > as promised, here is a patch to scintilla which makes it send new > notifications SC_START_ACTION each time that a new undo/redo transaction > (which is the result of user action) begins.
Why is SC_START_ACTION a new notficiation rather than a bit flag on existing notifications such as the SC_MOD_DELETETEXT | SC_PERFORMED_USER notification in DeleteChars? Why do you get the notification when calling BeginUndoAction? I would expect that to be harder to deal with as you would have to count it with the notification for the actual change. Passing around a reference to implicitBegin is ugly and makes a reader wonder if there are more side effects: returning a value when possible avoids needing to wonder about side effects and aliasing. Can't you predict that an action will cause a begin by testing whether the depth==0 and the current action is a startAction? Recovering the information after performing a change is more complex and can't be extracted into a separate "WillChangeStartUndoStep" method. Neil _______________________________________________ Scintilla-interest mailing list [email protected] http://mailman.lyra.org/mailman/listinfo/scintilla-interest
