Posted 10 years ago by Garik
Version: 4.0.0281
Avatar
How can I implement such feature.
In document I change only text, how can I save Undo/Redo actions. I need to save the undo/redo actions?

Comments (6)

Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Igor,

Maybe you could provide more detail on what you mean and how you want to use the information. Thanks.


Actipro Software Support

Posted 10 years ago by Garik
Avatar
Ok.

I want such functionality.
On the top I have a grid with a list of classes.
On the bottom I have SyntaxEditor control. When selected row in grid is changed, I change syntaxEditor.Document.Text with source text of classe selected in grid, and then i call Reparse method.

And if this document has UndoRedo actions they are lost. I want to save this UndoRedo actions. Maybe I need to save all the Document....

[Modified at 03/24/2009 03:23 PM]
Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Oh, yes setting Text will wipe out undo. You would want to do a ReplaceText but replace the entire document length. That will keep undo history.


Actipro Software Support

Posted 10 years ago by Garik
Avatar
Ok. But this UndoRedo actions are for another class.
Posted 10 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
In that case, maybe store a separate Document for each "class" and swap in the appropriate one instead of setting Document.Text. That way each Document will retain its own undo history.


Actipro Software Support

Posted 10 years ago by Garik
Avatar
Ok. Thanks a lot.
The latest build of this product (v2018.1 build 0341) was released 9 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.