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#67204: 29.1; request: always echo EMOJI name while emoji-list Date: Fri, 29 Dec 2023 09:44:05 +0200 Message-ID: <8334vl78sa.fsf@gnu.org> References: <83a5py9iy6.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="37023"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 67204@debbugs.gnu.org, awrhygty@outlook.com To: Daniel =?UTF-8?Q?Mart=C3=ADn?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Dec 29 08:45:28 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 1rJ7Ye-0009Q1-8d for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 29 Dec 2023 08:45:28 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJ7YH-0000eM-O3; Fri, 29 Dec 2023 02:45:05 -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 1rJ7YF-0000e5-G5 for bug-gnu-emacs@gnu.org; Fri, 29 Dec 2023 02:45:03 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJ7YF-0003O6-6W for bug-gnu-emacs@gnu.org; Fri, 29 Dec 2023 02:45:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rJ7YE-00019i-Jf for bug-gnu-emacs@gnu.org; Fri, 29 Dec 2023 02:45:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 29 Dec 2023 07:45:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 67204 X-GNU-PR-Package: emacs Original-Received: via spool by 67204-submit@debbugs.gnu.org id=B67204.17038358744390 (code B ref 67204); Fri, 29 Dec 2023 07:45:02 +0000 Original-Received: (at 67204) by debbugs.gnu.org; 29 Dec 2023 07:44:34 +0000 Original-Received: from localhost ([127.0.0.1]:40717 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rJ7Xl-00018k-MP for submit@debbugs.gnu.org; Fri, 29 Dec 2023 02:44:34 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44254) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rJ7Xi-00018T-82 for 67204@debbugs.gnu.org; Fri, 29 Dec 2023 02:44:31 -0500 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJ7Xc-0003IH-Ou; Fri, 29 Dec 2023 02:44:24 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=q7LwZHtnsZT2SGwEHbVGA2fiFiCoabQ75ldhiBwNgjs=; b=QIgojvGGzFZnxKKXw/H3 IY8+Pa2+b5acspSyR/K1O0sTXH9iOGbKmnWqnNAIK4kQ+kFzSnNbqjTEkxjKnkuJO+Bib1cQRMmDC HQrgWizLUCegUQ5lUraLbNPbiWUbsBhKnRHGvNLUQ0y93qOGrmyMLsC0x8N/rkbWFXl+mOl/VfW8R CCuPlDOQYSnEb2GY0RZkhwdo2/re+0kcLNGWNYhW31gxoWylZcwTX+S4+OBPUyC3oqfRfmmIiBKsH n3hM14DhDqsA5c84QfRu0SEngaYarFlmhZzxE06g5Ov6tzY08S/eDb3FwR45bNE5F+9N57EuVfHJf yP6RkFd/Px4lBw==; In-Reply-To: (message from Daniel =?UTF-8?Q?Mart=C3=ADn?= on Mon, 25 Dec 2023 21:52:42 +0100) 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:277003 Archived-At: > From: Daniel Martín > Cc: awrhygty@outlook.com, 67204@debbugs.gnu.org > Date: Mon, 25 Dec 2023 21:52:42 +0100 > > Eli Zaretskii writes: > > >> > >> This is because Emacs automatically moves the point when it’s in the > >> middle of text with the ’composition’ property. See (elisp) Adjusting > >> Point in the Elisp Info manual for more information about this feature. > >> > >> It seems that post-command-hook is invoked _before_ the point is moved, > >> so querying the position of point inside post-command-hook does not > >> always give correct results. You could add your code to the > >> pre-redisplay-function instead. > > > > Would temporarily disabling point adjustment help here? > > Not really. I think point adjustment is really needed in the emoji-list > buffer; otherwise, sometimes you’d need to press C-f multiple times to > go from one emoji to the next one, when compositions are involved. > > Here’s a complete recipe to understand the issue better: > > emacs -Q > > Eval the following code: > > (add-hook #'post-command-hook > (lambda () > (message "Column: %d" (current-column))) > nil) > > M-x column-number-mode > M-x emoji-list > C-s people > activity > C-n > C-n > C-f > > The mode-line shows point is at line 115 and column 9, but the echo area > shows "Column: 8". > > However, if you click on the emoji at column 9, then the echo area > correctly shows "Column: 9". Yes, I know how point adjustment works. What I meant is to set global-disable-point-adjustment non-nil in the *Emoji* buffer. However, now that I tried the original recipe in https://debbugs.gnu.org/cgi/bugreport.cgi?bug=67204#5, I don't think I see the OP's problem. With that post-command hook, I see the emoji name shown in the echo-area for all the emoji I tried. I probably didn't try with those which caused problems to the OP, so I'm asking: what are those "composed character EMOJI" which DON'T show their name with that post-command hook? I'd like to reproduce the problem before I see if we have a ready solution for it. Btw, each emoji in that buffer has also a help-echo string with the name, so moving the mouse there is another way of showing the name. Also, an alternative for post-command-hook is a point-entered text property.