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#61337: 29.0.60; Setting frame-title-format makes Emacs to steal focus Date: Tue, 07 Feb 2023 22:15:29 +0800 Message-ID: <87ilgd7e9q.fsf@yahoo.com> References: <874jrydpw8.fsf@telefonica.net> 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="36820"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 61337@debbugs.gnu.org To: "Oscar Fuentes" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Feb 07 15:19: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 1pPOob-0009My-2L for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 07 Feb 2023 15:19:21 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pPOnw-0002mK-O4; Tue, 07 Feb 2023 09:18:40 -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 1pPOnK-0002dy-I4 for bug-gnu-emacs@gnu.org; Tue, 07 Feb 2023 09:18:21 -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 1pPOnK-0004K6-A9 for bug-gnu-emacs@gnu.org; Tue, 07 Feb 2023 09:18:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pPOnK-00032k-4y for bug-gnu-emacs@gnu.org; Tue, 07 Feb 2023 09:18: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: Tue, 07 Feb 2023 14:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61337 X-GNU-PR-Package: emacs Original-Received: via spool by 61337-submit@debbugs.gnu.org id=B61337.167577946811665 (code B ref 61337); Tue, 07 Feb 2023 14:18:02 +0000 Original-Received: (at 61337) by debbugs.gnu.org; 7 Feb 2023 14:17:48 +0000 Original-Received: from localhost ([127.0.0.1]:51587 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pPOn5-000325-RR for submit@debbugs.gnu.org; Tue, 07 Feb 2023 09:17:48 -0500 Original-Received: from sonic307-36.consmr.mail.ne1.yahoo.com ([66.163.190.59]:44515) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pPOn2-00031n-QK for 61337@debbugs.gnu.org; Tue, 07 Feb 2023 09:17:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1675779458; bh=5CQekHrvD3Z+L/+duK72CqFQESF/C72xoVXntDCHYzc=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From:Subject:Reply-To; b=pZVFM1Tq7dumHrWKeMr7aB0Bmq6N6c+cdwklai9tLHYwPJGr4wgGxDZElHVZivxElcNcL391exxQlHiHkQfHMEzQizuyYNf6gNCZFaIG3W8p/CU4bX8+QUku0tP/8d+U0yTMzOGPMn9xx0Uv+M87KrHzNsb9Wf4BGTgwkiSG85gwJaVLW8BBJ0EqGrbH3TGUWfPctzpMNkQxtx2H/VnHY/tSV7pDwHY5jssEnIfBx/2OO0piTmBdPAHp3CQuMGmoeCEvefVuV097qlS65bBwBgiYXvNa+ejooieHfG1NALCXCu73/M/sjUDy6za/wCJItPKMYfdSmbPUMoE17W69mg== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1675779458; bh=OgGRRLGHAw0/8+HrslvnV8Fh3QZhhM33wS1O/xZnGNU=; h=X-Sonic-MF:From:To:Subject:Date:From:Subject; b=OyKgSeC4a2MzopqEDvlNKUw6WBz28+Ff7TZh8QcfmZ/4ujrpAEoohPs2+gk4ZZk1/D/2Ut+rx/RdVR3A4GAJTETjYiVioPOaNTkAY+Lvek6c+atWoos84KuOJLq7nY0yMqVF2ePwyrz+i9fJ1UTWcKoc89fnrebaXSuLX53Cr0KZs1vZvmkv2GIqy1gxKqD2dDU4n1tnvsKb1cm4MbM5Y8nDzbakVqKcm7KQkl0tZkrBndiF0h0J92b+2bpiE0oTQpBj8WSkzzrJqaYxW4ocaKiCPgIwdqmlEhO+IWU0cYWygMpL1q67JS3C3r5nPsz8IJOymmBciAOLJLv8DSemng== X-YMail-OSG: 4GzWOQIVM1nvJ5GjAFNfGn4oINDqnfUgJ36D.TsjUJQEdESos9V_SnP.jJm2QY4 iEc9CAP4yb4Xfb_XvMEO22SvYQ7rb8wp2sSM.KKeyTCaQeFTKL7UV_AtZ1Knc0fJrnLcCQfvPWDt .TqbvklJARKCGM9xe1sOQwZHywhbotIwO8L5FHktd_EpfXcFJ2xzYNN4DptCi6Pongd7geVsRfMR 3vtkHFJGyFPnrQZBLghxza63CJ_KErI18toRFOukkDDsiNK9MKcl2mTGPAEJKNskG87pWH00m0QW 0qwLgERw1Fnx9LLHUGbPBUHLZ5bGvQNLKduLbPKIu7UidASAgZbsAbSgdVrm92t0WytaPoqxzjJk XGdMNEw4.K50O_.nUaPWeOWx0qWtdP6pHTMziS6SKQsABXiRjSm7Bw84DW15G1UdcPsUtOn7LF2r 927cn9ULjS3oY0_pAks84_n8PFG9vQT4SN1wlDnibHZSkIKYkRXFEg3QuAWRrv9IO0QehI5RQVOX uIRBz4RjVMIoLgR4yWbB.duBIUe19Kn.gJdEKXsABQZNDPLkKzaA7m1GvQHYXgPiKfvq.WINu_67 0lKg36zgAmN8wne728yDio1pqJdREW_Ok29MjJ3mrex4M.aIAm_iKmYkYmw.SgsnG0bMcqu9GUzl _6IQwS8r.0EnFvITT8c6D0mpuaQr3.Q1Hh4CET1jZLyvt2QmXVyJy0h_Hb3GrpDAYV3_3AIUozu6 77_k14uur4jOs_60fr_sKndUIiChA5f8HA19j.ZXbIugxqURUnn.ifCKqWHhasy5xJzk376uGP4j 8dzjmEgy1IzIWC2P8TRmSdQJTb.Uzl_AyLu5WWUiP3 X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic307.consmr.mail.ne1.yahoo.com with HTTP; Tue, 7 Feb 2023 14:17:38 +0000 Original-Received: by hermes--production-sg3-9fc5746c8-28mz5 (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 0e1e4628ce0256e826b3aec4931d31be; Tue, 07 Feb 2023 14:15:35 +0000 (UTC) In-Reply-To: <874jrydpw8.fsf@telefonica.net> (Oscar Fuentes's message of "Tue, 07 Feb 2023 06:07:51 +0100") X-Mailer: WebService/1.1.21161 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:255048 Archived-At: "Oscar Fuentes" writes: > This is on KDE with two desktops. > > Let's suppose that we are on Desktop1. On xterm, for instance: > > $ emacs -Q > > Eval this on *scratch*: > > (setq frame-title-format "hello") > > Click somewhere on Emacs' frame to update its displayed title. > > Set focus to xterm, switch to Desktop2 and back to Desktop1. Focus is on > Emacs' frame. The z-order is not altered. > > After bisecting: > > commit e99f41f03a97641ee05ba4a27f8b91c190f55df1 > Author: Po Lu > Date: Thu Jun 9 21:48:19 2022 +0800 > > Fix recalculation of `icon-title-format' after a frame is iconified > > Previously it would only happen upon the next mode line > redisplay, meaning that just pressing C-z would not update the > implicit title, since C-z doesn't cause a redisplay. > > * src/dispextern.h: Update prototypes. > * src/frame.h (SET_FRAME_ICONIFIED): De-slugify. Call > `gui_consider_frame_title', since `icon-title-format' might be > different from the current frame title. > * src/xdisp.c (gui_consider_frame_title): Export (also in > dispextern.h). (bug#55850) > > I checked that reverting this commit fixes the problem. > > > In GNU Emacs 29.0.60 (build 3, x86_64-pc-linux-gnu, X toolkit, cairo > version 1.16.0) of 2023-02-07 built on sky > Repository revision: 746748f5c283b98a221571e725833affe304a748 > Repository branch: emacs-29 > Windowing system distributor 'The X.Org Foundation', version 11.0.12101006 > System Description: Debian GNU/Linux bookworm/sid > > Configured using: > 'configure --without-toolkit-scroll-bars --with-x-toolkit=lucid > --with-modules --without-imagemagick' > > Configured features: > CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG JSON > LIBOTF LIBSELINUX LIBXML2 MODULES NOTIFY INOTIFY PDUMPER PNG RSVG > SECCOMP SOUND THREADS TIFF TREE_SITTER WEBP X11 XAW3D XDBE XIM XINPUT2 > XPM LUCID ZLIB > > Important settings: > value of $LANG: es_ES.UTF-8 > locale-coding-system: utf-8-unix Thanks. Does this solve the problem? diff --git a/src/xfns.c b/src/xfns.c index 3a129211463..b64ebd0aefd 100644 --- a/src/xfns.c +++ b/src/xfns.c @@ -2329,7 +2329,7 @@ x_set_title (struct frame *f, Lisp_Object name, Lisp_Object old_name) else CHECK_STRING (name); - x_set_name_internal (f, name); + x_set_name (f, arg, false); } void