From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Po Lu via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#61307: 30.0.50; pixel-scroll-precision-mode: window-scroll-functions? Date: Sun, 19 Feb 2023 14:54:46 +0800 Message-ID: <875ybyjgax.fsf@yahoo.com> References: <87y1pbsgu5.fsf@web.de> <83h6vzq9at.fsf@gnu.org> <878rhascr8.fsf@web.de> <83wn4ngjvp.fsf@gnu.org> <875yc6cnmk.fsf@web.de> <83mt5ifdhn.fsf@gnu.org> <87o7pyb556.fsf@web.de> <83k00lg1ve.fsf@gnu.org> <873579jaot.fsf@web.de> <83edqse6qr.fsf@gnu.org> <87sff7374b.fsf@web.de> <83y1ozawtu.fsf@gnu.org> <877cwi1a35.fsf@web.de> <83edqq81f0.fsf@gnu.org> <87ttzifbkq.fsf@web.de> Reply-To: Po Lu Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="389"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Eli Zaretskii , 61307@debbugs.gnu.org To: Michael Heerdegen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Feb 19 07:58:21 2023 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 1pTdeN-000ASg-Lp for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 19 Feb 2023 07:58:19 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pTdeC-0003l7-1y; Sun, 19 Feb 2023 01:58:08 -0500 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 1pTde7-0003kq-0a for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 01:58:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pTde6-0001Ha-Ld for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 01:58:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pTde6-0001e7-FM for bug-gnu-emacs@gnu.org; Sun, 19 Feb 2023 01:58:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Po Lu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 19 Feb 2023 06:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61307 X-GNU-PR-Package: emacs Original-Received: via spool by 61307-submit@debbugs.gnu.org id=B61307.16767898336261 (code B ref 61307); Sun, 19 Feb 2023 06:58:02 +0000 Original-Received: (at 61307) by debbugs.gnu.org; 19 Feb 2023 06:57:13 +0000 Original-Received: from localhost ([127.0.0.1]:45523 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTddJ-0001cv-I1 for submit@debbugs.gnu.org; Sun, 19 Feb 2023 01:57:13 -0500 Original-Received: from sonic316-49.consmr.mail.ne1.yahoo.com ([66.163.187.175]:40737) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pTddI-0001ci-Jj for 61307@debbugs.gnu.org; Sun, 19 Feb 2023 01:57:12 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1676789825; bh=g2khWDJJE/HvUq79dwchnF90yG3ef8hNul2rQGAgcVc=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From:Subject:Reply-To; b=LpSnYkNCsNwCUFLp6AOSpu3i0WJ91yDy6AJKmFifV46MoVJuFEQtaOB7D/fofyz/B4xMLMMLD5QqEmi4G7Mt5nsTIcPIB6AfkWBmnlkHN8Px54PisBRHqwEe+WoLT7kbhm6Shzv7fYsoRAQGwqDDNGLhNO3aeAwejDOi0V8Z7VM4TW5nXDreO7LK5iG3Ow4NSGoaPhIPSDfLhH6F0o4vsgHGjRzkDyF6yM1O6dAKQzTYMsrP6SWsgVecDwED2HDMmQ3TfUOO5LwvO0rDMM8kSE5kqogELBU3XLqbc78cS9gNIMShZM/GK9IR5HwzcQu7f3Q5RLOk9dZfzCWbV0iJ6g== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1676789825; bh=dZyWIapMMQCypsL1yaiDs2d2SKSqThG3BIYs05YcZSX=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=CnrMI1h5yyIDSmwJd14J1CsWPQWfkSgfCqp+e0zGaYtBX16p00fIhcjqP1hbSmQcfbPLMqV47v8ELqeVL8mFFs2D01EMxtyeP47se4Do3q6zotYJ7uBCrrnCQqzyMafOBO85vD/Am5BLqlIea0pr9XiLbzH/sgZ+I60Ijhcz0lU3e1bXJNpKjGeRBzOMq+UFLIOqqW9AnUOGKeLj2j+JCLF9B6Y2MLTh7JZ3cEwo77cq7espqDeus27OpD1GRvNt/vewr/6SCWgXSFOFD2hG6jQUnhOMO29IWi2ylIXLppGCUjkq/oVo0eY1NbdVJqxd1+45Q0BIozqAzy83er+CbQ== X-YMail-OSG: xCf8INcVM1n2NnbyoTAUN7wM5fczqmquiLwwUjGIwQCFyd3mHAFFF1wt8m6tcFT rhCtaygXMKkahlaBnw793zQP2OQvaxWlTqmwjmXdvUrGfWopVAiZg8HGPPiNAjDqKg0QplRHN00s Vh6RIF8kq74xBXsYjDdvBhiYOmDWIyfgXQe4S81YH3muKbZEKHhSgH2bcz9k8mbzRZi9MKXBv_hq yuxkJFmXW84ZRqkcoTeynRqP31.c_lS_JJUbdgrmaT8DTI8Zgb5zxvtAZNZXm8vxOs5z9YZDiXj2 xoe7JRgVVn0thzfpje_X3Y.gHGYk7815u2FB1cMJHeWpw5TaOe.IYjcsbtAoAEvpCUhA8J5rYA9l kcorE3fwqvnTTssAR9d8QP_3ISkS10W.bBkj5kETqOv0K7KRLOdxOMi4VkB92TuDm_iW4S.HF6sM 43hMLs9sZ9EKobNHrTtLnVvpFgGb3B_eAN_qRR_8cQAxerxXcvB5je9WLrzWY7gB0DNsx0yRoHWt lnFbG6wC4HRIfOzE8qu0anP4.Gu74Nt0WVLa.Ok.mgZRRUns6pWbAp0WA7wisPiu.CMZoGhFkK52 G6hU2r42BcIvHE7WsvCQ6Nqcs_diQzM_7Kf87hkXEsdQXYJ9tuDpW1V0W.uY615fRuwheawerdmY 7VjoJTQuwQr.IotDQQ7VLgGcW_NGLGkIZ_6NbqxEudDhszqjDe6G5CZUrc5ZkEyJQGuBx4TmZKuU I0mZ.ac0BSG2AEVBhpWoXDGPFfy.bdQ_7RTY2dHKIhAYd8aOqjSszDMexxMUS1e.3VqPYW37mnvn Szg2TeVHK0PPCH8pEM5YdNamFWb17zNozpJhouN_2K X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic316.consmr.mail.ne1.yahoo.com with HTTP; Sun, 19 Feb 2023 06:57:05 +0000 Original-Received: by hermes--production-sg3-9fc5746c8-r2vxw (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID f07455c320b259e2e67014a627e080fa; Sun, 19 Feb 2023 06:55:02 +0000 (UTC) In-Reply-To: <87ttzifbkq.fsf@web.de> (Michael Heerdegen's message of "Sun, 19 Feb 2023 06:50:29 +0100") X-Mailer: WebService/1.1.21183 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:256031 Archived-At: Michael Heerdegen writes: > Eli Zaretskii writes: > >> I'm not sure, but Po Lu will know. >> >> In any case, AFAIR some mice produce mouse-4 and mouse-5 events >> instead, so relying on the events' symbols might not be the best >> idea. We are supposed to know whether the device supports pixel >> precision, so maybe basing the decision on that is better? > > So, would this already be good enough as a start? > > diff --git a/lisp/pixel-scroll.el b/lisp/pixel-scroll.el > index 487144144f5..1d2d3ff10fe 100644 > --- a/lisp/pixel-scroll.el > +++ b/lisp/pixel-scroll.el > @@ -714,7 +714,10 @@ pixel-scroll-precision > (let ((kin-state (pixel-scroll-kinetic-state))) > (aset kin-state 0 (make-ring 30)) > (aset kin-state 1 nil)) > - (pixel-scroll-precision-interpolate delta current-window)) > + (pixel-scroll-precision-interpolate delta current-window) > + (run-hook-with-args 'window-scroll-functions > + current-window > + (window-start current-window))) > (condition-case nil > (progn > (if (< delta 0) > > > AFAIU, in that branch of the code we know that we are presumably dealing > with a mouse or we scrolled by a larger amount. > > Michael. What if you are scrolling with a touch pad or core pointer that never triggers the ``large scroll'' options? Either way, please make sure it stays fast (or at least put it behind an option which is off by default.) If window-scroll-functions are not called, then it stays tolerable for many people. But users will become extremely annoyed if precision pixel scrolling becomes too slow.