Re: [hackers] [vis] [PATCH] fix {, }, (, ) movements

From: Marc André Tanner <>
Date: Wed, 3 Feb 2016 00:07:05 +0100

On Tue, Feb 02, 2016 at 10:14:52PM +0100, Markus Teich wrote:
> - Split the functions, so the algorithms are more clear
> - Paragraph movements work backwards
> - Paragraph movements work consistently with \r\n line breaks always placing the
> cursor on the first character of the first empty line before/after the
> paragraph
> - Sentence movements now work better at BOF/EOF
> - save a few lines of code

Thanks for cleaning up this mess. This sort of thing would really
benefit from some sort of testsuite. In principle there exists
basic infrastructure to compare behaviour with vim in the "test"
branch. The the test/vim subdirectory would be a starting point
for anybody interested ...

Did you also consider implementing text_paragraph_{next,prev} by
skipping to actual content i.e. a loop while (c == '\n' || c == '\r')
followed by a call to text_line_empty_{next,prev}?

I think this should work, but maybe I'm missing something?

 Marc André Tanner >< >< GPG key: 10C93617
Received on Wed Feb 03 2016 - 00:07:05 CET

This archive was generated by hypermail 2.3.0 : Wed Feb 03 2016 - 00:12:43 CET