From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Manuel Giraud Newsgroups: gmane.emacs.devel Subject: Re: Menu bar items structure Date: Fri, 18 Nov 2022 08:48:42 +0100 Message-ID: <87fsegk8it.fsf@elite.giraud> References: <87pmdmkdrh.fsf@elite.giraud> <83iljednq6.fsf@gnu.org> <87sfiiezv0.fsf@yahoo.com> <87cz9lkino.fsf@elite.giraud> <834juxesqa.fsf@gnu.org> <87k03tipsh.fsf@elite.giraud> <83tu2xcy7d.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22570"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: luangruo@yahoo.com, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Nov 18 08:49:31 2022 Return-path: Envelope-to: ged-emacs-devel@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 1ovw7t-0005bU-ES for ged-emacs-devel@m.gmane-mx.org; Fri, 18 Nov 2022 08:49:29 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ovw7L-0007ms-Te; Fri, 18 Nov 2022 02:48:55 -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 1ovw7G-0007ma-0a for emacs-devel@gnu.org; Fri, 18 Nov 2022 02:48:50 -0500 Original-Received: from ledu-giraud.fr ([51.159.28.247]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ovw7E-0000dG-6r; Fri, 18 Nov 2022 02:48:49 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; s=rsa; bh=ws+C1cMmzOEOBRz5 rnBA4SeKMWHn2iXxNsbL+xrbzFM=; h=date:references:in-reply-to:subject: cc:to:from; d=ledu-giraud.fr; b=PRTsKU0MzeEJ2j1kHfTFEEgl5MuUE1HoJlxb/p P07JQvHgAMSAfV0lIGea7SrpEW91VPZdXI5Htg8qBOpreReKQEXP1omhATinvCP98lwo+X tNqaD8/iIWyjBsZa8HSCyMCm77L0V502Dnvib1npshG7wBqYx5owNlMqSDVkv9GNbdXoS/ LHE9MGjrT/tjZaQZz8h5ZWBZUKB3baEu0KHLrN/MiSx0aK54lWIzUhI4ipV6hyjInjhoBN f7VUIOYYfGveoW1EUYdO9GXz3A+9nUj3j4SH8/I/e6v1F2wTwo4Lb8aTFeqcPiGVWxIb1y v7+HJMmJ3OBKNqdZ3uP8bcig== Original-Received: from elite.giraud ( [10.1.1.1]) by ledu-giraud.fr (OpenSMTPD) with ESMTPSA id eee53dcd (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Fri, 18 Nov 2022 08:48:43 +0100 (CET) In-Reply-To: <83tu2xcy7d.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 17 Nov 2022 19:01:10 +0200") Received-SPF: pass client-ip=51.159.28.247; envelope-from=manuel@ledu-giraud.fr; helo=ledu-giraud.fr X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:300093 Archived-At: Eli Zaretskii writes: [...] >> >> 2- add a fifth element to a menu item that records the end >> >> position of a menu entry (also in pixel and filled in >> >> display_menu_bar) >> > >> > The first alternative is better, IMO: on TTY frames each character is >> > 1 pixel, so the change doesn't affect TTY menus. >> >> I was not clear. My patch does the two points. > > Why do you need the second one? It seems more natural because in display_menu_bar I have all the information I needed handy (as we have just filled the menu bar). But anyway, I now going to ignore this second index and use x_y_to_hpos_vpos as Po Lu suggested. Thanks. -- Manuel Giraud