diff options
author | fvogel <fvogel@noemail.net> | 2016-05-30 18:07:48 (GMT) |
---|---|---|
committer | fvogel <fvogel@noemail.net> | 2016-05-30 18:07:48 (GMT) |
commit | dd90ecb08f1ae0b17da9293287707fe00828bf6b (patch) | |
tree | 13255d2cd63dc0c7da5e6be2d5e7e39a47dd391d /doc | |
parent | 425a61845fa7f0bf581991d86a894848b6a73ffd (diff) | |
parent | f10ab25f60b168abcf9a44a75e513da27d7a00f1 (diff) | |
download | tk-dd90ecb08f1ae0b17da9293287707fe00828bf6b.zip tk-dd90ecb08f1ae0b17da9293287707fe00828bf6b.tar.gz tk-dd90ecb08f1ae0b17da9293287707fe00828bf6b.tar.bz2 |
Merged TIP #446 accepted by TCT vote. This fixes [1273358] - Ask a text widget for the depth of its undo and redo stacks.
FossilOrigin-Name: 18b5c257cd874af3165097b11a16ff90b84e4025
Diffstat (limited to 'doc')
-rw-r--r-- | doc/event.n | 4 | ||||
-rw-r--r-- | doc/text.n | 13 |
2 files changed, 17 insertions, 0 deletions
diff --git a/doc/event.n b/doc/event.n index 045339e..54ad42e 100644 --- a/doc/event.n +++ b/doc/event.n @@ -352,6 +352,10 @@ user-driven .QW "tab to widget" action. .TP +\fB<<UndoStack>>\fR +This is sent to a text widget when its undo stack or redo stack becomes +empty or unempty. +.TP \fB<<WidgetViewSync>>\fR This is sent to a text widget when its internal data become obsolete, and again when these internal data are back in sync with the widget @@ -897,6 +897,9 @@ separator is already present at the top of the undo stack no other will be inserted. That means that two separators on the undo stack are always separated by at least one insert or delete action. .PP +The \fB<<UndoStack>>\fR virtual event is generated every time the undo stack +or the redo stack becomes empty or unempty. +.PP The undo mechanism is also linked to the modified flag. This means that undoing or redoing changes can take a modified text widget back to the unmodified state or vice versa. The modified flag will be set automatically to @@ -1282,6 +1285,16 @@ behavior of the command depends on the \fIoption\fR argument that follows the supported: .RS .TP +\fIpathName \fBedit canredo\fR +. +Returns a boolean true if redo is possible, i.e. when the redo stack is not +empty. Otherwise returns false. +.TP +\fIpathName \fBedit canundo\fR +. +Returns a boolean true if undo is possible, i.e. when the undo stack is not +empty. Otherwise returns false. +.TP \fIpathName \fBedit modified \fR?\fIboolean\fR? . If \fIboolean\fR is not specified, returns the modified flag of the widget. |