Subject: bug#51032: 29.0.50; Choices for blink-matching-paren

From: Arash Esbati <[email-masked]>
Date: Thu, 07 Oct 2021 11:02:23 +0200

Stefan Kangas <[email-masked]> writes:

> Eli Zaretskii <[email-masked]> writes:
>
>> I'm not talking about the doc string here, I'm talking about the
>> values in the value menu that the defcustom will show the user when
>> the user customizes this variable.

I think the values in the value menu are Ok, the only misleading part of
docstring was

    With any other non-nil value, the off-screen position of the opening
    paren will be shown in the echo area.

which is now (almost) fixed.

> It's short enough, so I pasted its current definition below:
>
> (defcustom blink-matching-paren t
>   "Non-nil means show matching open-paren when close-paren is inserted.
> In addition, if the opening paren is not visible on screen, show
> its position in the echo area.
>
> The valid values are:
>
>   nil               Disable.
>   non-nil           Highlight the opening paren.
>   `jump'            Briefly move cursor to its position.
>   `jump-offscreen'  Briefly move cursor to its position,
>                     even if the opening paren is not on screen."
>   :type '(choice
>           (const :tag "Disable" nil)
>           (const :tag "Highlight" t)
>           (const :tag "Move cursor" jump)
>           (const :tag "Move cursor, even if off screen" jump-offscreen))
>   :group 'paren-blinking)

Thanks Stefan.  May I suggest the following:

(defcustom blink-matching-paren t
  "Non-nil means show matching open-paren when close-paren is inserted.

Valid values are:

  nil               Disable.
  t                 Highlight the opening paren if on screen,
                    show the position in the echo area if off screen.
  `jump'            Briefly move cursor to the opening paren if on screen,
                    show the position in the echo area if off screen.
  `jump-offscreen'  Briefly move cursor to the opening paren,
                    even if the position is off screen."
  :type '(choice
          (const :tag "Disable" nil)
          (const :tag "Highlight" t)
          (const :tag "Move cursor" jump)
          (const :tag "Move cursor, even if off screen" jump-offscreen))
  :group 'paren-blinking)

Best, Arash