<div class="gmail_quote">On Wed, May 9, 2012 at 10:12 AM, Boudewijn Rempt <span dir="ltr"><<a href="mailto:boud@valdyas.org" target="_blank">boud@valdyas.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div class="im">On Tuesday 08 May 2012 May, Sven Langkamp wrote:<br>
<br>
><br>
> The commands at I was talking about are not QUndoCommands. It's also not on<br>
> the same level as the strokes framework.<br>
><br>
> QUndoCommand is too low-level. Action might map undo commands that are<br>
> missing information that is needed for recording e.g. the selection tools<br>
> use a normal transaction. Beside that I don't want to add xml loading and<br>
> saving code to every undo command.<br>
><br>
> Runners are on a much higher level than the strokes framework. For example<br>
> a possible runner could be the current KisLayerManager.<br>
><br>
> For example if you want to scale a layer:<br>
> 1) Dialog saves the values into a KisPropertiesConfiguration of a command,<br>
> id is set to e.g. "scaleLayer"<br>
> 2) Command is then send to the "command switch", that looks at the and<br>
> looks up the runner for id "scaleLayer"<br>
> 3) Command is then send to the KisLayerManager, which reads command id<br>
> "scaleLayer" from which is knows the function to call and the values to read<br>
> 4) KisLayerManager reads the values and calls KisLayerManager::scaleLayer<br>
><br>
> Recording happens in step 2, when the command goes through the "command<br>
> switch". Recording can't happen in step 4 as we have just transactions at<br>
> that point and no information about the original dialog values anymore.<br>
><br>
<br>
</div>But at 4 we should have access the to relevant values that make up this command, shouldn't we?<br></blockquote><div><br>Right, but at that point we are about to lose that. My point is that the values are not stored in the undo command.<br>
 </div><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
I'm wondering if what we're trying to reinvent isn't similar to gimp's PDB -- or maybe I'm mistaken about the purpose of that concept.<br></blockquote></div><br>I had not thought about it, but it looks pretty much identical to it.<br>