unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Al Haji-Ali <abdo.haji.ali@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 40814@debbugs.gnu.org
Subject: bug#40814: 26.3; show-paren-mode hightlights parentheses at eol
Date: Fri, 24 Apr 2020 11:55:24 +0100	[thread overview]
Message-ID: <CAAhfW2yq3CRG6eG-wad+K1Q-OUy-b1r+qXNPAhN3ooy7bJHgkw@mail.gmail.com> (raw)
In-Reply-To: <838silb25p.fsf@gnu.org>

I see. I think the documentation is unclear as to which parenthesis is
meant. After all, `(paren)` in the following text

    Some text (paren) some other text.

would not be highlighted if the point is in beginning (or end) of the
line even though this location meets the definition of the "line's
periphery" as defined in the documentation.
Based on this case, I would expect the consistent behaviour (to my
mind) that the text

   some other text (paren)

would highlight `(paren)` only if the point is at the end of the line,
not the beginning. This would also be consistent with the following
case

   (paren1) some other text (paren2)

where, correctly, (paren1) is highlighted if the point is in the
beginning of the line and (paren2) is highlighted if the point is in
the end of the line.

On Fri, Apr 24, 2020 at 11:37 AM Eli Zaretskii <eliz@gnu.org> wrote:
>
> > From: Abdo Haji-Ali <abdo.haji.ali@gmail.com>
> > Date: Fri, 24 Apr 2020 11:16:52 +0100
> >
> > In the following text:
> >
> > ```
> >    Some text (other text)
> > ```
> >
> > If `show-paren-mode` is on, `show-paren-when-point-in-periphery` is true and the point is anywhere before 'S', the parenthesis at the *end* of the line is highlighted. Is this intentional?
>
> Looks like it is.  From the option's doc string:
>
>   If non-nil, show parens when point is in the line’s periphery.
>   The periphery is at the beginning or end of a line or in any
>   whitespace there.
>
> What you describe seems to fit the "any whitespace there" part.
>
> maybe this text is confusing in some way?  What did you expect to see
> as the effect of this option?
>
> Thanks.





  reply	other threads:[~2020-04-24 10:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-24 10:16 bug#40814: 26.3; show-paren-mode hightlights parentheses at eol Abdo Haji-Ali
2020-04-24 10:37 ` Eli Zaretskii
2020-04-24 10:55   ` Al Haji-Ali [this message]
2021-06-13 12:29     ` Lars Ingebrigtsen

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=CAAhfW2yq3CRG6eG-wad+K1Q-OUy-b1r+qXNPAhN3ooy7bJHgkw@mail.gmail.com \
    --to=abdo.haji.ali@gmail.com \
    --cc=40814@debbugs.gnu.org \
    --cc=eliz@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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).