From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#57876: [PATCH] pulse-momentary-highlight-one-line: Act on visual line Date: Sun, 18 Sep 2022 15:55:48 +0300 Message-ID: <838rmgzvsb.fsf@gnu.org> References: <87illme7fe.fsf@gmail.com> <8735cp3pzg.fsf@gnus.org> <83bkrczwhn.fsf@gnu.org> <87o7vc26mq.fsf@gnus.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9448"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 57876@debbugs.gnu.org, public@protesilaos.com, arstoffel@gmail.com To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Sep 18 14:56:12 2022 Return-path: Envelope-to: geb-bug-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 1oZtqF-0002Jx-Up for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 18 Sep 2022 14:56:11 +0200 Original-Received: from localhost ([::1]:40084 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oZtqD-0008Gs-1Z for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 18 Sep 2022 08:56:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:43114) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oZtq6-0008GN-DL for bug-gnu-emacs@gnu.org; Sun, 18 Sep 2022 08:56:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:49247) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oZtq6-00048Q-4s for bug-gnu-emacs@gnu.org; Sun, 18 Sep 2022 08:56:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oZtq5-0000gE-Vt for bug-gnu-emacs@gnu.org; Sun, 18 Sep 2022 08:56:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 18 Sep 2022 12:56:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57876 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 57876-submit@debbugs.gnu.org id=B57876.16635057532597 (code B ref 57876); Sun, 18 Sep 2022 12:56:01 +0000 Original-Received: (at 57876) by debbugs.gnu.org; 18 Sep 2022 12:55:53 +0000 Original-Received: from localhost ([127.0.0.1]:48325 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oZtpw-0000fp-UZ for submit@debbugs.gnu.org; Sun, 18 Sep 2022 08:55:53 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:46608) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oZtpv-0000fb-T4 for 57876@debbugs.gnu.org; Sun, 18 Sep 2022 08:55:52 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:42814) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oZtpq-00043q-Di; Sun, 18 Sep 2022 08:55:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=9pN1BUEr3qZds/CwSOaz0wW49DOtIep/0tUMCSOIDjM=; b=XviHPdHNgGdm Da9wwJlUpng2eRjp0DRITUBTNeBHvX5jSJey5Tr79iRBfg0z3+a2NgS4h7MV/KMYb1+Z1qjwe8uVH MHh/Q1BONB03jytqsnI+aqxHKBdW3KZ41tQAml9tyPf80LXK/S8nqMuWOhd3sdiXCf9DPlo/KtMBu rtBk1TtzG6tCRCVfyVeghcFLzVuqYU/iIZMqcRPR0wNy7OkvrAbmpScOoMe14nQoX9r23ic8spb17 wlHtUF0UQRVdyP/xBcywIjsHR+8ycu7h0nmHcZjgVGVgnBPgvvCUF8DfatEUFwIsyvCJUjmXyIQ9D 6ZvdSCbxP6SByqBFQLFLQA==; Original-Received: from [87.69.77.57] (port=2193 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oZtpp-0002Mj-Sg; Sun, 18 Sep 2022 08:55:46 -0400 In-Reply-To: <87o7vc26mq.fsf@gnus.org> (message from Lars Ingebrigtsen on Sun, 18 Sep 2022 14:45:33 +0200) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:242989 Archived-At: > From: Lars Ingebrigtsen > Cc: arstoffel@gmail.com, public@protesilaos.com, 57876@debbugs.gnu.org > Date: Sun, 18 Sep 2022 14:45:33 +0200 > > Oh, sorry! I was confusing myself by testing with > > (let ((inhibit-point-motion-hooks t)) (beginning-of-visual-line)) > > which is the wrong thing, of course -- with inhibit-field-text-motion it > works fine. > > So adjusting the patch to use that instead might be appropriate (but > doesn't make much difference). My point in suggesting that was that it is better to use utility functions we have rather than the equivalent code, because the utility functions presumably serve as a locus of all our wisdom related to what they do. For example, what does "beginning of visual line" mean with bidirectional text? Instead of having to decide this in each case, we have a function that already does TRT.