aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/testsuite.at
diff options
context:
space:
mode:
authorRobin Haberkorn <robin.haberkorn@googlemail.com>2025-03-08 04:54:10 +0300
committerRobin Haberkorn <robin.haberkorn@googlemail.com>2025-03-08 05:11:56 +0300
commit7bcd3d8fee485d2fdd6af2d0362d2a59b374c724 (patch)
tree5bfecbc426a1adb976d2c13779709becffe7d016 /tests/testsuite.at
parent4fc266d9ed6cbdc02021caa6f3b5edfb6025b0bf (diff)
downloadsciteco-7bcd3d8fee485d2fdd6af2d0362d2a59b374c724.tar.gz
fixed the `Y` command: no longer delete any characters after dot
* This has __always__ been broken. It's been especially annoying when pressing `Y` at the end of a line with trailing whitespace since the linebreak would also be deleted. This was because `Y` always deleted the entire word or non-word character-span. This was inconsistent with `V`. * We now use SCI_WORDSTART|ENDPOSITION instead of the keyboard commands. It therefore also requires less Scintilla messages (4+2*n vs. 4+4*n). Most importantly, we can now check for errors before changing the buffer, so there is no need to undo anything in case of errors. This should always be the preferred strategy. * Added test case.
Diffstat (limited to 'tests/testsuite.at')
-rw-r--r--tests/testsuite.at5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/testsuite.at b/tests/testsuite.at
index 3f0b7e5..4d66392 100644
--- a/tests/testsuite.at
+++ b/tests/testsuite.at
@@ -113,6 +113,11 @@ AT_SETUP([Convert between line and glyph positions])
AT_CHECK([$SCITECO -e "@I/1^J2^J3/J 2^QC :^Q-3\"N(0/0)'"], 0, ignore, ignore)
AT_CLEANUP
+AT_SETUP([Deleting words])
+AT_CHECK([$SCITECO -e "@I/deleting words is useful/3J 2V .-3\"N(0/0)' Z-13\"N(0/0)'"], 0, ignore, ignore)
+AT_CHECK([$SCITECO -e "@I/deleting words is useful/3R 2Y .-14\"N(0/0)' Z-17\"N(0/0)'"], 0, ignore, ignore)
+AT_CLEANUP
+
AT_SETUP([Searches])
# FIXME: We cannot currently easily insert a single ASCII 5 (^E), as it must be followed
# by a 2nd character. It can be quoted, but cannot be written as Caret+E.