Stores an array of some edit information in given variable array, if array is not given then an unnamed variable will be used.
This command returns the array name array, or an empty string (unnamed variable) if array is not specified.
This is the available information related to this widget:
Current byte size, only characters have been counted (a character may have more than one byte).
Current number of lines.
Number of visible embedded images.
Number of visible embedded windows.
This is the available information related to whole content:
Current byte size, only characters have been counted (a character may have more than one byte).
The depth (number of undoable actions) of the undo stack.
The depth (number of redoable actions) of the redo stack.
Current number of items on undo stack.
Current number of items on redo stack.
Current number of bytes on the undo stack, only characters have been counted (a character may have more than one byte).
Current number of bytes on the redo stack, only characters have been counted (a character may have more than one byte).
If the current undo stack action does not contain an undo atom, then this information is empty. Otherwise it contains the list of commands that have been pushed for undoing onto the stack since last inserted separator. A command is one of: delete, image, insert, mark, tag, or window. Note that mark can only occur when option -steadymarks is enabled. Also note that the replace command is pushing either delete and insert. Further note that this list contains all edit operations of the current undo atom, this means that some commands can occur repeatedly.
If the current undo stack action does not contain an redo atom, then this information is empty. Otherwise it contains the list of commands that have been undone with current undo command, see undocommands for more details.
Current number of lines.
Number of embedded images.
Number of embedded windows.
Number of currently defined tags.
Number of tags currently used.
Number of currently defined marks, this does not include the special marks insert and current, nor the generated marks (see mark generate).
Number of generated marks currently defined (see mark generate).
This information is unrelated to the content:
Minimal number of lines per node in B-Tree, this information is only useful for testing.
In the future the information might be extended. Note that embedded windows and images will each be count with byte size one.
Note: recently the Tk team has added the commands edit undodepth and edit redodepth. But these commands are not yet belonging to the distributed Tk standard, and the edit info command is more flexible, so I did not integrate the additions edit undodepth and edit redodepth. The recently added commands edit canundo, and edit canredo are marked as deprecated in revised version, because edit info also provides this information. And in this way, with the edit info command, the flooding with new commands will be prevented. The edit info command is flexible and extensible.
The virtual event <<UndoStack>> has been adopted into the revised version, but this event now will be triggered with any change on the undo stack, because [set [.t edit info](undocommands)] and [set [.t edit info](redocommands)] will provide the changed content.