GNU bug report logs

#78527 30.1; Mishaving new frame creation in MacOS on new desktop

version graph
PackageSource(s)Maintainer(s)
emacs PTS Buildd Popcon
Full log

Message #35 received at 78527@debbugs.gnu.org (full text, mbox, reply):

Received: (at 78527) by debbugs.gnu.org; 4 Jun 2025 08:47:52 +0000
From debbugs-submit-bounces@debbugs.gnu.org Wed Jun 04 04:47:52 2025
Received: from localhost ([127.0.0.1]:46936 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces@debbugs.gnu.org>)
	id 1uMjmo-0007ia-OA
	for submit@debbugs.gnu.org; Wed, 04 Jun 2025 04:47:52 -0400
Received: from mout.gmx.net ([212.227.15.15]:54987)
 by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.84_2) (envelope-from <rudalics@gmx.at>) id 1uMjmk-0007gq-Ru
 for 78527@debbugs.gnu.org; Wed, 04 Jun 2025 04:47:48 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.at;
 s=s31663417; t=1749026855; x=1749631655; i=rudalics@gmx.at;
 bh=E/CD7ExQZTg1AggnWIOnMxHZFn+6+wVYcozpKBCshhQ=;
 h=X-UI-Sender-Class:Message-ID:Date:MIME-Version:Subject:To:Cc:
 References:From:In-Reply-To:Content-Type:
 Content-Transfer-Encoding:cc:content-transfer-encoding:
 content-type:date:from:message-id:mime-version:reply-to:subject:
 to;
 b=lb941/zay1XVrGd/B8daJGZ4U+XfOePEbhe204T+ER+y7LkXinl4odvJoHMbmLh1
 k3BoJdszNXC6GmRgtDC1x1NXe7eOk5QbXzsOqJdeU10r9y4T/GPcRYVm0r0nVFVgT
 glWp9y/NHmhEQ9rGKO3lHaLPR3KK4D7+z36YlUwgtCQKTNxpZ+PIvBQuyJP0HEbqS
 iSGnoy5out0gSrcG080MbTVkZu2Q7elVwXoMjwHmETx8F52I9m0fl7DucXka0V1Bo
 gRYQYhbiiZhSuuKYp4r7UT1JuFGLcAhlpD0b/hxfShnMkirKU3WmyTqP6lNKU5MRI
 r0Q9DP9fr3i9NgGYTw==
X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a
Received: from [192.168.31.113] ([46.125.249.97]) by mail.gmx.net (mrgmx004
 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MLzFr-1u5U2x3JGj-00IXdP; Wed, 04
 Jun 2025 10:47:34 +0200
Message-ID: <97dfdc42-d676-4cf0-a1cd-b248d441a6f7@gmx.at>
Date: Wed, 4 Jun 2025 10:47:33 +0200
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
Subject: Re: bug#78527: 30.1; Mishaving new frame creation in MacOS on new
 desktop
To: Boris Aronov <aronov.boris@gmail.com>
References: <CAGPpUSoPzgd4bSKoAagQniBZoS+fhMZp0ZskoW5nA24VNxmtYg@mail.gmail.com>
 <865xht6k1e.fsf@gnu.org> <db4f94fe-a395-4ece-a9bb-6d763d7d0235@gmx.at>
 <CAGPpUSr-uyVcoOBMyEjVLSCp8+=RnkCiWyjw5afSs4XnkT9N=A@mail.gmail.com>
Content-Language: en-US
From: martin rudalics <rudalics@gmx.at>
In-Reply-To: <CAGPpUSr-uyVcoOBMyEjVLSCp8+=RnkCiWyjw5afSs4XnkT9N=A@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Provags-ID: V03:K1:R71skV2YeX+c3jXstPqwgVdec1afN9JI9nDmKKEI5ibn7kBNwIk
 1WhuKUyo6KvzUrQ6aTFLs3cmV/f+8uBcGUhUXBZsb1mt8sbult2Nch522hDcvGxxeggMLIl
 HgF4Zxfb6XHhPxaw43hisT3AdbQHz0kaXgVoLCR4IA6OEcdVOjvvDzVfwzfFwtQZYfR125z
 taNIg2Zo09fuKkxmigKZA==
X-Spam-Flag: NO
UI-OutboundReport: notjunk:1;M01:P0:VxjyzK/Ji4w=;U1lvRwFFx31bCbvXUisnj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l4INcUuYSIlQlE
 7PMt3utJprjG5E+FBBInZBUUpqgdAMe1GCP2UEGlLKI9CYlZgXIi9qnClGDhWDJlcHRgPRSXF
 hoefLsvF5qyTZ3Nf3GA4UjDyejWjE0J6wvFjqSUNXf8MhUNqfbv0YE8xUFXQJ3jMNxmWuPx2C
 vzUfb28qo5Pk26Z9eXNPPRkuHdl6j1F/Tyw2fQ==
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 78527
Cc: Gerd Möllmann <gerd.moellmann@gmail.com>,
 Eli Zaretskii <eliz@gnu.org>, 78527@debbugs.gnu.org
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request@debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit@debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request@debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request@debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces@debbugs.gnu.org>
X-Spam-Score: -1.7 (-)
Thanks for answering.

I'm still a bit dense in the following sense: You have a fullscreen
frame, do C-x 5 2 and now see the new frame on a new desktop but it
apparently didn't get focus because, as you say, the prompt doesn't
appear there.  However, in your initial posting you say that "Focus
shifts there".  What makes you think that focus shifted there?  The
appearance of the cursor, the mode line, some decoration in the new
frame?  Does C-x 2 split a window in the new or old frame?

>> I'd like to understand the focus issue.  What does C-x 5 o do when run
>> in the old frame?
>
>
> - Opened "Emacs -Q"
> - Clicked the green button (fullscreen)
> - C-x 5 2 (new frame opens on another desktop)
> - I swipe to original desktop
> - C-x 5 o switches to the new one and repeating it takes me back

Does C-x 5 o also switch the desktop you see?

> What does running 'foo' defined as
>>
>> (defun foo ()
>>     (interactive)
>>     (let ((frame (make-frame)))
>>       (sit-for 3)
>>       (message "%s" (frame-focus-state frame))))
>>
>
> When I do this in an non-full-screen frame, a new frame pops up with a "t"
>
> When I do it in a full-screen frame, a new frame pops up but a "t' is in
> the OLD frame.  And then (I think) with some delay it also appears in the
> NEW frame.

This "delay" should come from the (sit-for 3) call.

>> report?  Is the message shown in both frames?
>>
>> Does 'foo' specified as
>>
>> (defun foo ()
>>     (interactive)
>>     (let ((frame (make-frame)))
>>       (select-frame-set-input-focus frame)))
>>
>> behave the same way?
>
>
> I get a "nil" in both frames.

The nil would come from the return value of the frame focusing function
so my question was silly.  What I really meant with "behave the same
way" was whether the new frame does get input focus with this 'foo',
that is, whether now Emacs shows the prompt in the new frame when you
try executing a command.  I suppose the answer is "no".

> Hard to tell if it's simulataneous (as I
> cannot look at them at the same time) and maybe switching desktops triggers
> something.
>
>    Does
>>
>> (add-hook 'after-make-frame-functions 'select-frame-set-input-focus)
>>
>> change anything?
>
>
> Not really.  When I make a new frame, a new frame on a new desktop appears,
> but typing M-x shows no change on screen.  When I switch back to the
> original screen M-x shows on screen AND when I switch again NOW I can see
> M-x prompt on the new screen as well.
>
>
>    Does
>>
>> (add-hook 'after-make-frame-functions 'redirect-frame-focus)
>>
>> change anything?
>>
>
> No.  Same behavior as after the other add-hook.

I see.

> Another oddity (or is it expected): when I switch back-and-forth between
> desktops having typed M-x, on one screen the focus (selected window?) is on
> the M-x line and on the other on *scratch* (where I originally ran the C-x
> 5 2 command).  Not sure which is which by now...
>
> Actually, after a few switches back and forth, the M-x line is the selected
> window in the frame where I typed it (new frame) and it's not selected in
> the old frame.
>
> Not sure if this helps in any way.

Not yet.  If you have two normal (non-fullscreen) frames of the same
Emacs process on two different desktops, type a command so that a prompt
appears in one of them and then do C-x 5 o: Does the prompt move to the
other frame?  Right away?

BTW: Do you have Mission Control installed and active?  Maybe some
setting in it triggers the "put the frame on the other desktop because
the first one is too crowded" behavior.

martin




Send a report that this bug log contains spam.


debbugs.gnu.org maintainers <help-debbugs@gnu.org>. Last modified: Wed Sep 10 21:29:49 2025; Machine Name: wallace-server

GNU bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.