all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Udyant Wig <udyant@rudiments.goosenet.in>
To: help-gnu-emacs@gnu.org
Subject: Possible misleading example in `Incremental Search' Info node
Date: Thu, 04 Aug 2016 17:55:35 +0530	[thread overview]
Message-ID: <87k2fwbu0w.fsf@rudiments.goosenet.in> (raw)

I was reading the _Incremental_Search_ Info node in the Emacs manual.
In "15.1.4 Special Input for Incremental Search", found via

    (info "(emacs)Special Isearch")

the second paragraph discusses "lax space matching", and its second and
third sentences read as follows in my version of Emacs:

    Hence, ‘foo bar’ matches ‘foo bar’, ‘foo bar’, ‘foo bar’, and so on
    (but not ‘foobar’).  More precisely, Emacs matches each sequence of
    space characters in the search string to a regular expression
    specified by the variable ‘search-whitespace-regexp’.

I have not modified the default value for `search-whitespace-regexp',
which, for me, is

    search-whitespace-regexp
    => "\\s-+"

From my understanding of that full paragraph, the following illustrates
the default behaviour.  Suppose that we have the text

foobar
foo bar
foo  bar
foo   bar

If point is at the first `f' of `foobar', and I start an incremental
search via C-s for `foo bar', then all three of `foo bar', `foo  bar',
and `foo   bar' are highlighted, the latter two using the
`lazy-highlight' face.

Were the three instances of `foo bar' in the Info node paragraph meant
to have an increasing number of spaces?  Does anyone else see this?

My Emacs version is:

(emacs-version)
=> "GNU Emacs 24.4.1 (x86_64-pc-linux-gnu, GTK+ Version 3.14.5)
    of 2015-03-08 on trouble, modified by Debian"

-- 
Udyant Wig


             reply	other threads:[~2016-08-04 12:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-04 12:25 Udyant Wig [this message]
2016-08-04 13:56 ` Possible misleading example in `Incremental Search' Info node Emanuel Berg
2016-08-04 14:21 ` Drew Adams
2016-08-04 15:01   ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k2fwbu0w.fsf@rudiments.goosenet.in \
    --to=udyant@rudiments.goosenet.in \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.