From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Manuel Giraud via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#64440: 30.0.50; [PATCH] Highlight on non toolkit menu bar items Date: Sun, 29 Oct 2023 10:02:51 +0100 Message-ID: <87sf5tyf5w.fsf@ledu-giraud.fr> References: <87zg4d56l8.fsf@ledu-giraud.fr> <871qf22f5g.fsf@ledu-giraud.fr> <87wmvzkjaw.fsf@ledu-giraud.fr> <87wmvzc2qq.fsf@yahoo.com> <87sf6nn4km.fsf@ledu-giraud.fr> <87o7hbn3mo.fsf@ledu-giraud.fr> <87r0lo2s8a.fsf@ledu-giraud.fr> <874jik46cs.fsf@yahoo.com> <87mswc2q70.fsf@ledu-giraud.fr> <87zg0c2pua.fsf@yahoo.com> <87il702nfo.fsf@ledu-giraud.fr> <87v8b02mae.fsf@yahoo.com> <87a5sc2lh4.fsf@ledu-giraud.fr> <87mswc2lb1.fsf@yahoo.com> <875y302km0.fsf@ledu-giraud.fr> <87il702jnk.fsf@yahoo.com> <871qdo2i6j.fsf@ledu-giraud.fr> <87wmv8qyc4.fsf@ledu-giraud.fr> <87o7gkxytr.fsf@yahoo.com> <83ttqce4k6.fsf@gnu.org> <87y1fnwc4j.fsf@yahoo.com> Reply-To: Manuel Giraud Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3989"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Eli Zaretskii , stefankangas@gmail.com, 64440-done@debbugs.gnu.org To: Po Lu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Oct 29 10:03:59 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 1qx1iA-0000pE-MY for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 29 Oct 2023 10:03:58 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qx1hk-0000Fl-3C; Sun, 29 Oct 2023 05:03:32 -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 1qx1hi-0000FH-Tt for bug-gnu-emacs@gnu.org; Sun, 29 Oct 2023 05:03:31 -0400 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 1qx1hh-0006vw-TK for bug-gnu-emacs@gnu.org; Sun, 29 Oct 2023 05:03:30 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qx1iE-0000ru-Ar for bug-gnu-emacs@gnu.org; Sun, 29 Oct 2023 05:04:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Manuel Giraud Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 29 Oct 2023 09:04:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64440 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 64440-done@debbugs.gnu.org id=D64440.16985702123302 (code D ref 64440); Sun, 29 Oct 2023 09:04:02 +0000 Original-Received: (at 64440-done) by debbugs.gnu.org; 29 Oct 2023 09:03:32 +0000 Original-Received: from localhost ([127.0.0.1]:40360 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qx1hk-0000rB-3C for submit@debbugs.gnu.org; Sun, 29 Oct 2023 05:03:32 -0400 Original-Received: from ledu-giraud.fr ([51.159.28.247]:31222) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qx1hg-0000qy-1P for 64440-done@debbugs.gnu.org; Sun, 29 Oct 2023 05:03:30 -0400 DKIM-Signature: v=1; a=ed25519-sha256; c=simple/simple; s=ed25519; bh=2UJxzxGH 8qAQR1KnHhUtjGBCgLNthTrm3RAs/HBXPWE=; h=date:references:in-reply-to: subject:cc:to:from; d=ledu-giraud.fr; b=1eumSEr11E2mGAZ3g+ug5+AhSVW5JO J3ZtoFLn+cemI/3dLlpMX3dMPd1x29Bp0elyRazZzBnOr6pKriO4UMAw== DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; s=rsa; bh=2UJxzxGH8qAQR1Kn HhUtjGBCgLNthTrm3RAs/HBXPWE=; h=date:references:in-reply-to:subject: cc:to:from; d=ledu-giraud.fr; b=kjqOM+2KuOSfdxXGcbaY/hmDXLhhnK6LmUDVDr BWoZ10NAgBWLHkvwnoVQdQ/ZWOlGFzB+RkfCMwub6zJ4a4IKQqsGfm/CB9gexf8BpB2BE7 OZt1GdFNq55NG61aHVH7VvLh1z/ccw02h9OJmAAOs16jIgTkolbb/DkDk+Tq/DtfZHxsXV U243SYs+Z5s5nxfRfl6auf1CzD64DxTVhxiMdGQYK/rAU1+2W8h0CxU8Q3775HpawjNOem yXgl7KLTgDkjGlygkdrlxbrZqpG9sAIvFuIMLSpKEYSjL1tN1EpE2d9ygP6qkjxNXjB+EW yZDBcKbi+CxWVA49sHMP6Vbw== Original-Received: from computer ( [10.1.1.1]) by ledu-giraud.fr (OpenSMTPD) with ESMTPSA id eee6cd4f (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Sun, 29 Oct 2023 10:02:53 +0100 (CET) In-Reply-To: <87y1fnwc4j.fsf@yahoo.com> (Po Lu's message of "Sat, 28 Oct 2023 13:26:52 +0800") 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:273485 Archived-At: --=-=-= Content-Type: text/plain Po Lu writes: > Now done, and thanks. Thanks Po. But could you also commit this one. It is the one and only usage for all those changes. It is used to set cursor as an arrow. Thanks. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0002-Set-non-text-mouse-cursor-on-menu-bar.patch >>From 9200d69b49fa57269e5357383d138872a372127a Mon Sep 17 00:00:00 2001 From: Manuel Giraud Date: Fri, 6 Oct 2023 14:27:02 +0200 Subject: [PATCH 2/2] Set non-text mouse cursor on menu bar * src/xdisp.c (note_mouse_highlight): Set non-text mouse cursor on menu bar. --- src/xdisp.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/xdisp.c b/src/xdisp.c index 7f9e62f05e8..df3076cf499 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -35537,6 +35537,16 @@ note_mouse_highlight (struct frame *f, int x, int y) w = XWINDOW (window); frame_to_window_pixel_xy (w, &x, &y); +#if defined (HAVE_WINDOW_SYSTEM) && ! defined (HAVE_EXT_MENU_BAR) + /* Handle menu-bar window differently since it doesn't display a + buffer. */ + if (EQ (window, f->menu_bar_window)) + { + cursor = FRAME_OUTPUT_DATA (f)->nontext_cursor; + goto set_cursor; + } +#endif + #if defined (HAVE_WINDOW_SYSTEM) /* Handle tab-bar window differently since it doesn't display a buffer. */ -- 2.40.0 --=-=-= Content-Type: text/plain -- Manuel Giraud --=-=-=--