From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Newsgroups: gmane.emacs.help Subject: Re: [External] : Re: Matching parenthesis for long constructs Date: Sat, 11 May 2024 07:40:45 +0200 Message-ID: References: <87zfszm21m.fsf@dataswamp.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Fwdw8jjsPPw8LR+J" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4421"; mail-complaints-to="usenet@ciao.gmane.io" To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Sat May 11 07:41:24 2024 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1s5fU3-00010U-Vt for geh-help-gnu-emacs@m.gmane-mx.org; Sat, 11 May 2024 07:41:24 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s5fTa-00023w-Ur; Sat, 11 May 2024 01:40:55 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s5fTW-00023g-Bd for help-gnu-emacs@gnu.org; Sat, 11 May 2024 01:40:50 -0400 Original-Received: from mail.tuxteam.de ([5.199.139.25]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s5fTU-0002Kp-2P for help-gnu-emacs@gnu.org; Sat, 11 May 2024 01:40:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tuxteam.de; s=mail; h=From:In-Reply-To:Content-Type:MIME-Version:References:Message-ID: Subject:To:Date:Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=VVtjUfUdeVb+1M5lYvk0aySFS6yaev8Z2OqRSVdcFqY=; b=TDgnH6f00/WiYrR54dlMILQUR3 UPyFW96RaidX1ejQUwESrn+4/L5WeO44IOUqJ3KRCIRR2UxCEOIYhoXu79hXs9kTDPNNexwTUv4r/ riI1u/PQhMtyN2rWqG77I6ylaPH7KsdbUS/bVXVEUXNbhpjGcC2cjn9nr+0MD6k18dWQYv6fBSRaV 8JdjFN69OdFjOGtsyHeBmQuQXTv5Z201lXtJSAKp9U5CJUug05UQ3M8rxA4JwBUoWQWeZxDHDktXM QUnYYm0QrghQVISxX31jqmNiYwDhO+zUUemN0hhxBTCldOzvP9UVck/g6yXZ28dJiqakHbZoteu12 dwFtnSEw==; Original-Received: from tomas by mail.tuxteam.de with local (Exim 4.94.2) (envelope-from ) id 1s5fTR-0001a0-8F for help-gnu-emacs@gnu.org; Sat, 11 May 2024 07:40:45 +0200 Content-Disposition: inline In-Reply-To: <87zfszm21m.fsf@dataswamp.org> Received-SPF: pass client-ip=5.199.139.25; envelope-from=tomas@tuxteam.de; helo=mail.tuxteam.de X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:146672 Archived-At: --Fwdw8jjsPPw8LR+J Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, May 09, 2024 at 05:35:01PM +0200, Emanuel Berg wrote: [...] > I agree with him it is a pretty bad state, I think it should > be outputted in the echo area the same that happens when you > write a right (closing) parenthesis and the left one isn't in > the window. Folks, I know the OP doesn't take the bother to even look at the docs (that's why I've given up to engage with them too much). But from you, Emanuel, I'd expect better. This is straight from the Emacs docs, "28.4.3 Matching Parentheses", specifically about Show Paren (minor) mode: To customize the mode, type =E2=80=98M-x customize-group paren-showing=E2=80=99. The customiza= ble options which control the operation of this mode include: =E2=80=A2 =E2=80=98show-paren-highlight-openparen=E2=80=99 controls whet= her to highlight an open paren when point is just before it, and hence its position is marked by the cursor anyway. The default is non-=E2=80=98nil=E2=80=99= (yes). =E2=80=A2 =E2=80=98show-paren-style=E2=80=99 controls whether just the t= wo parens, or also the text between them get highlighted. The valid options here are =E2=80=98parenthesis=E2=80=99 (show the matching paren), =E2=80=98expr= ession=E2=80=99 (highlight the entire expression enclosed by the parens), and =E2=80=98mixed=E2= =80=99 (highlight the matching paren if it is visible in the window, the expression otherwise). =E2=80=A2 =E2=80=98show-paren-when-point-inside-paren=E2=80=99, when non= -=E2=80=98nil=E2=80=99, causes highlighting also when point is inside of the parentheses. The default is =E2=80=98nil=E2=80=99. =E2=80=A2 =E2=80=98show-paren-when-point-in-periphery=E2=80=99, when non= -=E2=80=98nil=E2=80=99, causes highlighting also when point is in whitespace at the beginning of a line and there is a paren at the first or last non-whitespace position on the line, or when point is at the end of a line and there is a paren at the last non-whitespace position on the line. =E2=80=A2 =E2=80=98show-paren-context-when-offscreen=E2=80=99, when non-= =E2=80=98nil=E2=80=99, shows some context in the echo area when point is in a closing delimiter and the opening delimiter is offscreen. The context is usually the line that contains the opening delimiter, except if the opening delimiter is on its own line, in which case the context includes the previous nonblank line. So there /is/ a provision for the "matching delimiter is offscreen" case. And it is documented, in a place where one might stumble upon it with a search term nearly identical to this thread's subject. Now we could go on to discuss whether this is Good Enough or whether it can be improved, and how. Cheers --=20 t --Fwdw8jjsPPw8LR+J Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQRp53liolZD6iXhAoIFyCz1etHaRgUCZj8E1QAKCRAFyCz1etHa RqT6AJ45C9jhL9g1Go70/IWfxgjljh3V2gCfQ7WIDxnQT0n3owzaqrJgZSg+eXw= =AXLl -----END PGP SIGNATURE----- --Fwdw8jjsPPw8LR+J--