summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorfvogel <fvogel@noemail.net>2016-03-27 15:25:22 (GMT)
committerfvogel <fvogel@noemail.net>2016-03-27 15:25:22 (GMT)
commit96d2614cec32334bd6b34d609d89a63856299a4d (patch)
tree0dd6bfd881f87860ca526ac23cda6653a861d285 /doc
parentfc3a3e65350a969741f017583f2b314bb3b4035e (diff)
parent50c0996605d2e955ca2cb9788f755285e079c0e6 (diff)
downloadtk-96d2614cec32334bd6b34d609d89a63856299a4d.zip
tk-96d2614cec32334bd6b34d609d89a63856299a4d.tar.gz
tk-96d2614cec32334bd6b34d609d89a63856299a4d.tar.bz2
Fixed [18c08df753] - Change of behaviour for text widget last newline
FossilOrigin-Name: 592d54932adc50a4bc767c386a3a5ecf8926ef98
Diffstat (limited to 'doc')
-rw-r--r--doc/text.n40
1 files changed, 24 insertions, 16 deletions
diff --git a/doc/text.n b/doc/text.n
index 5d6ac19..cf516f4 100644
--- a/doc/text.n
+++ b/doc/text.n
@@ -1173,22 +1173,30 @@ test suite.
.TP
\fIpathName \fBdelete \fIindex1 \fR?\fIindex2 ...\fR?
.
-Delete a range of characters from the text. If both \fIindex1\fR and
-\fIindex2\fR are specified, then delete all the characters starting with the
-one given by \fIindex1\fR and stopping just before \fIindex2\fR (i.e. the
-character at \fIindex2\fR is not deleted). If \fIindex2\fR does not specify a
-position later in the text than \fIindex1\fR then no characters are deleted.
-If \fIindex2\fR is not specified then the single character at \fIindex1\fR is
-deleted. It is not allowable to delete characters in a way that would leave
-the text without a newline as the last character. The command returns an empty
-string. If more indices are given, multiple ranges of text will be deleted.
-All indices are first checked for validity before any deletions are made. They
-are sorted and the text is removed from the last range to the first range so
-deleted text does not cause an undesired index shifting side-effects. If
-multiple ranges with the same start index are given, then the longest range is
-used. If overlapping ranges are given, then they will be merged into spans
-that do not cause deletion of text outside the given ranges due to text
-shifted during deletion.
+Delete a range of characters from the text.
+If both \fIindex1\fR and \fIindex2\fR are specified, then delete
+all the characters starting with the one given by \fIindex1\fR
+and stopping just before \fIindex2\fR (i.e. the character at
+\fIindex2\fR is not deleted).
+If \fIindex2\fR does not specify a position later in the text
+than \fIindex1\fR then no characters are deleted.
+If \fIindex2\fR is not specified then the single character at
+\fIindex1\fR is deleted.
+Attempts to delete characters in a way that would leave
+the text without a newline as the last character will be tweaked by the
+text widget to avoid this. In particular, deletion of complete lines of
+text up to the end of the text will also delete the newline character just
+before the deleted block so that it is replaced by the new final newline
+of the text widget.
+The command returns an empty string.
+If more indices are given, multiple ranges of text will be deleted.
+All indices are first checked for validity before any deletions are made.
+They are sorted and the text is removed from the last range to the
+first range so deleted text does not cause an undesired index shifting
+side-effects. If multiple ranges with the same start index are given,
+then the longest range is used. If overlapping ranges are given, then
+they will be merged into spans that do not cause deletion of text
+outside the given ranges due to text shifted during deletion.
.TP
\fIpathName \fBdlineinfo \fIindex\fR
.