From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Heime Newsgroups: gmane.emacs.help Subject: Re: Regexp capturing unicode characters Date: Thu, 01 Aug 2024 11:26:40 +0000 Message-ID: <2wHi4S9MruOl3ZOkpjKnin3CJxnVnomMkaIdhl-i3OF7AYEda3X-7-1ijhWUrLZ22JwOMXQu5ntZ3FFBuAlmhkpMxgXFbhZ-sS_XMmCrE4g=@protonmail.com> References: <865xskygar.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25665"; mail-complaints-to="usenet@ciao.gmane.io" Cc: help-gnu-emacs@gnu.org To: Eli Zaretskii Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Thu Aug 01 13:27:37 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 1sZTy4-0006U1-RK for geh-help-gnu-emacs@m.gmane-mx.org; Thu, 01 Aug 2024 13:27:36 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sZTxM-0002SK-27; Thu, 01 Aug 2024 07:26:52 -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 1sZTxK-0002S8-1M for help-gnu-emacs@gnu.org; Thu, 01 Aug 2024 07:26:50 -0400 Original-Received: from mail-40137.protonmail.ch ([185.70.40.137]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sZTxH-0001iM-4t for help-gnu-emacs@gnu.org; Thu, 01 Aug 2024 07:26:49 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1722511603; x=1722770803; bh=UHzlUcXewmO9C5T5NQ+oxmQgAH0z7OYnQEnm5c2D13w=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=L3GxjU2TXiWAY8C1PMObRHur0Ryrx2Uk2OFM7bYCX7iVTGneI97WjIFwfL/RRqGIG FWnlnKlYpRUcSeqG1VZ2gFS+dTNBYxIbqfIHBiRD+/B7hLHSvaUOtC4QtGSjvYvqHh VCfiQ9iUprvDfbHid++5q3nJqdnG6cFR92xTfc/SmfeyVVVQhcO8sbg00o+BZwweR/ gn8TIkmn6Wb2KcuQHMqhedd4FSbJIW2GsR6Khe/O1S0JrnhsXTG57vLFW7Z8VMQjBK /BTknOIEqdcAICLL5NtUF3N2Wk+xPfhpB+7mj0q4RNBW3jMtdsMKYTrqb1gQVXFPLW 4GicGDpJA+Gwg== In-Reply-To: <865xskygar.fsf@gnu.org> Feedback-ID: 57735886:user:proton X-Pm-Message-ID: 9928850f591dfdff208bbdb2282f1a88b0a80226 Received-SPF: pass client-ip=185.70.40.137; envelope-from=heimeborgia@protonmail.com; helo=mail-40137.protonmail.ch X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=unavailable 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:147480 Archived-At: On Thursday, August 1st, 2024 at 5:15 PM, Eli Zaretskii wrot= e: > > Date: Wed, 31 Jul 2024 21:24:46 +0000 > > From: Heime heimeborgia@protonmail.com > >=20 > > I am using unicode characters in my elisp code (e.g. foreign language s= ymbols in icelandic > > and spanish). > >=20 > > Is the regexp [[:word:]] appropriate to capture them ? >=20 >=20 > No. [[:word:]] matches characters that have the word syntax, so which > characters match depends on the major mode. My suggestion is to use > either [[:alnum:]] or [[:alpha:]] instead, depending on whether you > want or don't want to match digit characters. >=20 > The meaning of each character class is documented in the "Char > Classes" node of the ELisp Reference manual, I suggest to read it and > choose the most appropriate one for your needs. It is difficult to determine from a character class, the actual character. Is there a way to show the characters that are members of each class ? Thought that [:multibyte:] captured the unicode characters. Bet even when I applied (set-buffer-multibyte t) to the buffer, I did not get matches. Does [:word:] mean word in the english language only ?