Friday, September 6, 2019

Re: What happened to "Search hit BOTTOM, continuing at TOP"?

> Speaking of this " W' indicator, why was it chosen to _add_ it to the
> '[N/M]' string instead of _prepending_ "W " before one?
>
> The point is, if _appended_, then at the moment of wrapping, the expected
> position of '[N/M]' changes slightly to the left, which isn't exactly nice
> (like, why the information is jumping in front of our eyes, etc). While if
> _prepended_, the counter itself stays exactly where it was, and only this
> sign "W" appears on the left. Don't know if I'm right or wrong here but I
> personally certainly like the prepended option better.
>
> If you agree, then here's a patch for src/search.c, which seems to fix it
> (I'm not a programmer, I also don't know ANYTHING about C at all, and these
> few lines here may be completely wrong and stupid, so, please, feel
> absolutely free to change it if needed):
>
> ====
> 5014c5014,5017
> < STRCPY(t + len, " W");
> ---
> > char t_tmp[len + 2];
> > STRCPY(t_tmp, t);
> > STRCPY(t + 0, "W ");
> > STRCPY(t + 2, t_tmp);
> ====

I like it. No need to send a patch.

--
hundred-and-one symptoms of being an internet addict:
199. You read this entire list of symptoms, looking for something
that doesn't describe you.

/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/201909061840.x86IeeuF023010%40masaka.moolenaar.net.

No comments:

Post a Comment