PDA

View Full Version : Syncing QTextDocument's undo stack with custom undo stack



Dini Selimović
24th June 2012, 14:11
Hello!

Anyone has any idea how to synchronize QTextDocument's internal undo stack with custom undo stack?

If there was undoCommandedRemoved signal I would know when to remove undo command. But it seems that only undoCommandedAdded signal is available. So when I type, let's say 5 paragraphs in a text document, I get 5 undoCommandedAdded signal emits. When I undo changes, I get redoAvailable(true) for the first paragraph, and no other undo/redo signals for other paragraphs.

Thanks!