From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#22541: 25.0.50; highlight-regexp from isearch has is case-sensitive even if case-fold is active Date: Sat, 30 Apr 2016 23:07:40 +0300 Organization: LINKOV.NET Message-ID: <87bn4s8d7b.fsf@mail.linkov.net> References: <87si1a2tod.fsf@secretsauce.net> <8760x7vyui.fsf@mail.linkov.net> <87zisfhcf4.fsf@secretsauce.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1462047101 353 80.91.229.3 (30 Apr 2016 20:11:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 30 Apr 2016 20:11:41 +0000 (UTC) Cc: 22541@debbugs.gnu.org To: Dima Kogan Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Apr 30 22:11:31 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1awbEg-00040q-My for geb-bug-gnu-emacs@m.gmane.org; Sat, 30 Apr 2016 22:11:30 +0200 Original-Received: from localhost ([::1]:59507 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1awbEc-0007x3-Jp for geb-bug-gnu-emacs@m.gmane.org; Sat, 30 Apr 2016 16:11:26 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34374) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1awbET-0007iw-Hu for bug-gnu-emacs@gnu.org; Sat, 30 Apr 2016 16:11:23 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1awbEH-0004Ms-Pb for bug-gnu-emacs@gnu.org; Sat, 30 Apr 2016 16:11:12 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:46187) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1awbEH-0004LW-M3 for bug-gnu-emacs@gnu.org; Sat, 30 Apr 2016 16:11:05 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1awbEE-0003oi-Ab for bug-gnu-emacs@gnu.org; Sat, 30 Apr 2016 16:11:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 30 Apr 2016 20:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22541 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 22541-submit@debbugs.gnu.org id=B22541.146204704314633 (code B ref 22541); Sat, 30 Apr 2016 20:11:02 +0000 Original-Received: (at 22541) by debbugs.gnu.org; 30 Apr 2016 20:10:43 +0000 Original-Received: from localhost ([127.0.0.1]:58521 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1awbDv-0003nx-2L for submit@debbugs.gnu.org; Sat, 30 Apr 2016 16:10:43 -0400 Original-Received: from sub3.mail.dreamhost.com ([69.163.253.7]:37888 helo=homiemail-a22.g.dreamhost.com) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1awbDu-0003no-5f for 22541@debbugs.gnu.org; Sat, 30 Apr 2016 16:10:42 -0400 Original-Received: from homiemail-a22.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a22.g.dreamhost.com (Postfix) with ESMTP id 8F168114066; Sat, 30 Apr 2016 13:10:40 -0700 (PDT) Original-Received: from localhost.linkov.net (m83-191-208-165.cust.tele2.ee [83.191.208.165]) (Authenticated sender: jurta@jurta.org) by homiemail-a22.g.dreamhost.com (Postfix) with ESMTPA id 7E744114065; Sat, 30 Apr 2016 13:10:39 -0700 (PDT) In-Reply-To: <87zisfhcf4.fsf@secretsauce.net> (Dima Kogan's message of "Tue, 26 Apr 2016 22:02:23 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.92 (x86_64-pc-linux-gnu) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:117443 Archived-At: >>>> > Another possible side effect of this is that highlighting >>>> > >>>> > Database directory: >>>> > >>>> > doesn't work: hi-lock goes through the motions but nothing ends up= being >>>> > highlighted. Turning off char-folding fixes that. >>>> >>>> Actually =E2=80=9CDatabase directory:=E2=80=9D is not highlighted du= e to case-folding. >>>> After toggling case-folding with =E2=80=98M-s c=E2=80=99 and preserv= ing the capital D, >>>> it's highlighted correctly. >>>> >>>> ...... >> >> The problem is that with introduction of char-folding, a hack responsi= ble >> for case-folding in isearch-highlight-regexp that turns isearch-string >> into a case-insensitive regexp is not used anymore, i.e. it's overridd= en by >> isearch-regexp-function. (Also note a FIXME comment in hi-lock-proces= s-phrase) >> >> Since we can't change the value of font-lock-keywords-case-fold-search >> for font-lock based highlighting in hi-lock for individual regexps, >> the best solution is to rely on the feature allowing MATCHER in >> font-lock-keywords to be a function. So we can let-bind case-fold-sea= rch >> in its lambda. >> >> Now the remaining problem is how to transfer case-fold from >> isearch-highlight-regexp down to hi-lock-set-pattern. > > Hi. Sorry it took me so long to reply to this. I haven't looked at > isearch specifically in enough detail to comment on this, but if it > makes this better, then I'm all for it :) Fortunately, I'll have more time in May to help in fixing this. >> Implementing pcre-style embedded modifiers is a good long-term goal, >> but we need to fix this for the next release. What options do we have= now? >> I see no other way than adding new argument to the chain of calls: >> ... > > I've been looking long-term, and emacs-devel now has a thread about an > initial implementation of one of the embedded modifiers. Since char-fol= d > isn't the default anymore, maybe this issue isn't pressing and isn't > critical to fix by emacs-25? Better to release emacs-25 with less bugs :)