From debbugs-submit-bounces@debbugs.gnu.org Mon Jul 15 13:38:39 2019 Received: (at submit) by debbugs.gnu.org; 15 Jul 2019 17:38:40 +0000 Received: from localhost ([127.0.0.1]:48957 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hn4vv-0005zZ-KD for submit@debbugs.gnu.org; Mon, 15 Jul 2019 13:38:39 -0400 Received: from lists.gnu.org ([209.51.188.17]:37774) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hn4vs-0005zQ-RN for submit@debbugs.gnu.org; Mon, 15 Jul 2019 13:38:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48036) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hn4vr-000898-UH for bug-gnu-emacs@gnu.org; Mon, 15 Jul 2019 13:38:36 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hn4vr-0007JU-1Y for bug-gnu-emacs@gnu.org; Mon, 15 Jul 2019 13:38:35 -0400 Received: from mail-wr1-x42c.google.com ([2a00:1450:4864:20::42c]:39292) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hn4vq-0007Ip-Ma for bug-gnu-emacs@gnu.org; Mon, 15 Jul 2019 13:38:34 -0400 Received: by mail-wr1-x42c.google.com with SMTP id x4so18000721wrt.6 for ; Mon, 15 Jul 2019 10:38:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:mime-version:subject:message-id:date:to; bh=nyBHCgF6RcYharcPdSofHzoYsRKewMzRSvETf8HLCEE=; b=rVwtRSKuZ12pDPn+RIWWBf2IrYV835EQ8wgGWv736VprgyS5YA4lEFuy38WPYfbDwS lj27nIwM9UuwnIbVVv9BgxvQjYiSkO7lkLZyP/t+k7c5FOeP/kE5zst9zk9/zD0hZ4My kZo3ESXMd5hXehmS2LNE2sjwx3KJGBJ1bCL30AsRBvghqv0bmdWjJdzvY7itLkSErn/L fAYTenf62PeRmRw9b020Wb7ufkrGg3IEs0VwdSBjIMPsKrNc9t8ro0rhrB3u6fa//Fo1 /oTZvDVczSXj+nYNj4ULbTiiADYU/+rSTQ9AuAcz3DDUBx/YPpoj6cyP2NU5+ofNd8y/ HbqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:message-id:date:to; bh=nyBHCgF6RcYharcPdSofHzoYsRKewMzRSvETf8HLCEE=; b=GRVesfxa8pVPZVD56uCTugYs8ZMbAfEiob+FFrwWhIQcLYT6oqkLGkoVAE/q6dFa1m JenDY4NuTuQuEvYYzwfSOstMGBxT2kDkC4yT59RfclpetAtoHdOpPGNT4G4u+rFsOCGR 69pTWecXG8ETND7pExIt/oV8ocpCB8mz9g8dnTt4fVWZIQFbN+ejBQ2HCWA0ycE2wUDv 3ueb4YzCXRxuH6ZhD1PqIw23sRSj+n/ImLFrj3NWrpC6bf3RrL6/ijZ/fLw4MMBYkwpJ BCt01ILlFpcexTiaYYaXAKFVsGjeTReWnS2NaCVkf/kfJmOb7Qy1ArIXuv1ggaQYjvKh h7zQ== X-Gm-Message-State: APjAAAXx4SfEJU1Y4HPhJWX+RW8kxUzot5wdaA1v9cwBf+S38qUF9VFb FRSpfHGj3YZeQMbGf++VXrbU+WK+ X-Google-Smtp-Source: APXvYqz3ITU0wnPj6SeWRoPYpJ86UHP7+5t96CtT0HivA9QeltFbC4cFTXoQ+/eJ65951zwQIw5kqQ== X-Received: by 2002:a5d:5450:: with SMTP id w16mr31405543wrv.128.1563212312933; Mon, 15 Jul 2019 10:38:32 -0700 (PDT) Received: from [192.168.0.100] ([91.206.110.138]) by smtp.gmail.com with ESMTPSA id c78sm24643303wmd.16.2019.07.15.10.38.31 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 15 Jul 2019 10:38:32 -0700 (PDT) From: Andrii Kolomoiets Content-Type: multipart/mixed; boundary="Apple-Mail=_E8A25678-66B8-45D4-8F36-60FE26B9D2E9" Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Subject: 27.0.50; NS build: Creating child frame leads to empty space Message-Id: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> Date: Mon, 15 Jul 2019 20:38:31 +0300 To: bug-gnu-emacs@gnu.org X-Mailer: Apple Mail (2.3445.104.11) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::42c X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) --Apple-Mail=_E8A25678-66B8-45D4-8F36-60FE26B9D2E9 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii Assume there are only one space - Desktop 1. emacs -Q 2. M-x toggle-frame-fullscreen Now there are two spaces - Desktop and *scratch* 3. eval (make-frame `((parent-frame . ,(window-frame)))) Now there are three spaces: - Desktop - Empty space named *scratch* with emacs menu - *scratch* with emacs frames but without menu Although attached patch solves this problem for me these cases still not handled right way: 1. Removing parent-frame property leaves the frame is same space: (let ((new-frame (make-frame `((parent-frame . ,(window-frame)))))) (modify-frame-parameters new-frame `((parent-frame . nil)))) Maybe child frame must go fullscreen if ex-parent frame is in fullscreen. 2. Setting parent frame after frame creation: (let ((frame (window-frame)) (new-frame (make-frame))) (modify-frame-parameters new-frame `((parent-frame . ,frame)))) Thanks! In GNU Emacs 27.0.50 (build 1, x86_64-apple-darwin18.6.0, NS appkit-1671.50 Version 10.14.5 (Build 18F132)) Windowing system distributor 'Apple', version 10.3.1671 System Description: Mac OS X 10.14.5 --Apple-Mail=_E8A25678-66B8-45D4-8F36-60FE26B9D2E9 Content-Disposition: attachment; filename=ns-emacs-spaces.patch Content-Type: application/octet-stream; x-unix-mode=0644; name="ns-emacs-spaces.patch" Content-Transfer-Encoding: 7bit diff --git a/src/nsterm.h b/src/nsterm.h index 9773eb3e66..d16588718e 100644 --- a/src/nsterm.h +++ b/src/nsterm.h @@ -1274,6 +1274,7 @@ extern char gnustep_base_version[]; /* version tracking */ #if !defined (NS_IMPL_COCOA) || !defined (MAC_OS_X_VERSION_10_7) #define NSFullScreenWindowMask (1 << 14) #define NSWindowCollectionBehaviorFullScreenPrimary (1 << 7) +#define NSWindowCollectionBehaviorFullScreenAuxiliary (1 << 8) #define NSApplicationPresentationFullScreen (1 << 10) #define NSApplicationPresentationAutoHideToolbar (1 << 11) #define NSAppKitVersionNumber10_7 1138 diff --git a/src/nsterm.m b/src/nsterm.m index 02331826d9..cc5921090c 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -7365,7 +7375,10 @@ - (instancetype) initFrameFromEmacs: (struct frame *)f #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 if (NSAppKitVersionNumber >= NSAppKitVersionNumber10_7) #endif - [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; + if (FRAME_PARENT_FRAME (f)) + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary]; + else + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; #endif wr = [win frame]; --Apple-Mail=_E8A25678-66B8-45D4-8F36-60FE26B9D2E9-- From debbugs-submit-bounces@debbugs.gnu.org Tue Jul 16 15:28:34 2019 Received: (at 36672) by debbugs.gnu.org; 16 Jul 2019 19:28:34 +0000 Received: from localhost ([127.0.0.1]:51181 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hnT7q-0004ow-C2 for submit@debbugs.gnu.org; Tue, 16 Jul 2019 15:28:34 -0400 Received: from mail-wm1-f42.google.com ([209.85.128.42]:33533) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hnT7o-0004of-Ji for 36672@debbugs.gnu.org; Tue, 16 Jul 2019 15:28:33 -0400 Received: by mail-wm1-f42.google.com with SMTP id h19so17460971wme.0 for <36672@debbugs.gnu.org>; Tue, 16 Jul 2019 12:28:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=+3ZmNLUSisfMy53xBmewpNy+Bv3X/H9YzmEur09AtXo=; b=LCEIxaJtC5HzYu92RGXzvOrwg1VrYVckc8tQx11k1qMqOZBYd9glHhMuAGO5cPZ8+6 cT/B4oYr909xNGu9jfIm2plu54cw8qJfKQftC9Xp6UYERGs1vYubHasu+3uBzWYKLwGV 497aCK9RX+Q2tjZsIGaExhGKyxl8N+7VmPya9pnle3kQPWa7nsDtL71V3fWLO6yvHzQ+ AMBUvAk94Ilvrsrcyh5rqHAQLtylbHHazAJ43kCDHGQppxyYz77tqncCWJJWegQRzs36 +zoq2+qDoUEk8pO8XbIAyjylx3Zcw0rXHJnVTL+rexDfg9PAWyuPSal99Cnr8Vo8bFk9 S2Tw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=+3ZmNLUSisfMy53xBmewpNy+Bv3X/H9YzmEur09AtXo=; b=jfhD/o2ciYRuqFx9OGu//21pnMQk3uPgiFx2xtqeCZuaRR9D7yFpNUa1asnHpbRcnr KygFjWmcp9/9+d/GDj7esc66Uzp/d8l+0tcmRgA2yoj+i+g7/qr55RdZh5s+OFQ8tvXM gxv8WLC0xaANLI8NMDgvxvIaU3rF4lauWv9JjrnDAQIlMW9iOg2Rj1VD53Os96Q5CxZS eiDNPcuu0Ye6JvVzrXombLLlM7lJK71GUON0buE9DF3f00Dms7HNae+b+Y5AQHbLipXn W4ScONkRD1tGhtPmGGmV1T8q6c8iusWsmVkbHjz6w4AqXKRzguteI/U/Fza4Nbf0eRXs h4+g== X-Gm-Message-State: APjAAAXsb/jYyIf8jiyJ9AoOGUPbjBstFCSj1+RvuiGU0A7v+SR6POHy RQAjbMQYoMQcYMdSXJIriCc= X-Google-Smtp-Source: APXvYqzhGRklI57cabGhPJ1CE4uxCTMERLWmplrEpSbtYkR/4DoBmqMCFLK9slBkAM6MP4z5hpwvXw== X-Received: by 2002:a1c:f515:: with SMTP id t21mr33427824wmh.39.1563305305409; Tue, 16 Jul 2019 12:28:25 -0700 (PDT) Received: from breton.holly.idiocy.org (ip6-2001-08b0-03f8-8129-b0d8-8cf9-dc55-40ba.holly.idiocy.org. [2001:8b0:3f8:8129:b0d8:8cf9:dc55:40ba]) by smtp.gmail.com with ESMTPSA id l8sm36428006wrg.40.2019.07.16.12.28.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 16 Jul 2019 12:28:24 -0700 (PDT) Date: Tue, 16 Jul 2019 20:28:22 +0100 From: Alan Third To: Andrii Kolomoiets Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Message-ID: <20190716192822.GA63701@breton.holly.idiocy.org> References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> User-Agent: Mutt/1.12.0 (2019-05-25) X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.7 (/) On Mon, Jul 15, 2019 at 08:38:31PM +0300, Andrii Kolomoiets wrote: > Assume there are only one space - Desktop > 1. emacs -Q > 2. M-x toggle-frame-fullscreen > Now there are two spaces - Desktop and *scratch* > 3. eval (make-frame `((parent-frame . ,(window-frame)))) > Now there are three spaces: > - Desktop > - Empty space named *scratch* with emacs menu > - *scratch* with emacs frames but without menu I hit C-x C-c at this point to exit Emacs and it completely crashed my session. Not great... The patch looks good to me, but lets see if we can find solutions to these other issues. To be honest, given that Apple don’t provide any way to properly deal with spaces, I’d expect this stuff to be handled sensibly by default, but I guess that’s too much to ask. > 1. Removing parent-frame property leaves the frame is same space: > > (let ((new-frame (make-frame `((parent-frame . ,(window-frame)))))) > (modify-frame-parameters new-frame `((parent-frame . nil)))) > > Maybe child frame must go fullscreen if ex-parent frame is in > fullscreen. I suppose the best thing to do would be to move it onto the first space, but there’s no API for that, apparently. Going fullscreen seems like a reasonable work‐around to me. > 2. Setting parent frame after frame creation: > > (let ((frame (window-frame)) > (new-frame (make-frame))) > (modify-frame-parameters new-frame `((parent-frame . ,frame)))) What do you see happening in this case? I’ve got spaces turned on and everything I do just seems to create a new fullscreen space (except when it crashes my session). -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Wed Jul 17 04:39:39 2019 Received: (at 36672) by debbugs.gnu.org; 17 Jul 2019 08:39:39 +0000 Received: from localhost ([127.0.0.1]:51509 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hnfTM-0006Z0-7f for submit@debbugs.gnu.org; Wed, 17 Jul 2019 04:39:36 -0400 Received: from mout.gmx.net ([212.227.17.21]:52741) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hnfTI-0006Yl-Tb for 36672@debbugs.gnu.org; Wed, 17 Jul 2019 04:39:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1563352755; bh=ClYDSybcN5xBd4gud70SUvl0tAuFmnnQwJWJXHly8Jw=; h=X-UI-Sender-Class:Subject:To:Cc:References:From:Date:In-Reply-To; b=lnmuGjR/qO/dbuZlGjzajOkGuJydSHxXOPc/SPqYUvcU/K17u8SyqZxD+Xjyn99TJ e60zUAGarbArbSIZMh9NGHQsN2EbkSlxpqgARJPen3/xDTSopBDurhqoRdrY/igmmO g1Uc7WvhjmxW1vTm5cFO+MIgfZExpzao7yBPWIR4= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.1.101] ([212.95.5.9]) by mail.gmx.com (mrgmx102 [212.227.17.168]) with ESMTPSA (Nemesis) id 0LhCDT-1iGxrY1IAB-00oSvB; Wed, 17 Jul 2019 10:39:15 +0200 Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space To: Alan Third , Andrii Kolomoiets References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> From: martin rudalics Message-ID: <3fbee9bb-22a0-643d-1fcb-dacc1685d67e@gmx.at> Date: Wed, 17 Jul 2019 10:39:15 +0200 MIME-Version: 1.0 In-Reply-To: <20190716192822.GA63701@breton.holly.idiocy.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: de-DE Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:xKn3Rwn2QA2zu2ONr2mXmNeCB89lT4zkU4dPeu46Rc1E5Kp3XOr +HNqOcQmnrmA8Qh+v2Dh6gOHA+MalvW+502PhdbDJH0pelxyQJHUe/pyFEsLxtG6LPnyh96 j/cohoclhSrR2NSV4F2hQtFWgBnvBGb+NkhoIwysuREH9+cXBIDU46nD1cdH56cSOY/z5aU ijh9SAPdE8H8SBo0uiMjg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:m54Xb7QQLx4=:nO841L7z7wZx2KcmtYdJua Jfj1LpHLIHTgorHcKyIltQ6YZ8M5gSOAajmXT1toUHr4+Iga1LfrxA0KWHtNZCGkXsbPES9CB cJchonvwqwWHJSTWv6XaOzXGhgDe70tV2L6QK7zwtFfnZTEuWDPejeJufYkDVuG5Aqw+aqRXT qNWkyWHLiU2/naOh8YWq+1Jd5S1yEDQyNkCoBMBupeYGPf5UqgtlVedCeQNlr8VupcsxhZ6d0 Rbq/uszDjVztkzlebWTa+q/CBCtccYks8EuQClkY5iWn2R2m5IvmVqKGJ+q8IUu8TEyGs59Cf qkZ+GzQcdnT3rSUMbUpacZhzHBQEVESV+CwqhucsQaXLblv64+A7ueeHu20EeXqiO8/SvnAZW YDwBD8BdieZyGhkXAL3ZCFlzsMMrtkxpWhREYspDmh/uQuDbzeLCaAz+eLuoKFubqv7jd/fWJ UgLQDDZ6WRqUADX/wKsebQjwHlF0KYtYUBhJBjgiVsmwrTXtBcTRjoPbEthku7ickarL3UFGQ qo7PvktJGnS5fcZFw7LJEu3nPs2MKqxVuMGFNJ6j7273syPXrInvcZwa0ATUfgOhNYg/CIXNa BOe0PJ/eGAmBDRJqSSLoo2EbfQu/Mkz9jmQDOuLGLfpY90GSONhEFfi5e4J/t0AUTz74nPBIt 2o7xBmQ1NigJ0ZstTyU5/JUVbxWFb2Sz4EJeXZ58k/Ojoel5ZrAMuDFBRh+8+h/MepQ9pS829 98ACmOvaNMdA9B8MK3lvLjL4Vua2gulA5QFizF/7zohQ6rdZXKH4Fil8d/aKnDuqTuB+eUHow EFBC+mBKnbzB0saxx0hDmalmngIjpVCaY4oNjEB8XjxPEoNKu3m2rVyBTfKfqU05Z70OI699Z xYx8LjDPQgSviWccLt+ImZxgM6oTDv3NEPHf+YVAqrZ0S8mga1BbTqgtPsl1mapBRACBRpdhO TYY42WUneTBBQvpi2QxmyCTb1kYR64ohQFSYUWapnNSph7brj7c+KtbwnhCF2v+oYvf5gklDh vFF7nNjkOdQMFCwK2OBGScZ4YfwTH8Ze/UJeaMpHUh7PS4uj8a81lxgpFWRf1u5i2zyTnTpRT Qo0U1/BMGt9pmDmtvyRX674JunUEYlHlmVK X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> Assume there are only one space - Desktop >> 1. emacs -Q >> 2. M-x toggle-frame-fullscreen >> Now there are two spaces - Desktop and *scratch* >> 3. eval (make-frame `((parent-frame . ,(window-frame)))) >> Now there are three spaces: >> - Desktop >> - Empty space named *scratch* with emacs menu >> - *scratch* with emacs frames but without menu > > I hit C-x C-c at this point to exit Emacs and it completely crashed my= > session. Not great... No backtrace? It sounds already strange that one apparently gets two spaces with the same name "*scratch*" here. Do things return to "normality" when one deletes the child frame before trying to exit Emacs? BTW, does maximizing a frame run into similar problems? > The patch looks good to me, Does it work with two child frames of the same parent? > but lets see if we can find solutions to > these other issues. To be honest, given that Apple don=E2=80=99t provi= de any > way to properly deal with spaces, I=E2=80=99d expect this stuff to be = handled > sensibly by default, but I guess that=E2=80=99s too much to ask. > >> 1. Removing parent-frame property leaves the frame is same space: >> >> (let ((new-frame (make-frame `((parent-frame . ,(window-frame)))))) >> (modify-frame-parameters new-frame `((parent-frame . nil)))) >> >> Maybe child frame must go fullscreen if ex-parent frame is in >> fullscreen. Does making it fullscreen then give it a separate menu? Note also that the new parent could be another frame (even a child frame). > I suppose the best thing to do would be to move it onto the first > space, but there=E2=80=99s no API for that, apparently. What happens when one sets 'parent-frame' to nil and removes the 'NSWindowCollectionBehaviorFullScreenAuxiliary' simultaneously? > Going fullscreen seems > like a reasonable work=E2=80=90around to me. > >> 2. Setting parent frame after frame creation: >> >> (let ((frame (window-frame)) >> (new-frame (make-frame))) >> (modify-frame-parameters new-frame `((parent-frame . ,frame)))) > > What do you see happening in this case? I=E2=80=99ve got spaces turned= on and > everything I do just seems to create a new fullscreen space (except > when it crashes my session). Can't one set the 'NSWindowCollectionBehaviorFullScreenAuxiliary' just as with the initial frame here? martin From debbugs-submit-bounces@debbugs.gnu.org Wed Jul 17 14:51:59 2019 Received: (at 36672) by debbugs.gnu.org; 17 Jul 2019 18:51:59 +0000 Received: from localhost ([127.0.0.1]:52996 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hnp1z-0004Mg-8W for submit@debbugs.gnu.org; Wed, 17 Jul 2019 14:51:59 -0400 Received: from mail-wr1-f68.google.com ([209.85.221.68]:36981) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hnp1w-0004MP-7L for 36672@debbugs.gnu.org; Wed, 17 Jul 2019 14:51:57 -0400 Received: by mail-wr1-f68.google.com with SMTP id n9so881086wrr.4 for <36672@debbugs.gnu.org>; Wed, 17 Jul 2019 11:51:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:message-id:mime-version:subject:date:in-reply-to:cc:to :references; bh=xLzlLXz9i7gJX6IXWV+3CvFKppK3qUKGn1Q5/d96gqM=; b=oxjljmu3zocjmle3ZlZAaTPLI6n1QxTu2M4SKwyLv6fOkxpBNnPzvo2fGrJCgbj7HE RohMO+yX21lu6Ou//DnOmjinTHGVqNpv2n+vB8tKrlfbV/PCvEUK4bCRmDq1c6R0fRmk F7m//VYGqdFW/0XR1f8HFgklN1YN9FTq2/23WPThIhmH9bcov/sOkiUORkLoS9Cl4tv2 UWxEP+6e4A9BJNakAySINCnClgaIVBx8cNFlxMKu+M1EnTjKbkQnXB1X6UzhOlVgBtsg 93zsxW85ncVhmUNYctCrFJ/3SdVrl4tYtnVUxAYJ8eON2i3JliqqBeqrD5ZkPUFtrNYP Ojuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:message-id:mime-version:subject:date :in-reply-to:cc:to:references; bh=xLzlLXz9i7gJX6IXWV+3CvFKppK3qUKGn1Q5/d96gqM=; b=kPaaLqCQL2JWArosAegeZTwoD+ktWvhY2Vx1C+nFmvyyKvH6LqsmvPyzgbIvIiH3Ml rxtraxcR6z/RQvEl7iSvrOvUJUe7MYDkvlO6cZzcgJO5/laomcqeVyDLsMatY1bu/8iA LjI2SG5CqojlSCAccYAFDdgOLFuCI5I7qjS90I/Eimi1zADXTIB5u5h0oy0tLs4ItZhl vPp49pMxsGO4ts5j0U6TNdmE4+LkFOL0bOxu6zA9LOwI089o57rqB8OOx5+OXzpHAaUm +PlZBcDP5kqsLugUkH3y4EGA+2oBM5OQqJwrgXVQA4ZoeCThS/vPKGsEaSzZNgDA0Usv W8rA== X-Gm-Message-State: APjAAAV/NTiGo2JiNUQREdkGTOnp9Jl5QSA142jV+R/LmscToEB8ri5O gX8JQAvgMi+1wEfYVRYC6ws= X-Google-Smtp-Source: APXvYqysS7QAyCHv6yODAKGbmRTp36uLcGg6kke9w75yklh+ocx/LKJmpb0pTOr5K56XfJ7g7R4+ww== X-Received: by 2002:a5d:63c8:: with SMTP id c8mr1733172wrw.21.1563389509309; Wed, 17 Jul 2019 11:51:49 -0700 (PDT) Received: from [192.168.0.100] ([91.206.110.133]) by smtp.gmail.com with ESMTPSA id x185sm13642195wmg.46.2019.07.17.11.51.47 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 17 Jul 2019 11:51:48 -0700 (PDT) From: Andrii Kolomoiets Message-Id: <213A995F-5DF6-4CE1-9365-1E227B732CE7@gmail.com> Content-Type: multipart/mixed; boundary="Apple-Mail=_F6C08BAC-3CDA-4FBC-B7B9-D4FE4B5082AF" Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Date: Wed, 17 Jul 2019 21:51:47 +0300 In-Reply-To: <20190716192822.GA63701@breton.holly.idiocy.org> To: Alan Third References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> X-Mailer: Apple Mail (2.3445.104.11) X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --Apple-Mail=_F6C08BAC-3CDA-4FBC-B7B9-D4FE4B5082AF Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 On Jul 16, 2019, at 22:28, Alan Third wrote: >=20 > On Mon, Jul 15, 2019 at 08:38:31PM +0300, Andrii Kolomoiets wrote: >> Assume there are only one space - Desktop >> 1. emacs -Q >> 2. M-x toggle-frame-fullscreen >> Now there are two spaces - Desktop and *scratch* >> 3. eval (make-frame `((parent-frame . ,(window-frame)))) >> Now there are three spaces: >> - Desktop >> - Empty space named *scratch* with emacs menu >> - *scratch* with emacs frames but without menu >=20 > I hit C-x C-c at this point to exit Emacs and it completely crashed my > session. Not great... >=20 > The patch looks good to me, but lets see if we can find solutions to > these other issues. To be honest, given that Apple don=E2=80=99t = provide any > way to properly deal with spaces, I=E2=80=99d expect this stuff to be = handled > sensibly by default, but I guess that=E2=80=99s too much to ask. >=20 >> 1. Removing parent-frame property leaves the frame is same space: >>=20 >> (let ((new-frame (make-frame `((parent-frame . ,(window-frame)))))) >> (modify-frame-parameters new-frame `((parent-frame . nil)))) >>=20 >> Maybe child frame must go fullscreen if ex-parent frame is in >> fullscreen. >=20 > I suppose the best thing to do would be to move it onto the first > space, but there=E2=80=99s no API for that, apparently. Going = fullscreen seems > like a reasonable work=E2=80=90around to me. >=20 I manage to make this code work. Please see attached updated patch. But this patch is not completely ready as it missing compilation = conditions. Just hope you find it useful. >> 2. Setting parent frame after frame creation: >>=20 >> (let ((frame (window-frame)) >> (new-frame (make-frame))) >> (modify-frame-parameters new-frame `((parent-frame . ,frame)))) >=20 > What do you see happening in this case? I=E2=80=99ve got spaces turned = on and > everything I do just seems to create a new fullscreen space (except > when it crashes my session). >=20 I see same result as in the first case: Desktop, empty blank space with Emacs menu, space with Emacs frame and no menu/titlebar. Still can't make this case work. Probably window animation stand in the = way: nsterm.m : 1869: [ 376] ns_set_parent_frame nsterm.m : 1912: [ 377] | child frame must not be in fullscreen 2019-07-17 21:20:49.027 Emacs[91925:3597098] not in fullscreen state If ns_set_parent_frame is called while window is still in process of = going full screen then maybe it must be deferred until animation ends. --Apple-Mail=_F6C08BAC-3CDA-4FBC-B7B9-D4FE4B5082AF Content-Disposition: attachment; filename=ns-emacs-spaces-wip.patch Content-Type: application/octet-stream; x-unix-mode=0644; name="ns-emacs-spaces-wip.patch" Content-Transfer-Encoding: 7bit diff --git a/src/nsterm.h b/src/nsterm.h index 9773eb3e66..d16588718e 100644 --- a/src/nsterm.h +++ b/src/nsterm.h @@ -1274,6 +1274,7 @@ extern char gnustep_base_version[]; /* version tracking */ #if !defined (NS_IMPL_COCOA) || !defined (MAC_OS_X_VERSION_10_7) #define NSFullScreenWindowMask (1 << 14) #define NSWindowCollectionBehaviorFullScreenPrimary (1 << 7) +#define NSWindowCollectionBehaviorFullScreenAuxiliary (1 << 8) #define NSApplicationPresentationFullScreen (1 << 10) #define NSApplicationPresentationAutoHideToolbar (1 << 11) #define NSAppKitVersionNumber10_7 1138 diff --git a/src/nsterm.m b/src/nsterm.m index 02331826d9..8725520d4a 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -1884,6 +1884,8 @@ so some key presses (TAB) are swallowed by the system. */ if ([child parentWindow] != nil) { + parent = [child parentWindow]; + [[child parentWindow] removeChildWindow:child]; #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101000 #if MAC_OS_X_VERSION_MIN_REQUIRED < 101000 @@ -1891,10 +1893,28 @@ so some key presses (TAB) are swallowed by the system. */ #endif [child setAccessibilitySubrole:NSAccessibilityStandardWindowSubrole]; #endif + if (NILP (new_value)){ + NSTRACE ("child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary"); + [child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; + // TODO check parents of parent + if (([parent styleMask] & NSWindowStyleMaskFullScreen) != 0){ + // if current parent in fullscreen and not new parent make child fullscreen + NSTRACE ("make child fullscreen"); + [child toggleFullScreen:child]; + } + } } if (!NILP (new_value)) { + // child frame must not be in fullscreen + if (([child styleMask] & NSWindowStyleMaskFullScreen) != 0){ + NSTRACE ("child frame must not be in fullscreen"); + [child toggleFullScreen:child]; + } + NSTRACE ("child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary"); + [child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary]; + parent = [FRAME_NS_VIEW (p) window]; [parent addChildWindow: child @@ -7365,7 +7385,10 @@ - (instancetype) initFrameFromEmacs: (struct frame *)f #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 if (NSAppKitVersionNumber >= NSAppKitVersionNumber10_7) #endif - [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; + if (FRAME_PARENT_FRAME (f)) + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary]; + else + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; #endif wr = [win frame]; --Apple-Mail=_F6C08BAC-3CDA-4FBC-B7B9-D4FE4B5082AF-- From debbugs-submit-bounces@debbugs.gnu.org Tue Jul 23 14:14:30 2019 Received: (at 36672) by debbugs.gnu.org; 23 Jul 2019 18:14:30 +0000 Received: from localhost ([127.0.0.1]:35605 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hpzJ0-0006Yi-Bw for submit@debbugs.gnu.org; Tue, 23 Jul 2019 14:14:30 -0400 Received: from mail-wr1-f49.google.com ([209.85.221.49]:35196) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hpzIx-0006YR-Sl for 36672@debbugs.gnu.org; Tue, 23 Jul 2019 14:14:28 -0400 Received: by mail-wr1-f49.google.com with SMTP id y4so44205455wrm.2 for <36672@debbugs.gnu.org>; Tue, 23 Jul 2019 11:14:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:message-id:mime-version:subject:date:in-reply-to:cc:to :references; bh=KKrw1ngpsdb1pM8pIjwxA9sLg57yTQPmek8L+PzqTig=; b=drlCKcGvS+8slNnXxLmcDzWSrmh4MW/yOujHMtCck/r5Iy0ZPuX0Xp9EZDQ3Fx5QOr RVmL2vVcFGm3nAA+u6it4hwZ18E4uSoSLYIMKubbSjfuia9djdf7cweha4h4GvGlsElM 3BaUxX0lAyMsTGhsCjx38ol7nfwdM61QseMEY11Zv9qdhe6zjg9DCgFLJtpQckpcjeR7 3ldgO2AEVy4U+5wrIbKX0UwMw3LjIxiKGFPKHWan2VeaHrJhfGpFq8NmjhFrHdMuVejT PscMXguL73giiVjZ6ASBWOrzt154BBbi6U4XXmsjBsniXXVErNRcrNVc3sk/LZU2SH0g uLFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:message-id:mime-version:subject:date :in-reply-to:cc:to:references; bh=KKrw1ngpsdb1pM8pIjwxA9sLg57yTQPmek8L+PzqTig=; b=t2Nx5IdEN0WbcIAxfZIrI9OeguJU3Muf1JNpgt8nDHszZU01nJNwnvsAMtcGx2Corj QKRaajPS7PA8osehSGxPjKNle+puolktFHRZ4avGicn7RttwjR2aHsVHhoL38lUKAEKF xUMBjTOXiKzIAW6rI8g5/T3/iznUscYHVuSLqiaerphS2wF9fKtyGj8u93xCkmx06ONQ ZV+cwomzRiSZRNFI5DXAaCCTsQsMxSpflq47tAB7eLtYt1QFTjC1ovUG4vPQfkfPbA/A rOQb7Wb5bGBSLDl+Q6SvSFS8o21rjCDhEh/ix32fVNWi3gtBJbbp5GuzL10MaLi1bk+F V4QQ== X-Gm-Message-State: APjAAAWXwQIh+Ma3/9zjUtycr8Kyvl38zzawaaZMg0Dj5QK3AXXUo4q3 9Q26DHjUhJxGJVnW8QZECBs= X-Google-Smtp-Source: APXvYqwfiahZ9L9O2z5o3yZzjESErq3o2DvebX9iW9ZBDC4afgq5Bp0fPR49kmWZ6bq1APqQsVS5Jw== X-Received: by 2002:a5d:470e:: with SMTP id y14mr57712036wrq.308.1563905662085; Tue, 23 Jul 2019 11:14:22 -0700 (PDT) Received: from [192.168.0.100] ([91.206.110.141]) by smtp.gmail.com with ESMTPSA id x20sm97373597wrg.10.2019.07.23.11.14.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 23 Jul 2019 11:14:21 -0700 (PDT) From: Andrii Kolomoiets Message-Id: Content-Type: multipart/mixed; boundary="Apple-Mail=_A3D226A6-99FF-4758-A3D3-1E8EC325CD41" Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Date: Tue, 23 Jul 2019 21:14:19 +0300 In-Reply-To: <20190716192822.GA63701@breton.holly.idiocy.org> To: Alan Third References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> X-Mailer: Apple Mail (2.3445.104.11) X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --Apple-Mail=_A3D226A6-99FF-4758-A3D3-1E8EC325CD41 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii > On Jul 16, 2019, at 22:28, Alan Third wrote: > > The patch looks good to me, but lets see if we can find solutions to > these other issues. I made some progress on this issue. The idea is to wait for fullscreen transition to complete: - Set property isFullScreenTransition on windowWillEnterFullScreen and windowWillExitFullScreen events; - Clear that property on windowDidEnterFullScreen and windowDidExitFullScreen events; - Wait for property to be cleared when we need to. Removing parent-frame property causes child frame to enter fullscreen if some of parent frames is in fullscreen. Setting parent-frame property to fullscreen window causes window to leave fullscreen. As a side effect (sleep-for 0.5) in toggle-frame-fullscreen is no longer needed (bug#28496). But I need help with some questions: 1. Is it the rigth way to wait for some NS event by calling wait_reading_process_output or is there a better way? 2. I commented some code in windowDidMove with FIXME comment. After windowDidMove event is triggered, windowDidExitFullScreen is not received and fullscreen transition is never "completed". With that code commented windowDidExitFullScreen is received. Is this code somehow breaks the events queue? Actually it is the first time I'm working with the C side of Emacs. And with AppKit. And with C :) Please let me know if my decisions and conclusions are wrong. Thanks! --Apple-Mail=_A3D226A6-99FF-4758-A3D3-1E8EC325CD41 Content-Disposition: attachment; filename=ns-emacs-spaces.patch Content-Type: application/octet-stream; x-unix-mode=0644; name="ns-emacs-spaces.patch" Content-Transfer-Encoding: quoted-printable diff=20--git=20a/lisp/frame.el=20b/lisp/frame.el=0Aindex=20= fd7e872fb6..325b4c07c5=20100644=0A---=20a/lisp/frame.el=0A+++=20= b/lisp/frame.el=0A@@=20-2629,11=20+2629,7=20@@=20toggle-frame-fullscreen=0A= =20=09=20=20=20=20=20=20(set-frame-parameter=20frame=20'fullscreen=20= fullscreen-restore)=0A=20=09=20=20=20=20(set-frame-parameter=20frame=20= 'fullscreen=20nil)))=0A=20=20=20=20=20=20=20(modify-frame-parameters=0A-=20= =20=20=20=20=20=20frame=20`((fullscreen=20.=20fullboth)=20= (fullscreen-restore=20.=20,fullscreen))))=0A-=20=20=20=20;;=20= Manipulating=20a=20frame=20without=20waiting=20for=20the=20fullscreen=0A= -=20=20=20=20;;=20animation=20to=20complete=20can=20cause=20a=20crash,=20= or=20other=20unexpected=0A-=20=20=20=20;;=20behavior,=20on=20macOS=20= (bug#28496).=0A-=20=20=20=20(when=20(featurep=20'cocoa)=20(sleep-for=20= 0.5))))=0A+=20=20=20=20=20=20=20frame=20`((fullscreen=20.=20fullboth)=20= (fullscreen-restore=20.=20,fullscreen))))))=0A=20=0A=20=0C=0A=20;;;;=20= Key=20bindings=0Adiff=20--git=20a/src/nsterm.h=20b/src/nsterm.h=0Aindex=20= 9773eb3e66..9391e31b48=20100644=0A---=20a/src/nsterm.h=0A+++=20= b/src/nsterm.h=0A@@=20-417,6=20+417,7=20@@=20#define=20= NSTRACE_UNSILENCE()=0A=20=20=20=20int=20maximized_width,=20= maximized_height;=0A=20=20=20=20NSWindow=20*nonfs_window;=0A=20=20=20=20= BOOL=20fs_is_native;=0A+=20=20=20BOOL=20is_fullscreen_transition;=0A=20= @public=0A=20=20=20=20struct=20frame=20*emacsframe;=0A=20=20=20=20int=20= rows,=20cols;=0A@@=20-448,6=20+449,8=20@@=20#define=20= NSTRACE_UNSILENCE()=0A=20-=20(void)=20toggleFullScreen:=20(id)=20sender;=0A= =20-=20(BOOL)=20fsIsNative;=0A=20-=20(BOOL)=20isFullscreen;=0A+-=20= (BOOL)=20isFullScreenTransition;=0A+-=20(void)=20= waitFullScreenTransition;=0A=20#if=20defined=20(NS_IMPL_COCOA)=20&&=20= MAC_OS_X_VERSION_MAX_ALLOWED=20>=3D=201070=0A=20-=20(void)=20= updateCollectionBehavior;=0A=20#endif=0A@@=20-1274,6=20+1277,7=20@@=20= #define=20SCREENMAXBOUND(x)=20(IN_BOUND=20(-SCREENMAX,=20x,=20= SCREENMAX))=0A=20#if=20!defined=20(NS_IMPL_COCOA)=20||=20!defined=20= (MAC_OS_X_VERSION_10_7)=0A=20#define=20NSFullScreenWindowMask=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20(1=20<<=2014)=0A=20= #define=20NSWindowCollectionBehaviorFullScreenPrimary=20(1=20<<=207)=0A= +#define=20NSWindowCollectionBehaviorFullScreenAuxiliary=20(1=20<<=208)=0A= =20#define=20NSApplicationPresentationFullScreen=20=20=20=20=20=20=20=20=20= (1=20<<=2010)=0A=20#define=20NSApplicationPresentationAutoHideToolbar=20=20= =20=20(1=20<<=2011)=0A=20#define=20NSAppKitVersionNumber10_7=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=201138=0Adiff=20--git=20= a/src/nsterm.m=20b/src/nsterm.m=0Aindex=2002331826d9..df6a0aab80=20= 100644=0A---=20a/src/nsterm.m=0A+++=20b/src/nsterm.m=0A@@=20-1495,9=20= +1495,11=20@@=20-(void)remove=0A=20=0A=20=20=20=20=20=20=20/*=20Making=20= a=20new=20frame=20from=20a=20fullscreen=20frame=20will=20make=20the=20= new=20frame=0A=20=20=20=20=20=20=20=20=20=20fullscreen=20also.=20=20So=20= skip=20handleFS=20as=20this=20will=20print=20an=20error.=20=20*/=0A-=20=20= =20=20=20=20if=20([view=20fsIsNative]=20&&=20f->want_fullscreen=20=3D=3D=20= FULLSCREEN_BOTH=0A-=20=20=20=20=20=20=20=20=20=20&&=20[view=20= isFullscreen])=0A+=20=20=20=20=20=20if=20([view=20fsIsNative]=20&&=20= [view=20isFullscreen])=20{=0A+=20=20=20=20=20=20=20=20//=20maybe=20it=20= is=20not=20necessary=20to=20wait=0A+=20=20=20=20=20=20=20=20[view=20= waitFullScreenTransition];=0A=20=20=20=20=20=20=20=20=20return;=0A+=20=20= =20=20=20=20}=0A=20=0A=20=20=20=20=20=20=20if=20(f->want_fullscreen=20!=3D= =20FULLSCREEN_NONE)=0A=20=20=20=20=20=20=20=20=20{=0A@@=20-1882,19=20= +1884,52=20@@=20so=20some=20key=20presses=20(TAB)=20are=20swallowed=20by=20= the=20system.=20=20*/=0A=20=20=20=20=20=20=20block_input=20();=0A=20=20=20= =20=20=20=20child=20=3D=20[FRAME_NS_VIEW=20(f)=20window];=0A=20=0A+#if=20= defined=20(NS_IMPL_COCOA)=20&&=20MAC_OS_X_VERSION_MAX_ALLOWED=20>=3D=20= 1070=0A+=20=20=20=20=20=20EmacsView=20*view=20=3D=20(EmacsView=20= *)FRAME_NS_VIEW=20(f);=0A+#endif=0A+=0A=20=20=20=20=20=20=20if=20([child=20= parentWindow]=20!=3D=20nil)=0A=20=20=20=20=20=20=20=20=20{=0A+#if=20= defined=20(NS_IMPL_COCOA)=20&&=20MAC_OS_X_VERSION_MAX_ALLOWED=20>=3D=20= 1070=0A+=20=20=20=20=20=20=20=20=20=20parent=20=3D=20[child=20= parentWindow];=0A+#endif=0A+=0A=20=20=20=20=20=20=20=20=20=20=20[[child=20= parentWindow]=20removeChildWindow:child];=0A=20#if=20defined=20= (NS_IMPL_COCOA)=20&&=20MAC_OS_X_VERSION_MAX_ALLOWED=20>=3D=20101000=0A=20= #if=20MAC_OS_X_VERSION_MIN_REQUIRED=20<=20101000=0A=20=20=20=20=20=20=20=20= =20=20=20if=20([child=20= respondsToSelector:@selector(setAccessibilitySubrole:)])=0A=20#endif=0A=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20[child=20= setAccessibilitySubrole:NSAccessibilityStandardWindowSubrole];=0A+#endif=0A= +#if=20defined=20(NS_IMPL_COCOA)=20&&=20MAC_OS_X_VERSION_MAX_ALLOWED=20= >=3D=201070=0A+=20=20=20=20=20=20=20=20=20=20if=20(NILP=20(new_value))=20= {=0A+=20=20=20=20=20=20=20=20=20=20=20=20NSTRACE=20("child=20= setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary");=0A+=20= =20=20=20=20=20=20=20=20=20=20=20[child=20= setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary];=0A+=20= =20=20=20=20=20=20=20=20=20=20=20//=20if=20current=20parent=20in=20= fullscreen=20and=20no=20new=20parent=20make=20child=20fullscreen=0A+=20=20= =20=20=20=20=20=20=20=20=20=20while=20(parent)=20{=0A+=20=20=20=20=20=20=20= =20=20=20=20=20=20=20if=20(([parent=20styleMask]=20&=20= NSWindowStyleMaskFullScreen)=20!=3D=200){=0A+=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20[view=20toggleFullScreen:child];=0A+=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20break;=0A+=20=20=20=20=20=20=20=20=20=20=20=20= =20=20}=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20//=20check=20all=20= parents=0A+=20=20=20=20=20=20=20=20=20=20=20=20=20=20parent=20=3D=20= [parent=20parentWindow];=0A+=20=20=20=20=20=20=20=20=20=20=20=20}=0A+=20=20= =20=20=20=20=20=20=20=20}=0A=20#endif=0A=20=20=20=20=20=20=20=20=20}=0A=20= =0A=20=20=20=20=20=20=20if=20(!NILP=20(new_value))=0A=20=20=20=20=20=20=20= =20=20{=0A+#if=20defined=20(NS_IMPL_COCOA)=20&&=20= MAC_OS_X_VERSION_MAX_ALLOWED=20>=3D=201070=0A+=20=20=20=20=20=20=20=20=20= =20//=20child=20frame=20must=20not=20be=20in=20fullscreen=0A+=20=20=20=20= =20=20=20=20=20=20if=20([view=20fsIsNative]=20&&=20[view=20= isFullscreen]){=0A+=20=20=20=20=20=20=20=20=20=20=20=20//=20in=20case=20= child=20is=20going=20fullscreen=0A+=20=20=20=20=20=20=20=20=20=20=20=20= [view=20waitFullScreenTransition];=0A+=20=20=20=20=20=20=20=20=20=20=20=20= [view=20toggleFullScreen:child];=0A+=20=20=20=20=20=20=20=20=20=20}=0A+=20= =20=20=20=20=20=20=20=20=20NSTRACE=20("child=20= setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary");=0A= +=20=20=20=20=20=20=20=20=20=20[child=20= setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary];=0A= +#endif=0A=20=20=20=20=20=20=20=20=20=20=20parent=20=3D=20[FRAME_NS_VIEW=20= (p)=20window];=0A=20=0A=20=20=20=20=20=20=20=20=20=20=20[parent=20= addChildWindow:=20child=0A@@=20-7336,6=20+7371,7=20@@=20-=20= (instancetype)=20initFrameFromEmacs:=20(struct=20frame=20*)f=0A=20#endif=0A= =20=20=20=20=20fs_is_native=20=3D=20ns_use_native_fullscreen;=0A=20= #endif=0A+=20=20is_fullscreen_transition=20=3D=20NO;=0A=20=0A=20=20=20= maximized_width=20=3D=20maximized_height=20=3D=20-1;=0A=20=20=20= nonfs_window=20=3D=20nil;=0A@@=20-7365,7=20+7401,10=20@@=20-=20= (instancetype)=20initFrameFromEmacs:=20(struct=20frame=20*)f=0A=20#if=20= MAC_OS_X_VERSION_MIN_REQUIRED=20<=201070=0A=20=20=20if=20= (NSAppKitVersionNumber=20>=3D=20NSAppKitVersionNumber10_7)=0A=20#endif=0A= -=20=20=20=20[win=20= setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary];=0A+=20= =20=20=20if=20(FRAME_PARENT_FRAME=20(f))=0A+=20=20=20=20=20=20[win=20= setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary];=0A= +=20=20=20=20else=0A+=20=20=20=20=20=20[win=20= setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary];=0A=20= #endif=0A=20=0A=20=20=20wr=20=3D=20[win=20frame];=0A@@=20-7496,11=20= +7535,12=20@@=20-=20(void)windowDidMove:=20sender=0A=20=20=20=20=20=20=20= emacsframe->top_pos=20=3D=0A=20=20=20=20=20=20=20=20=20= NS_PARENT_WINDOW_TOP_POS=20(emacsframe)=20-=20(r.origin.y=20+=20= r.size.height);=0A=20=0A-=20=20=20=20=20=20if=20(emacs_event)=0A-=20=20=20= =20=20=20=20=20{=0A-=20=20=20=20=20=20=20=20=20=20emacs_event->kind=20=3D=20= MOVE_FRAME_EVENT;=0A-=20=20=20=20=20=20=20=20=20=20EV_TRAILER=20= ((id)nil);=0A-=20=20=20=20=20=20=20=20}=0A+=20=20=20=20=20=20//=20FIXME:=20= after=20event=20part=20below=20didExitFullScreen=20is=20not=20received=0A= +=20=20=20=20=20=20//=20if=20(emacs_event)=0A+=20=20=20=20=20=20//=20=20=20= {=0A+=20=20=20=20=20=20//=20=20=20=20=20emacs_event->kind=20=3D=20= MOVE_FRAME_EVENT;=0A+=20=20=20=20=20=20//=20=20=20=20=20EV_TRAILER=20= ((id)nil);=0A+=20=20=20=20=20=20//=20=20=20}=0A=20=20=20=20=20}=0A=20}=0A= =20=0A@@=20-7700,6=20+7740,7=20@@=20-=20= (NSApplicationPresentationOptions)window:(NSWindow=20*)window=0A=20-=20= (void)windowWillEnterFullScreen:(NSNotification=20*)notification=0A=20{=0A= =20=20=20NSTRACE=20("[EmacsView=20windowWillEnterFullScreen:]");=0A+=20=20= is_fullscreen_transition=20=3D=20YES;=0A=20=20=20[self=20= windowWillEnterFullScreen];=0A=20}=0A=20-=20= (void)windowWillEnterFullScreen=20/*=20provided=20for=20direct=20calls=20= */=0A@@=20-7712,6=20+7753,7=20@@=20-=20= (void)windowDidEnterFullScreen:(NSNotification=20*)notification=0A=20{=0A= =20=20=20NSTRACE=20("[EmacsView=20windowDidEnterFullScreen:]");=0A=20=20=20= [self=20windowDidEnterFullScreen];=0A+=20=20is_fullscreen_transition=20=3D= =20NO;=0A=20}=0A=20=0A=20-=20(void)windowDidEnterFullScreen=20/*=20= provided=20for=20direct=20calls=20*/=0A@@=20-7750,6=20+7792,7=20@@=20-=20= (void)windowDidEnterFullScreen=20/*=20provided=20for=20direct=20calls=20= */=0A=20-=20(void)windowWillExitFullScreen:(NSNotification=20= *)notification=0A=20{=0A=20=20=20NSTRACE=20("[EmacsView=20= windowWillExitFullScreen:]");=0A+=20=20is_fullscreen_transition=20=3D=20= YES;=0A=20=20=20[self=20windowWillExitFullScreen];=0A=20}=0A=20=0A@@=20= -7769,6=20+7812,7=20@@=20-=20= (void)windowDidExitFullScreen:(NSNotification=20*)notification=0A=20{=0A=20= =20=20NSTRACE=20("[EmacsView=20windowDidExitFullScreen:]");=0A=20=20=20= [self=20windowDidExitFullScreen];=0A+=20=20is_fullscreen_transition=20=3D=20= NO;=0A=20}=0A=20=0A=20-=20(void)windowDidExitFullScreen=20/*=20provided=20= for=20direct=20calls=20*/=0A@@=20-7798,6=20+7842,21=20@@=20-=20= (void)windowDidExitFullScreen=20/*=20provided=20for=20direct=20calls=20= */=0A=20=20=20=20=20[[self=20window]=20performZoom:self];=0A=20}=0A=20=0A= +-=20(BOOL)isFullScreenTransition=0A+{=0A+=20=20return=20= is_fullscreen_transition;=0A+}=0A+=0A+-=20(void)waitFullScreenTransition=0A= +{=0A+#if=20MAC_OS_X_VERSION_MAX_ALLOWED=20>=3D=201070=0A+=20=20while=20= ([self=20isFullScreenTransition]){=0A+=20=20=20=20NSTRACE=20("wait=20for=20= fullscreen");=0A+=20=20=20=20wait_reading_process_output=20(0,=20= 300000000,=200,=201,=20Qnil,=20NULL,=200);=0A+=20=20}=0A+#endif=0A+}=0A+=0A= =20-=20(BOOL)fsIsNative=0A=20{=0A=20=20=20return=20fs_is_native;=0A@@=20= -7835,10=20+7894,17=20@@=20-=20(void)updateCollectionBehavior=0A=20=20=20= =20=20{=0A=20=20=20=20=20=20=20NSWindow=20*win=20=3D=20[self=20window];=0A= =20=20=20=20=20=20=20NSWindowCollectionBehavior=20b=20=3D=20[win=20= collectionBehavior];=0A-=20=20=20=20=20=20if=20= (ns_use_native_fullscreen)=0A-=20=20=20=20=20=20=20=20b=20|=3D=20= NSWindowCollectionBehaviorFullScreenPrimary;=0A-=20=20=20=20=20=20else=0A= +=20=20=20=20=20=20if=20(ns_use_native_fullscreen)=20{=0A+=20=20=20=20=20= =20=20=20=20=20if=20([win=20parentWindow])=20{=0A+=20=20=20=20=20=20=20=20= =20=20=20=20b=20&=3D=20~NSWindowCollectionBehaviorFullScreenPrimary;=0A+=20= =20=20=20=20=20=20=20=20=20=20=20b=20|=3D=20= NSWindowCollectionBehaviorFullScreenAuxiliary;=0A+=20=20=20=20=20=20=20=20= =20=20}=20else=20{=0A+=20=20=20=20=20=20=20=20=20=20=20=20b=20|=3D=20= NSWindowCollectionBehaviorFullScreenPrimary;=0A+=20=20=20=20=20=20=20=20=20= =20=20=20b=20&=3D=20~NSWindowCollectionBehaviorFullScreenAuxiliary;=0A+=20= =20=20=20=20=20=20=20=20=20}=0A+=20=20=20=20=20=20}=20else=20{=0A=20=20=20= =20=20=20=20=20=20b=20&=3D=20= ~NSWindowCollectionBehaviorFullScreenPrimary;=0A+=20=20=20=20=20=20}=0A=20= =0A=20=20=20=20=20=20=20[win=20setCollectionBehavior:=20b];=0A=20#if=20= MAC_OS_X_VERSION_MIN_REQUIRED=20<=201070=0A@@=20-7863,9=20+7929,14=20@@=20= -=20(void)toggleFullScreen:=20(id)sender=0A=20=20=20=20=20{=0A=20#if=20= defined=20(NS_IMPL_COCOA)=20&&=20MAC_OS_X_VERSION_MAX_ALLOWED=20>=3D=20= 1070=0A=20#if=20MAC_OS_X_VERSION_MIN_REQUIRED=20<=201070=0A-=20=20=20=20=20= =20if=20([[self=20window]=20respondsToSelector:=20= @selector(toggleFullScreen:)])=0A+=20=20=20=20=20=20if=20([[self=20= window]=20respondsToSelector:=20@selector(toggleFullScreen:)]){=0A=20= #endif=0A=20=20=20=20=20=20=20=20=20[[self=20window]=20= toggleFullScreen:sender];=0A+=20=20=20=20=20=20=20=20//=20wait=20for=20= fullscreen=20animation=20complete=20(bug#28496)=0A+=20=20=20=20=20=20=20=20= [self=20waitFullScreenTransition];=0A+#endif=0A+#if=20= MAC_OS_X_VERSION_MIN_REQUIRED=20<=201070=0A+=20=20=20=20=20=20}=0A=20= #endif=0A=20=20=20=20=20=20=20return;=0A=20=20=20=20=20}=0A= --Apple-Mail=_A3D226A6-99FF-4758-A3D3-1E8EC325CD41-- From debbugs-submit-bounces@debbugs.gnu.org Fri Feb 14 03:23:33 2020 Received: (at 36672) by debbugs.gnu.org; 14 Feb 2020 08:23:33 +0000 Received: from localhost ([127.0.0.1]:60806 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j2WG5-0006t5-1x for submit@debbugs.gnu.org; Fri, 14 Feb 2020 03:23:33 -0500 Received: from mail-lj1-f173.google.com ([209.85.208.173]:41634) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j2WG3-0006ss-Aj for 36672@debbugs.gnu.org; Fri, 14 Feb 2020 03:23:32 -0500 Received: by mail-lj1-f173.google.com with SMTP id h23so9730702ljc.8 for <36672@debbugs.gnu.org>; Fri, 14 Feb 2020 00:23:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=fF5t9qa5adR/1PMXoymk5V9/dpTw1cY8U9CCwB8mm+M=; b=hXeYVySUAIhtVoo4sz3UzuBOj4vq5Q0RbNGCEamjZwFJkxatfAvqqVtYHvyFy+xv6W 1oucSNvMn/wgFAPi4NUU+kxawipHyHiVcvUbaeU/X/zRMvvIcO+8+Lt7wBJo1yINJWsu 3koMEEUbGH4E6EmgbfoVVuBz2134w31DlAaVbB9yIvWid49V9gGlZ6SAFYQ+U7QV+y5N xHgWaxDYMXsC+5oyuMEiP9L8qIxLDBBz5yCjP+ExgipWG50F8bnhOUbY369AcOX75a4I ClLA6ZpWBT3BwM1zbxghncPGjAK9FVckzzgXEggfGStG0MjuPNoMurXzcLq4Pmstqw4z m4Gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=fF5t9qa5adR/1PMXoymk5V9/dpTw1cY8U9CCwB8mm+M=; b=Qh6UQX6G6T+8UIApRpBVl3UPSR/ZkZjFBQ2InNZakThMPtEPOaCxZYV6UXzhdptSAk cDtxToS2upMCvx955r19oqrVzPZ276tIEGAVEn8QLKia8g1zgcR4v8r73p6p2vRJgs5K 7ypgk3AsbSLZcv4JTmlXAH70uvVRVN9tnsw2OWzen+nNxDLsFrZiGwFGRnA5LVVRpV8h cWZLW5h2RcMP4zCCjenz6qB+nrInxoIY245gjSGDjPwbtPQqUX7I54eCBy2sVV0QPLOF JxbWZ+eO2HL/PkJwTqyy4BqM73pCk13YtVwsE/iclsD2mJRtMtEoOqQADN7XKm5YDPmw Gc5w== X-Gm-Message-State: APjAAAWz6b/e98UwE47OjX2tQuwiKbSadRApDS6AW/jU3g/c9iYMvv2N uzWcBSPHfzCBnOtp22j9L9ed8vFg X-Google-Smtp-Source: APXvYqwVvurC8ohhqT2dr6qPz6jzT+Bd6ATOJFkGvJv4iZ5rQhJPGRT2Q1nf0mKKYXC5uVVjT+htVw== X-Received: by 2002:a2e:2201:: with SMTP id i1mr1326365lji.110.1581668604397; Fri, 14 Feb 2020 00:23:24 -0800 (PST) Received: from 10-1-1-147.office.area (188-42-207-82.ip.ukrtel.net. [82.207.42.188]) by smtp.gmail.com with ESMTPSA id x23sm2680473lff.24.2020.02.14.00.23.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Feb 2020 00:23:23 -0800 (PST) From: Andrii Kolomoiets To: Alan Third Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> Date: Fri, 14 Feb 2020 10:23:22 +0200 In-Reply-To: (Andrii Kolomoiets's message of "Tue, 23 Jul 2019 21:14:19 +0300") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Andrii Kolomoiets writes: >> On Jul 16, 2019, at 22:28, Alan Third wrote: >> >> The patch looks good to me, but lets see if we can find solutions to >> these other issues. > > I made some progress on this issue. > > The idea is to wait for fullscreen transition to complete: > - Set property isFullScreenTransition on windowWillEnterFullScreen and > windowWillExitFullScreen events; > - Clear that property on windowDidEnterFullScreen and > windowDidExitFullScreen events; > - Wait for property to be cleared when we need to. Updated patch to work with latest master --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=ns-emacs-spaces-updated.patch diff --git a/lisp/frame.el b/lisp/frame.el index 16ee7580f8..7ed3e23f3c 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -2676,11 +2676,7 @@ toggle-frame-fullscreen (set-frame-parameter frame 'fullscreen fullscreen-restore) (set-frame-parameter frame 'fullscreen nil))) (modify-frame-parameters - frame `((fullscreen . fullboth) (fullscreen-restore . ,fullscreen)))) - ;; Manipulating a frame without waiting for the fullscreen - ;; animation to complete can cause a crash, or other unexpected - ;; behavior, on macOS (bug#28496). - (when (featurep 'cocoa) (sleep-for 0.5)))) + frame `((fullscreen . fullboth) (fullscreen-restore . ,fullscreen)))))) ;;;; Key bindings diff --git a/src/nsterm.h b/src/nsterm.h index 7c6197f128..243d66be60 100644 --- a/src/nsterm.h +++ b/src/nsterm.h @@ -417,6 +417,7 @@ #define NSTRACE_UNSILENCE() int maximized_width, maximized_height; NSWindow *nonfs_window; BOOL fs_is_native; + BOOL is_fullscreen_transition; #ifdef NS_IMPL_COCOA CGContextRef drawingBuffer; #endif @@ -451,6 +452,8 @@ #define NSTRACE_UNSILENCE() - (void) toggleFullScreen: (id) sender; - (BOOL) fsIsNative; - (BOOL) isFullscreen; +- (BOOL) isFullScreenTransition; +- (void) waitFullScreenTransition; #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 - (void) updateCollectionBehavior; #endif @@ -1270,6 +1273,7 @@ #define SCREENMAXBOUND(x) (IN_BOUND (-SCREENMAX, x, SCREENMAX)) #if !defined (NS_IMPL_COCOA) || !defined (MAC_OS_X_VERSION_10_7) #define NSFullScreenWindowMask (1 << 14) #define NSWindowCollectionBehaviorFullScreenPrimary (1 << 7) +#define NSWindowCollectionBehaviorFullScreenAuxiliary (1 << 8) #define NSApplicationPresentationFullScreen (1 << 10) #define NSApplicationPresentationAutoHideToolbar (1 << 11) #define NSAppKitVersionNumber10_7 1138 diff --git a/src/nsterm.m b/src/nsterm.m index 2cf6774a1f..b290fd3d95 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -1588,9 +1588,11 @@ -(void)remove /* Making a new frame from a fullscreen frame will make the new frame fullscreen also. So skip handleFS as this will print an error. */ - if ([view fsIsNative] && f->want_fullscreen == FULLSCREEN_BOTH - && [view isFullscreen]) + if ([view fsIsNative] && [view isFullscreen]) { + // maybe it is not necessary to wait + [view waitFullScreenTransition]; return; + } if (f->want_fullscreen != FULLSCREEN_NONE) { @@ -1976,19 +1978,52 @@ so some key presses (TAB) are swallowed by the system. */ block_input (); child = [FRAME_NS_VIEW (f) window]; +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + EmacsView *view = (EmacsView *)FRAME_NS_VIEW (f); +#endif + if ([child parentWindow] != nil) { +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + parent = [child parentWindow]; +#endif + [[child parentWindow] removeChildWindow:child]; #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101000 #if MAC_OS_X_VERSION_MIN_REQUIRED < 101000 if ([child respondsToSelector:@selector(setAccessibilitySubrole:)]) #endif [child setAccessibilitySubrole:NSAccessibilityStandardWindowSubrole]; +#endif +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + if (NILP (new_value)) { + NSTRACE ("child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary"); + [child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; + // if current parent in fullscreen and no new parent make child fullscreen + while (parent) { + if (([parent styleMask] & NSWindowStyleMaskFullScreen) != 0){ + [view toggleFullScreen:child]; + break; + } + // check all parents + parent = [parent parentWindow]; + } + } #endif } if (!NILP (new_value)) { +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + // child frame must not be in fullscreen + if ([view fsIsNative] && [view isFullscreen]){ + // in case child is going fullscreen + [view waitFullScreenTransition]; + [view toggleFullScreen:child]; + } + NSTRACE ("child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary"); + [child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary]; +#endif parent = [FRAME_NS_VIEW (p) window]; [parent addChildWindow: child @@ -7411,6 +7446,7 @@ - (instancetype) initFrameFromEmacs: (struct frame *)f #endif fs_is_native = ns_use_native_fullscreen; #endif + is_fullscreen_transition = NO; maximized_width = maximized_height = -1; nonfs_window = nil; @@ -7442,7 +7478,10 @@ - (instancetype) initFrameFromEmacs: (struct frame *)f #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 if (NSAppKitVersionNumber >= NSAppKitVersionNumber10_7) #endif - [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; + if (FRAME_PARENT_FRAME (f)) + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary]; + else + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; #endif wr = [win frame]; @@ -7565,11 +7604,12 @@ - (void)windowDidMove: sender emacsframe->top_pos = NS_PARENT_WINDOW_TOP_POS (emacsframe) - (r.origin.y + r.size.height); - if (emacs_event) - { - emacs_event->kind = MOVE_FRAME_EVENT; - EV_TRAILER ((id)nil); - } + // FIXME: after event part below didExitFullScreen is not received + // if (emacs_event) + // { + // emacs_event->kind = MOVE_FRAME_EVENT; + // EV_TRAILER ((id)nil); + // } } } @@ -7769,6 +7809,7 @@ - (NSApplicationPresentationOptions)window:(NSWindow *)window - (void)windowWillEnterFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowWillEnterFullScreen:]"); + is_fullscreen_transition = YES; [self windowWillEnterFullScreen]; } - (void)windowWillEnterFullScreen /* provided for direct calls */ @@ -7781,6 +7822,7 @@ - (void)windowDidEnterFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowDidEnterFullScreen:]"); [self windowDidEnterFullScreen]; + is_fullscreen_transition = NO; } - (void)windowDidEnterFullScreen /* provided for direct calls */ @@ -7819,6 +7861,7 @@ - (void)windowDidEnterFullScreen /* provided for direct calls */ - (void)windowWillExitFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowWillExitFullScreen:]"); + is_fullscreen_transition = YES; [self windowWillExitFullScreen]; } @@ -7838,6 +7881,7 @@ - (void)windowDidExitFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowDidExitFullScreen:]"); [self windowDidExitFullScreen]; + is_fullscreen_transition = NO; } - (void)windowDidExitFullScreen /* provided for direct calls */ @@ -7867,6 +7911,21 @@ - (void)windowDidExitFullScreen /* provided for direct calls */ [[self window] performZoom:self]; } +- (BOOL)isFullScreenTransition +{ + return is_fullscreen_transition; +} + +- (void)waitFullScreenTransition +{ +#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + while ([self isFullScreenTransition]){ + NSTRACE ("wait for fullscreen"); + wait_reading_process_output (0, 300000000, 0, 1, Qnil, NULL, 0); + } +#endif +} + - (BOOL)fsIsNative { return fs_is_native; @@ -7904,10 +7963,17 @@ - (void)updateCollectionBehavior { NSWindow *win = [self window]; NSWindowCollectionBehavior b = [win collectionBehavior]; - if (ns_use_native_fullscreen) - b |= NSWindowCollectionBehaviorFullScreenPrimary; - else + if (ns_use_native_fullscreen) { + if ([win parentWindow]) { + b &= ~NSWindowCollectionBehaviorFullScreenPrimary; + b |= NSWindowCollectionBehaviorFullScreenAuxiliary; + } else { + b |= NSWindowCollectionBehaviorFullScreenPrimary; + b &= ~NSWindowCollectionBehaviorFullScreenAuxiliary; + } + } else { b &= ~NSWindowCollectionBehaviorFullScreenPrimary; + } [win setCollectionBehavior: b]; #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 @@ -7932,9 +7998,14 @@ - (void)toggleFullScreen: (id)sender { #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 - if ([[self window] respondsToSelector: @selector(toggleFullScreen:)]) + if ([[self window] respondsToSelector: @selector(toggleFullScreen:)]){ #endif [[self window] toggleFullScreen:sender]; + // wait for fullscreen animation complete (bug#28496) + [self waitFullScreenTransition]; +#endif +#if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 + } #endif return; } --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Feb 20 18:23:18 2020 Received: (at 36672) by debbugs.gnu.org; 20 Feb 2020 23:23:18 +0000 Received: from localhost ([127.0.0.1]:46075 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j4vA6-0003zA-7l for submit@debbugs.gnu.org; Thu, 20 Feb 2020 18:23:18 -0500 Received: from mail-wm1-f44.google.com ([209.85.128.44]:52139) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j4vA4-0003yt-NF for 36672@debbugs.gnu.org; Thu, 20 Feb 2020 18:23:17 -0500 Received: by mail-wm1-f44.google.com with SMTP id t23so331836wmi.1 for <36672@debbugs.gnu.org>; Thu, 20 Feb 2020 15:23:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to; bh=WYZK6R+9y146YZuOfnIYBsl2up0IookscgyFAeb58LQ=; b=TnT7xz64DRoUnWXbMrrEUsTBqD1PUr1/iOf8qjWTSShNMdkdtCbWrrqx9yHsG73hVe JHbjSbmLZMPPv75KcOJzNzUYvRdg46F+faVjI5Tt6sBiSxcqhO6EjT95N+jA/Ml2Fv5M HvQCuq5xnWYrbQTE869XK4854O4HGgEIFIrx6ck4a7K7io1dRYwTy7Eeldj74fHY3Qdc 5i3zLzDzzuGSbGFon6W2Dy0AewAz6Jmdn1X29YKU+MdeIjdsmml2k3f+2EL2Tc5lwutc 6pM7wuglT8Jy6TTH9uhDhsFnZwps/Z6LSYsVm7wnDLGLLKtFiF/88NDYbvd2je3fpv1A ZqeQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition :content-transfer-encoding:in-reply-to; bh=WYZK6R+9y146YZuOfnIYBsl2up0IookscgyFAeb58LQ=; b=JR0boPwjqnf4X70Xhvtr3qfAfZQsSARbL9uOC3dsXsPU39UGWUITndX21SEnXWnPhE 17AVgVY0epKaffvMRsgfkJJRJ9WHVL+RnbdwFP3lPUeDMpOL8Tnmxgnp6DOZvkg+3he9 NcbdnyN1m6VZJsFyMcZqxt6/X7NIrZFW9mZCfBtcn4XBmR4puo0ace63NMmH5o5UmWTV gYr9u+SqwwuQwEi1YqER7oPu/rIOtnK+sFnkK7wNfPwAsyRrEpNyN9e4v8l6picIhyZT U4+ruOkU14/FV915XcgpUmtfoRjxfEzS8jglpufVIN1y6QHw4R3EH0Dr7A5/YtGKRTlX KjqQ== X-Gm-Message-State: APjAAAVVDRlv3gdlRfbCdQwMqe9TVduDGMRodlUtVY49DqD8dnrFRZvJ fuxsf1oiICCiWE7bNRz5+/A= X-Google-Smtp-Source: APXvYqxVK4BqfN00fpNcK0MZX5od7H/A2RvQBeQUrSCYe+Yf/7LDJTQjGud/ZrgOixEqbZmezxv1XQ== X-Received: by 2002:a1c:1c7:: with SMTP id 190mr6815548wmb.121.1582240991095; Thu, 20 Feb 2020 15:23:11 -0800 (PST) Received: from breton.holly.idiocy.org (ip6-2001-08b0-03f8-8129-8996-8c22-b40f-230f.holly.idiocy.org. [2001:8b0:3f8:8129:8996:8c22:b40f:230f]) by smtp.gmail.com with ESMTPSA id q9sm1407508wrx.18.2020.02.20.15.23.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 20 Feb 2020 15:23:10 -0800 (PST) Date: Thu, 20 Feb 2020 23:23:08 +0000 From: Alan Third To: Andrii Kolomoiets Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Message-ID: <20200220232308.GB49343@breton.holly.idiocy.org> References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Score: 0.5 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.5 (/) On Fri, Feb 14, 2020 at 10:23:22AM +0200, Andrii Kolomoiets wrote: > Andrii Kolomoiets writes: > > >> On Jul 16, 2019, at 22:28, Alan Third wrote: > >> > >> The patch looks good to me, but lets see if we can find solutions to > >> these other issues. > > > > I made some progress on this issue. > > > > The idea is to wait for fullscreen transition to complete: > > - Set property isFullScreenTransition on windowWillEnterFullScreen and > > windowWillExitFullScreen events; > > - Clear that property on windowDidEnterFullScreen and > > windowDidExitFullScreen events; > > - Wait for property to be cleared when we need to. > > Updated patch to work with latest master Sorry for the delay, I’ll try and get a look this weekend. -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 01 11:16:18 2020 Received: (at 36672) by debbugs.gnu.org; 1 Mar 2020 16:16:18 +0000 Received: from localhost ([127.0.0.1]:36878 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j8RGM-0006lE-5d for submit@debbugs.gnu.org; Sun, 01 Mar 2020 11:16:18 -0500 Received: from mailout-l3b-97.contactoffice.com ([212.3.242.97]:40718) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j8RGK-0006l0-Lw for 36672@debbugs.gnu.org; Sun, 01 Mar 2020 11:16:17 -0500 Received: from smtpauth1.co-bxl (smtpauth1.co-bxl [10.2.0.15]) by mailout-l3b-97.contactoffice.com (Postfix) with ESMTP id 278251B21; Sun, 1 Mar 2020 17:16:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1583079370; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To; l=2830; bh=tVG9RgIbb/rVaVh7h2nBEdXw/dVLOtNp9l9E1inb22M=; b=mux5hCKHVybSlJV4vdzXNvnkXCiA1f0iYR29op9l5ndb2ghPYtHBygyxTdOs50nW TZPms8mLS3LmZH9nEBdg+Rh2B5+/vCl5nM6MnqQ9avM7ALNZ1eI7Q++etb1+57xLP64 hlUGbzHieea5beSKQ4/kugdm341tLMfVdauMqAX3JZ4nQ/6gZ19LjS6LCN0nKuogNVZ ssEC/t6UTHK+DkJYex4mUbR4NYMI5T1ptVAQeCgKr+DUsEMGeoLhZSzIk9jBqaa+xqa OeF6iZKBBAzQ2a4DuolDCMyvIU0Z4xmJu7SW9dp4hRg5chhW4T5NwSzmauySExhQE2Z xycsSxilVQ== Received: by smtp.mailfence.com with ESMTPA ; Sun, 1 Mar 2020 17:16:06 +0100 (CET) Received: by idiocy.org (Postfix, from userid 501) id 40AD8201FE1C4D; Sun, 1 Mar 2020 16:16:05 +0000 (GMT) Date: Sun, 1 Mar 2020 17:16:08 +0100 (CET) From: Alan Third To: Andrii Kolomoiets Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Message-ID: <20200301161605.GA8290@breton.holly.idiocy.org> References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.1 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Fri, Feb 14, 2020 at 10:23:22AM +0200, Andrii Kolomoiets wrote: > Andrii Kolomoiets writes: > > >> On Jul 16, 2019, at 22:28, Alan Third wrote: > >> > >> The patch looks good to me, but lets see if we can find solutions to > >> these other issues. > > > > I made some progress on this issue. > > > > The idea is to wait for fullscreen transition to complete: > > - Set property isFullScreenTransition on windowWillEnterFullScreen and > > windowWillExitFullScreen events; > > - Clear that property on windowDidEnterFullScreen and > > windowDidExitFullScreen events; > > - Wait for property to be cleared when we need to. > > Updated patch to work with latest master Thanks! This looks much better than what we had before. No crashes for one! A few nitpicks: > + BOOL is_fullscreen_transition; I may be misunderstanding this, but would ‘in_fullscreen_transition’ be a better name? > +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 > + // child frame must not be in fullscreen > + if ([view fsIsNative] && [view isFullscreen]){ Opening braces go on a new line. > +- (void)waitFullScreenTransition > +{ > +#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 > + while ([self isFullScreenTransition]){ Opening brace, again. > - (BOOL)fsIsNative > { > return fs_is_native; > @@ -7904,10 +7963,17 @@ - (void)updateCollectionBehavior > { > NSWindow *win = [self window]; > NSWindowCollectionBehavior b = [win collectionBehavior]; > - if (ns_use_native_fullscreen) > - b |= NSWindowCollectionBehaviorFullScreenPrimary; > - else > + if (ns_use_native_fullscreen) { > + if ([win parentWindow]) { > + b &= ~NSWindowCollectionBehaviorFullScreenPrimary; > + b |= NSWindowCollectionBehaviorFullScreenAuxiliary; > + } else { > + b |= NSWindowCollectionBehaviorFullScreenPrimary; > + b &= ~NSWindowCollectionBehaviorFullScreenAuxiliary; > + } > + } else { > b &= ~NSWindowCollectionBehaviorFullScreenPrimary; > + } And again. That ‘} else {’ should also be over three lines. > #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 > @@ -7932,9 +7998,14 @@ - (void)toggleFullScreen: (id)sender > { > #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 > #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 > - if ([[self window] respondsToSelector: @selector(toggleFullScreen:)]) > + if ([[self window] respondsToSelector: @selector(toggleFullScreen:)]){ > #endif > [[self window] toggleFullScreen:sender]; > + // wait for fullscreen animation complete (bug#28496) > + [self waitFullScreenTransition]; > +#endif > +#if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 > + } > #endif > return; > } Should that final #if #endif not be within the outer #if #endif? And the opening brace again. -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 10 04:42:23 2020 Received: (at 36672) by debbugs.gnu.org; 10 Mar 2020 08:42:23 +0000 Received: from localhost ([127.0.0.1]:51822 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jBaT0-00028J-Tp for submit@debbugs.gnu.org; Tue, 10 Mar 2020 04:42:23 -0400 Received: from mail-lf1-f44.google.com ([209.85.167.44]:42940) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jBaSy-000285-Iu for 36672@debbugs.gnu.org; Tue, 10 Mar 2020 04:42:21 -0400 Received: by mail-lf1-f44.google.com with SMTP id t21so10121862lfe.9 for <36672@debbugs.gnu.org>; Tue, 10 Mar 2020 01:42:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=OJ23412HPwjYe5kY+5pFR+fKKzXBsKt53UVYrAINFRY=; b=ItcjRvLaKFkMwQ8YsNprVVD0xxyW2yPkiy1WMY9wIMh6FGuXJmAgf+cuDUtWEdmwU1 K01hPGjDaCSJjzyoWgYgUqa3sVWAKpNIBTnfK3l8qD1DAGpAgZJwf49esWI8Zs+1q41S MqJzNSebx1Hdw7QxOiT3ZQX8mnYmnnevzKDZXrKhyKGod46DLuSrLCL8fQbdUTmQadHp LKchK8oS7mk0Z2y9BI3rvqJIyhnLYu93A0eAFnF3+w4fEKlXpUWLxKyDMZsSIYONVOxR 6DTF5iVb01uOJEmT/JPF4FQvb6CLEYHI6MsTozJbA3naXYj8KoaAZJkRfnf/Sf1+mmRr h4cQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=OJ23412HPwjYe5kY+5pFR+fKKzXBsKt53UVYrAINFRY=; b=APsgURZb23vA2vp683jHvDD5bQDEnBq8bIqr2C3LQ4Uxmpr/GSdL/auEkiR5phzj/s XN8uMEgPIy+rWKbJLijLYTS3okmmrGxdDWY37sJ5EjH6k2qx9zuSDpWfV0F2WLzmqY5B KmzV2ue7wDJaamy3XnaVI4g/5wFTLrBP+x8W1+fZJjeYRFzleBWVuKAn4EWF9Y+nQEp+ 2T/b49AXcuL6meddAiPGvZfZUk0zyBruqYrByb+sdMvAiezNj9SFF2723wPzZyvM90XO j6A1t/z1Oqd3uAhHqwRU1AfDhAbvf07TaedeFU90eoi1EQes3XYk280ah+VErgBvbYvr soiA== X-Gm-Message-State: ANhLgQ3J5Irfp2aXfyZVKXqN/C0PlnjsllKlp5y39uytTrQ6FNmDZi2r JXMGICak1xV/iQdbfXKZ4lIvM/Qf X-Google-Smtp-Source: ADFU+vte1yQwUIKuykuKEpD+N6xuGHllR8bVGR89YpxmB0vW5i6O8wZcJKH2teht0x1wjwzx0ACh2w== X-Received: by 2002:a19:9d2:: with SMTP id 201mr12074043lfj.159.1583829734025; Tue, 10 Mar 2020 01:42:14 -0700 (PDT) Received: from 10-1-1-147.office.area (188-42-207-82.ip.ukrtel.net. [82.207.42.188]) by smtp.gmail.com with ESMTPSA id e2sm21313920ljp.55.2020.03.10.01.42.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Mar 2020 01:42:12 -0700 (PDT) From: Andrii Kolomoiets To: Alan Third Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> Date: Tue, 10 Mar 2020 10:42:11 +0200 In-Reply-To: <20200301161605.GA8290@breton.holly.idiocy.org> (Alan Third's message of "Sun, 1 Mar 2020 17:16:08 +0100 (CET)") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (darwin) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 36672 Cc: 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Alan Third writes: > Thanks! This looks much better than what we had before. No crashes for > one! > > A few nitpicks: > >> + BOOL is_fullscreen_transition; > > I may be misunderstanding this, but would =E2=80=98in_fullscreen_transiti= on=E2=80=99 > be a better name? OK, renamed.=20 > Opening braces go on a new line. Braces style is fixed to match Emacs code style. > And again. That =E2=80=98} else {=E2=80=99 should also be over three line= s. > >> #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 >> @@ -7932,9 +7998,14 @@ - (void)toggleFullScreen: (id)sender >> { >> #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >=3D 1070 >> #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 >> - if ([[self window] respondsToSelector: @selector(toggleFullScreen= :)]) >> + if ([[self window] respondsToSelector: @selector(toggleFullScreen= :)]){ >> #endif >> [[self window] toggleFullScreen:sender]; >> + // wait for fullscreen animation complete (bug#28496) >> + [self waitFullScreenTransition]; >> +#endif >> +#if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 >> + } >> #endif >> return; >> } > > Should that final #if #endif not be within the outer #if #endif? Yes. Fixed. Thanks! Please see attached patch. Log message is also provided. --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-NS-child-frame-in-native-fullscreen.patch >From a9705617188c9a5ef77a8f2d5cc796b86dda9fa6 Mon Sep 17 00:00:00 2001 From: Andrii Kolomoiets Date: Tue, 10 Mar 2020 10:14:59 +0200 Subject: [PATCH] NS child frame in native fullscreen * lisp/frame.el (toggle-frame-fullscreen): Don't sleep on cocoa. Fullscreen animation waiting is moved to src/nsterm.m. * src/nsterm.h (EmacsView): Add in_fullscreen_transition, inFullScreenTransition, waitFullScreenTransition. (NSWindowCollectionBehaviorFullScreenAuxiliary): New define. * src/nsterm.m (ns_make_frame_visible): Wait for fullscreen animation. (ns_set_parent_frame): Set frame collection behavior; make child frames non-fullscreen; make non-child frames fullscreen if parent was fullscreen. ([EmacsView initFrameFromEmacs]): Set in_fullscreen_transition; set frame collection behavior according to parent frame. ([EmacsView windowDidMove]): Remove code by commenting with "fixme". ([EmacsView windowWillEnterFullScreen], [EmacsView windowDidEnterFullScreen]) ([EmacsView windowWillExitFullScreen], [EmacsView windowDidExitFullScreen]): Set in_fullscreen_transition. ([EmacsView inFullScreenTransition], [EmacsView waitFullScreenTransition]): New methods. ([EmacsView updateCollectionBehavior]): Set collection behavior according to parent frame. ([EmacsView toggleFullScreen]): Wait for fullscreen animation. --- lisp/frame.el | 6 +--- src/nsterm.h | 4 +++ src/nsterm.m | 107 +++++++++++++++++++++++++++++++++++++++++++++++++++------- 3 files changed, 100 insertions(+), 17 deletions(-) diff --git a/lisp/frame.el b/lisp/frame.el index 16ee7580f8..7ed3e23f3c 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -2676,11 +2676,7 @@ toggle-frame-fullscreen (set-frame-parameter frame 'fullscreen fullscreen-restore) (set-frame-parameter frame 'fullscreen nil))) (modify-frame-parameters - frame `((fullscreen . fullboth) (fullscreen-restore . ,fullscreen)))) - ;; Manipulating a frame without waiting for the fullscreen - ;; animation to complete can cause a crash, or other unexpected - ;; behavior, on macOS (bug#28496). - (when (featurep 'cocoa) (sleep-for 0.5)))) + frame `((fullscreen . fullboth) (fullscreen-restore . ,fullscreen)))))) ;;;; Key bindings diff --git a/src/nsterm.h b/src/nsterm.h index db966e1581..8396a542f7 100644 --- a/src/nsterm.h +++ b/src/nsterm.h @@ -433,6 +433,7 @@ #define NS_DRAW_TO_BUFFER 1 int maximized_width, maximized_height; NSWindow *nonfs_window; BOOL fs_is_native; + BOOL in_fullscreen_transition; #ifdef NS_DRAW_TO_BUFFER CGContextRef drawingBuffer; #endif @@ -467,6 +468,8 @@ #define NS_DRAW_TO_BUFFER 1 - (void) toggleFullScreen: (id) sender; - (BOOL) fsIsNative; - (BOOL) isFullscreen; +- (BOOL) inFullScreenTransition; +- (void) waitFullScreenTransition; #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 - (void) updateCollectionBehavior; #endif @@ -1286,6 +1289,7 @@ #define SCREENMAXBOUND(x) (IN_BOUND (-SCREENMAX, x, SCREENMAX)) #if !defined (NS_IMPL_COCOA) || !defined (MAC_OS_X_VERSION_10_7) #define NSFullScreenWindowMask (1 << 14) #define NSWindowCollectionBehaviorFullScreenPrimary (1 << 7) +#define NSWindowCollectionBehaviorFullScreenAuxiliary (1 << 8) #define NSApplicationPresentationFullScreen (1 << 10) #define NSApplicationPresentationAutoHideToolbar (1 << 11) #define NSAppKitVersionNumber10_7 1138 diff --git a/src/nsterm.m b/src/nsterm.m index 851a5617d7..96a7fdc018 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -1571,9 +1571,12 @@ -(void)remove /* Making a new frame from a fullscreen frame will make the new frame fullscreen also. So skip handleFS as this will print an error. */ - if ([view fsIsNative] && f->want_fullscreen == FULLSCREEN_BOTH - && [view isFullscreen]) - return; + if ([view fsIsNative] && [view isFullscreen]) + { + // maybe it is not necessary to wait + [view waitFullScreenTransition]; + return; + } if (f->want_fullscreen != FULLSCREEN_NONE) { @@ -1959,19 +1962,55 @@ so some key presses (TAB) are swallowed by the system. */ block_input (); child = [FRAME_NS_VIEW (f) window]; +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + EmacsView *view = (EmacsView *)FRAME_NS_VIEW (f); +#endif + if ([child parentWindow] != nil) { +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + parent = [child parentWindow]; +#endif + [[child parentWindow] removeChildWindow:child]; #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101000 #if MAC_OS_X_VERSION_MIN_REQUIRED < 101000 if ([child respondsToSelector:@selector(setAccessibilitySubrole:)]) #endif [child setAccessibilitySubrole:NSAccessibilityStandardWindowSubrole]; +#endif +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + if (NILP (new_value)) + { + NSTRACE ("child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary"); + [child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; + // if current parent in fullscreen and no new parent make child fullscreen + while (parent) { + if (([parent styleMask] & NSWindowStyleMaskFullScreen) != 0) + { + [view toggleFullScreen:child]; + break; + } + // check all parents + parent = [parent parentWindow]; + } + } #endif } if (!NILP (new_value)) { +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + // child frame must not be in fullscreen + if ([view fsIsNative] && [view isFullscreen]) + { + // in case child is going fullscreen + [view waitFullScreenTransition]; + [view toggleFullScreen:child]; + } + NSTRACE ("child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary"); + [child setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary]; +#endif parent = [FRAME_NS_VIEW (p) window]; [parent addChildWindow: child @@ -7398,6 +7437,7 @@ - (instancetype) initFrameFromEmacs: (struct frame *)f #endif fs_is_native = ns_use_native_fullscreen; #endif + in_fullscreen_transition = NO; maximized_width = maximized_height = -1; nonfs_window = nil; @@ -7431,7 +7471,10 @@ - (instancetype) initFrameFromEmacs: (struct frame *)f #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 if (NSAppKitVersionNumber >= NSAppKitVersionNumber10_7) #endif - [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; + if (FRAME_PARENT_FRAME (f)) + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenAuxiliary]; + else + [win setCollectionBehavior:NSWindowCollectionBehaviorFullScreenPrimary]; #endif wr = [win frame]; @@ -7554,11 +7597,12 @@ - (void)windowDidMove: sender emacsframe->top_pos = NS_PARENT_WINDOW_TOP_POS (emacsframe) - (r.origin.y + r.size.height); - if (emacs_event) - { - emacs_event->kind = MOVE_FRAME_EVENT; - EV_TRAILER ((id)nil); - } + // FIXME: after event part below didExitFullScreen is not received + // if (emacs_event) + // { + // emacs_event->kind = MOVE_FRAME_EVENT; + // EV_TRAILER ((id)nil); + // } } } @@ -7758,6 +7802,7 @@ - (NSApplicationPresentationOptions)window:(NSWindow *)window - (void)windowWillEnterFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowWillEnterFullScreen:]"); + in_fullscreen_transition = YES; [self windowWillEnterFullScreen]; } - (void)windowWillEnterFullScreen /* provided for direct calls */ @@ -7770,6 +7815,7 @@ - (void)windowDidEnterFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowDidEnterFullScreen:]"); [self windowDidEnterFullScreen]; + in_fullscreen_transition = NO; } - (void)windowDidEnterFullScreen /* provided for direct calls */ @@ -7808,6 +7854,7 @@ - (void)windowDidEnterFullScreen /* provided for direct calls */ - (void)windowWillExitFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowWillExitFullScreen:]"); + in_fullscreen_transition = YES; [self windowWillExitFullScreen]; } @@ -7827,6 +7874,7 @@ - (void)windowDidExitFullScreen:(NSNotification *)notification { NSTRACE ("[EmacsView windowDidExitFullScreen:]"); [self windowDidExitFullScreen]; + in_fullscreen_transition = NO; } - (void)windowDidExitFullScreen /* provided for direct calls */ @@ -7856,6 +7904,22 @@ - (void)windowDidExitFullScreen /* provided for direct calls */ [[self window] performZoom:self]; } +- (BOOL)inFullScreenTransition +{ + return in_fullscreen_transition; +} + +- (void)waitFullScreenTransition +{ +#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 + while ([self inFullScreenTransition]) + { + NSTRACE ("wait for fullscreen"); + wait_reading_process_output (0, 300000000, 0, 1, Qnil, NULL, 0); + } +#endif +} + - (BOOL)fsIsNative { return fs_is_native; @@ -7894,9 +7958,22 @@ - (void)updateCollectionBehavior NSWindow *win = [self window]; NSWindowCollectionBehavior b = [win collectionBehavior]; if (ns_use_native_fullscreen) - b |= NSWindowCollectionBehaviorFullScreenPrimary; + { + if ([win parentWindow]) + { + b &= ~NSWindowCollectionBehaviorFullScreenPrimary; + b |= NSWindowCollectionBehaviorFullScreenAuxiliary; + } + else + { + b |= NSWindowCollectionBehaviorFullScreenPrimary; + b &= ~NSWindowCollectionBehaviorFullScreenAuxiliary; + } + } else - b &= ~NSWindowCollectionBehaviorFullScreenPrimary; + { + b &= ~NSWindowCollectionBehaviorFullScreenPrimary; + } [win setCollectionBehavior: b]; #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 @@ -7922,8 +7999,14 @@ - (void)toggleFullScreen: (id)sender #if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 #if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 if ([[self window] respondsToSelector: @selector(toggleFullScreen:)]) + { +#endif + [[self window] toggleFullScreen:sender]; + // wait for fullscreen animation complete (bug#28496) + [self waitFullScreenTransition]; +#if MAC_OS_X_VERSION_MIN_REQUIRED < 1070 + } #endif - [[self window] toggleFullScreen:sender]; #endif return; } -- 2.15.1 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 12 19:27:18 2020 Received: (at 36672-done) by debbugs.gnu.org; 12 Mar 2020 23:27:18 +0000 Received: from localhost ([127.0.0.1]:57933 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCXET-0006IN-S6 for submit@debbugs.gnu.org; Thu, 12 Mar 2020 19:27:18 -0400 Received: from mailout-l3b-97.contactoffice.com ([212.3.242.97]:33112) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCXES-0006I6-Ga for 36672-done@debbugs.gnu.org; Thu, 12 Mar 2020 19:27:16 -0400 Received: from smtpauth1.co-bxl (smtpauth1.co-bxl [10.2.0.15]) by mailout-l3b-97.contactoffice.com (Postfix) with ESMTP id 2BC2C34AA; Fri, 13 Mar 2020 00:27:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1584055630; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:In-Reply-To; l=253; bh=Bj+JpelHvAKF7sMkp0lYazWcYkgSmZqf3enzO9KK+rI=; b=UNF52C06Ya7IRr7oJVfNfWQl3meyGkPEkpYB4aYH366oI42X7Aka1p3uUHBXGer1 wYfREFoAHuYO2MHE2N09xrr5pd9+VLdcUj1ebQMgXVdwvoWpxAsnJ0od2PZFE2YTIwc fOutB9U2+vst+yLipWuqRJDuhlaLCZ9rolmvNAR+OcT8OTumSK2QyPLF97ALsnxzMmp euzeHDOZhqGMAT2VW+17unfHUYFHbT1jfwkCrV2Glr7V5oR3PXXvRB98dJZvIIyb+/Q 3QJrv0NNfSZj8VeRZIIMLcFbNixWmdXq2xkdIQf65jHg6ae1+vHBrqxjM3S7QTlwzJ2 tysdAGLRSw== Received: by smtp.mailfence.com with ESMTPA ; Fri, 13 Mar 2020 00:27:08 +0100 (CET) Received: by idiocy.org (Postfix, from userid 501) id D61142020316A9; Thu, 12 Mar 2020 23:27:06 +0000 (GMT) Date: Fri, 13 Mar 2020 00:27:09 +0100 (CET) From: Alan Third To: Andrii Kolomoiets Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Message-ID: <20200312232706.GA84518@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , Andrii Kolomoiets , 36672-done@debbugs.gnu.org References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.1 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 36672-done Cc: 36672-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Tue, Mar 10, 2020 at 10:42:11AM +0200, Andrii Kolomoiets wrote: > Please see attached patch. Log message is also provided. This all looks good to me. Pushed to master as bbc48b263485c26c6823eabdbbd7e9af62178e34. Thank you! -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 13 05:39:09 2020 Received: (at 36672-done) by debbugs.gnu.org; 13 Mar 2020 09:39:09 +0000 Received: from localhost ([127.0.0.1]:58158 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCgmb-0003HL-EO for submit@debbugs.gnu.org; Fri, 13 Mar 2020 05:39:09 -0400 Received: from mout.gmx.net ([212.227.17.21]:59149) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCgmY-0003Gh-J0 for 36672-done@debbugs.gnu.org; Fri, 13 Mar 2020 05:39:06 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1584092338; bh=8YLTzlslGAn+qzO8GiHvLMOpsu2v/9jCvRZmI15c70U=; h=X-UI-Sender-Class:Subject:To:References:From:Date:In-Reply-To; b=ZHC/tokOaNVrZAsCkT28BaODPB53K2yVMRejGfYbQ37iEyd9SzWE52bYhyfAToWG1 ZeraT+jeJpJrAyDfUcCz4alcdRd2enL++qDf7rGwmDO3jMNqtXIrx+uKFkA47NmHfz 6xKsNI31IYgkqXJ85JY/jEh1PKUrHtb2mfSindZA= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.1.101] ([46.125.249.120]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1N7zFj-1jP9Tl1eUN-014zat; Fri, 13 Mar 2020 10:38:58 +0100 Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space To: Alan Third , Andrii Kolomoiets , 36672-done@debbugs.gnu.org References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> <20200312232706.GA84518@breton.holly.idiocy.org> From: martin rudalics Message-ID: <96e82dad-b72f-d8c5-29d4-4e02d9bb127b@gmx.at> Date: Fri, 13 Mar 2020 10:38:57 +0100 MIME-Version: 1.0 In-Reply-To: <20200312232706.GA84518@breton.holly.idiocy.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:di1MSnKuIrmBYTp808JGOq9H0r+8iuPQmy+8azsyWspruW3u5su 5L5olltN2gWG1AXE8df6VIAHd6Rt3Hninv4PMtpUSJUTm5T9sPKikxaFou62olkIVqt8C7D zzKYLNhW7rQciz8GoocWXvo8GsSKtX9yF/qPZzfrTQTnaaaUuIz19ggsIOArFILr27y3Bmp QGPg1f0rWMveGCC5ITDhg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:qQecgkp5Rtc=:IfH6L7bVmUevuPzWp64B8t jf97pxeye7kxVIijQTd7SrRQM4aGtrAAIDZq0p/M8Bb9atT0aR3x7DXAuJgOXwoGmioxgbh2n ulCycrrOV1ISin8UldBeXidrx62qI1GHHbnd1eayWGnI0Ld0Xa1SZobCJJ17ozrNJw1u1HbgM jClPjpqLgISS9in5P1mfCDhVKpz9l/qB8fOOuRD3tk7gpmaLeS3CvcVuA61aBq5EdzQ7juLFN cZ9Y7oaCZzZ4p95UDGP1Sm009sjFEnmC1ceol6UiHWri3hhF4Yr19FVRyTd3+iHAdm3+CRsGQ 6UQzRx1JISF68qBIl4gKJW5PE3zzDcR5sNHbZ5Ha5+f83KWa4y/j296RbxVWBCw7w/cjgN9cT 3qf3e+G+2JYsMBEoel3VvM6fa1XCYDqYVeC11nYfXNeT5/8gr+HT5PC/zlD7Q4fR1WmexHbPc p3mgLVgGFtA7ldRyqh8TFnxWv2Fw0ASK3wjdi3gU+23JzHobfv9cMZ81AYqTHJoUSd9w10oSi alq5yVaC0CwToMIITSTx5oL/pPJX6DSTw7gzIG6IidO3cU1zITAa/LX9r1CXEJRkzwHfQPxa5 kb1+g2uDCS/V3GxQQ0TNnQe6BCLp+XaXl+lXbStXVBJT0Vjr6P/ctIL5ZiCmhe8eIkdEQ96p8 59246sBOiffu1o/f+QeqzhFKSE0Q9UtmhBnVUvAOPI6WKkz1XDe023w0y8tm+sHkRGulA/cz/ CWReDIpAJlb44moyPLHHlk3ErUom3pDmIKblviWZbARxaEycEcGONiL5io7rG830jee2itujY B2kLBNwMAYqW51rPDVR6sqDYvzYdozSFfN+fT3cp/16VU6fVJmM0RrC9jMYvj/FGOMxn3ipRH C0EywRV5zLzWSFUlLmkzTHZYU96ezcF1xJ0iG7iumJV+7teBVb3xyRQKmPP7kBTHfZp0DL+PP oTxuIiY22uDcPjAwj2Ev08y3rcWAE50+BQCADsu50sXA2ii4TnpMghFIr0CLB/4Sv4Vt4AnXY 0M1sXNPVWX3pqqreGmTtgyYQRQS/Augxh8W2HLnfyLAdIttrCi1+xJz80e1zZenu+8X4VX1h6 cODZtbxMbAMaTcfudfE2f1yEN8L5i3zFaIPQ6udSQbZGFp4T4+ts+zQIAh/WGkVcMfpDbrnNs YdxCNE746pnzTtTcNn77lxOjqAuCisV6SolmXaes64Qep7+OEg78jtn3u9Pc8hsz6caJpWuu1 KQyZO2JRJSd2tSPqL X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: 36672-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.2 (/) > This all looks good to me. Pushed to master as > bbc48b263485c26c6823eabdbbd7e9af62178e34. Alan, one child frame related question: When I specify a child frame in a GNUstep build and move its parent frame around, the child frame does _not_ move along with the parent but keeps its old position on the display. However, clicking into that child frame with the mouse afterwards, moves it to its previous location within the parent frame. Is this behavior observable with other NS builds? Thanks, martin From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 13 11:13:42 2020 Received: (at 36672) by debbugs.gnu.org; 13 Mar 2020 15:13:42 +0000 Received: from localhost ([127.0.0.1]:60147 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCm0L-00068H-SK for submit@debbugs.gnu.org; Fri, 13 Mar 2020 11:13:42 -0400 Received: from mailout-l3b-97.contactoffice.com ([212.3.242.97]:37248) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCm0I-000682-Vb for 36672@debbugs.gnu.org; Fri, 13 Mar 2020 11:13:39 -0400 Received: from smtpauth1.co-bxl (smtpauth1.co-bxl [10.2.0.15]) by mailout-l3b-97.contactoffice.com (Postfix) with ESMTP id 997AE81; Fri, 13 Mar 2020 16:13:32 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1584112412; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To; l=956; bh=wSt5331AYM6rQULo7sGFBMq3jZxY7ziYZWl9PPSNXzQ=; b=LnHhOiFDkUZGT0vdf6Umr23sw2CuGnOcmzdSAhjDFE2xxmNCLtdCBcsUq6WkgIyR EFAvRQ6UyY2eq420woXCEGbM1+pYvNND30nZsCntJPh8LbK8Y9wKA4nJaaDRJD2YLj/ 7tkiyYmrCZ7RgxaM2vOWIwqWBgaQvk7FDYnrTO2gMmhFRF0yppOmbxQyoJ85r862T5u Qm9XRha+tnAmyKfBXDU4MTF3qisCo6jvtfdzViWg0iya6DuwsH06wkuhyZa62pGd/Qf wwnKEWjUmgU6GCwbF4zWMUGmXyYt94knSF2l7s0Sb9kCb38y/g+mW/UKcLI4nA1OJ7y OzCzPsmzeg== Received: by smtp.mailfence.com with ESMTPA ; Fri, 13 Mar 2020 16:13:26 +0100 (CET) Received: by idiocy.org (Postfix, from userid 501) id 762EC20203600C; Fri, 13 Mar 2020 15:13:22 +0000 (GMT) Date: Fri, 13 Mar 2020 16:13:27 +0100 (CET) From: Alan Third To: martin rudalics Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Message-ID: <20200313151322.GA2905@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , martin rudalics , Andrii Kolomoiets , 36672@debbugs.gnu.org References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> <20200312232706.GA84518@breton.holly.idiocy.org> <96e82dad-b72f-d8c5-29d4-4e02d9bb127b@gmx.at> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <96e82dad-b72f-d8c5-29d4-4e02d9bb127b@gmx.at> X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.20 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 36672 Cc: Andrii Kolomoiets , 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Fri, Mar 13, 2020 at 10:38:57AM +0100, martin rudalics wrote: > > This all looks good to me. Pushed to master as > > bbc48b263485c26c6823eabdbbd7e9af62178e34. > > Alan, one child frame related question: When I specify a child frame in > a GNUstep build and move its parent frame around, the child frame does > _not_ move along with the parent but keeps its old position on the > display. However, clicking into that child frame with the mouse > afterwards, moves it to its previous location within the parent frame. > Is this behavior observable with other NS builds? On macOS the child windows move with the parent. I thought GNUstep worked that way too, but in my own experiments I can’t get them to move at all, even with clicking in the windows like you’re doing. I just tried an ancient build and it doesn’t work there, so I guess this has probably never worked right. I wonder if support is a WM thing? -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 13 12:29:27 2020 Received: (at 36672) by debbugs.gnu.org; 13 Mar 2020 16:29:27 +0000 Received: from localhost ([127.0.0.1]:60182 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCnBe-0008AT-VJ for submit@debbugs.gnu.org; Fri, 13 Mar 2020 12:29:27 -0400 Received: from mout.gmx.net ([212.227.15.18]:36881) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCnBd-0008AH-Vx for 36672@debbugs.gnu.org; Fri, 13 Mar 2020 12:29:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1584116958; bh=puPWG9FessXYlYfMoZQ3bpPtn0viwDDGp/4Jhytba6s=; h=X-UI-Sender-Class:Subject:To:References:From:Date:In-Reply-To; b=P/GWF+08wHotVv4ExfsLQQ9qEshWjtSAlJozjwtkTzZchPv889bcCQtk7vOM7JMMs P5lW60ut81d139z4CeGomRYtsm7/UorCXxJVvZI5TLMPdQ+YZPIV4PNcAGlFnhnivQ M+52oqM+G6FYK7ePAXCgWagnJq6HXsUZuAZUMIrY= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.1.101] ([46.125.249.120]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1Md6Mj-1jl1wM3L9P-00aCM6; Fri, 13 Mar 2020 17:29:17 +0100 Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space To: Alan Third , Andrii Kolomoiets , 36672@debbugs.gnu.org References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> <20200312232706.GA84518@breton.holly.idiocy.org> <96e82dad-b72f-d8c5-29d4-4e02d9bb127b@gmx.at> <20200313151322.GA2905@breton.holly.idiocy.org> From: martin rudalics Message-ID: <72f46966-46a1-f470-18ff-9ba1ff5ad5db@gmx.at> Date: Fri, 13 Mar 2020 17:29:17 +0100 MIME-Version: 1.0 In-Reply-To: <20200313151322.GA2905@breton.holly.idiocy.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:qEoDdzdY4uQqhnzxa5bNgIiRkF3KGgm/zoEQDB1HTlgQYRDGZkj sMUTFl4mDEo0ySL1ZJgqGwplY2VleXSD1THq1kPB51LfLBVEG34U0emcM8FLfedxnMtAYPB Tsr4y1eLXwlOEgVfYxkXbErBJMmKaX8xxzvH0xDnit/g2n2PoNl0bZIzOahbjVUtbcz+cGG t63GjIuddm6yI3sflY/Mw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:OEcGk3fCems=:8cBnI2EJqkleGLA47dW+mK BcRj9b/FR8Pk8iS1UjmWSF2bRFq0I1qObxQNWT2wF+mDXCoNemlTzoClzg5yMbskH/Sl9VWvK 07ULKtGBNXW2iNiqprzh0ntxLrg3TBt93KXtMYDBEh8ZnwmoDIHpxtHPJOSmP7ZO1EdpKN10G k9T55We2FHSLNCMEBlDUKNtvhNw0+ubOYP5VCaxwa3k8wohdJ/Kegu8k02KACv4ghh4LRvXwD lcwMgh28uJPu5XuLwdiuFxTieB2tFcT52/JNsIW3PSmbuaPNY+2pJ83pDEOveUb3is6vUA8Ph 159Yd+cB+Sh/H9ti3tuUr/b3+zrrs7W0rWPvHvcsgC+uympU/5sdYB+6Ygf8fsQpDqwHewBUJ dUICvJU6B3dC2aq/SaREtrp7qY8Jp0q6EWbwflpesukVc524U+X036FOJq9SGfDrwUUcHGna9 8FrA1XEWDHGPv0VLFspXBndgjHUPirgWhkSZerPrlAmlDh/XZQKIdY5tztF/Y++LoPg/QfHCQ CG4pZU+9hGMDsOLTygjaUeUY/uHJcZkuvV32Wga+2uvtYWr3T6X0ED3aH1gX7uld0dwoq6O+E ZYn7U7uYmJBb1OKKb8YWi0VXFDw9PptrxYeFe7DEpzlXmvdK0+iO1atp/gpbXUEwNBhTqk3Yv Pf6NwYdVKnzcZcgKr6V+TqphQJ3ROpAes/kW1Pf+VTjVONSBAqW6vGxcX19xuPA3kJ1vGsQsg JwzoZcqrRtRpg3Tb8OAF1tlI0XR64+cGhe2F1OY5Q63xgu5WoG+U0FGZeex2o/WZjBLwWes6a j1HN3dGSWSiGtx6sKiAr95dPs2Gdcagey/9QvjagG806SiroYy8zIR1K7RQNz+yNpivK49KJl wT+Z9xYGcYp4hhT2MzjJQgnWyEtRP9qpeJf7ZzkcySO9A8QE815Dpmj1coqvBcBVWkCNyb8HN thmdaPAf4ScMRRmFp9Lceu/4Ms8C+R8FFdi/Ip2FWEt9YVU6lmrZgfgEIwZPOmztbUk7jQIaQ Yy6ZIkVZ7FwnziKIspg8rYcu6h9p5wVNeiJJQIW09K847Dk/ipZK5gZH4kjdCUpu5jYjNMZmU O6p0eA1uNTu8gYZ2SBstSfE1isRnvft9JEQ6d+Ou4qRYIj9T+7tnK0FjSjoFl0/NTLY/V7qDu I9otZBEuNR7EYrZNxXQvDVKkDgWoT0zwvfJiN+GUADt7PZ6Pol5hkob2tztux4rK9/2w7Q7cZ QtZEX9GATYyVe79mv X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: 36672 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.2 (/) > On macOS the child windows move with the parent. Good. > I thought GNUstep > worked that way too, but in my own experiments I can=E2=80=99t get the= m to > move at all, even with clicking in the windows like you=E2=80=99re doi= ng. Indeed. What I tried was to move the child frame by dragging its mode line. What happens when you call (set-frame-position child-frame x y) for a child frame and some values of x and y? > I just tried an ancient build and it doesn=E2=80=99t work there, so I = guess > this has probably never worked right. > > I wonder if support is a WM thing? Indirectly, maybe. I have to try with window maker later. Thanks, martin From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 13 13:45:32 2020 Received: (at 36672) by debbugs.gnu.org; 13 Mar 2020 17:45:32 +0000 Received: from localhost ([127.0.0.1]:60221 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCoNI-0001n3-8J for submit@debbugs.gnu.org; Fri, 13 Mar 2020 13:45:32 -0400 Received: from mout.gmx.net ([212.227.15.15]:37657) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCoNG-0001mm-9M for 36672@debbugs.gnu.org; Fri, 13 Mar 2020 13:45:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1584121522; bh=euZ5TBmMVznwZPyt/8MZjqAt5u5cuVnJ2Nmkf+14dOk=; h=X-UI-Sender-Class:Subject:From:To:References:Date:In-Reply-To; b=gy7UFJjqVqlPsGSNmaQLyUPCrv+S8TVVjKbZzld1bpWDaefGNe4pRToaOdvodaoZt GgJ5NPoV7EH61aVCI95kxF4skjWoSuxsYciDIaUcUJSfnAjKEWKPg0b7tBTUe4lv4D VVFFBdVNiCbOSpAk1CLvHzLR6QMOqgSTQerMDNl8= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.1.101] ([46.125.249.120]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MN5eR-1ivxwa3K4L-00J5bI; Fri, 13 Mar 2020 18:45:21 +0100 Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space From: martin rudalics To: Alan Third , Andrii Kolomoiets , 36672@debbugs.gnu.org References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> <20200312232706.GA84518@breton.holly.idiocy.org> <96e82dad-b72f-d8c5-29d4-4e02d9bb127b@gmx.at> <20200313151322.GA2905@breton.holly.idiocy.org> <72f46966-46a1-f470-18ff-9ba1ff5ad5db@gmx.at> Message-ID: <007b39b6-5f29-15ab-4b56-5640b82b1eaa@gmx.at> Date: Fri, 13 Mar 2020 18:45:20 +0100 MIME-Version: 1.0 In-Reply-To: <72f46966-46a1-f470-18ff-9ba1ff5ad5db@gmx.at> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:0RAscbsoMHRyiohcwZjZZtYO8tfpuwdszO+WVfjssTynPgAi6Ay mwS1L3BLFv6ewJ8QMfpA2l14uCLSrsewMmyM6fzSroJzQ3DuFui8WfhzpCumKyUsxmgUc3s NJMrP0CeiMcS9hb92IXT3aF9jkMYrNAcmIWOp8C9YlqGvhjQbkqoM4TZF0mxIy17d+ds4AN JeteFgaAm9Yb7YGbjq9KA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:Dv6f/SwZhn0=:oifY/QVROmOGACNw9w69AK vxD9dSu3E4IyWt5Xu0bEYYgb8aCyXid2QNFRbbnurbmvKgxo7sbeJMWsJLyhrkwsU2fuLiyfh IFyGlXmrrhO2lUC2Wj3k3Peu19mh95YuUyWmWApv5IaeynsLRBGkznE5a464JlWeSmYxCcDaK MlkdqRTazgqqpfyzLJpM7H83vtob/Ux+Ztgxo68NPNRE6JAcCXyvk5ZEr3HNINnnXkLGYYMoo nMQEnQ5ZTgMqIsgqKmhEIVWGVNZn0UV6FrQTxfVLErA9/71f1WBOGpsehiev+xJRYV8gGyKv4 IyHiuxoMGq7bDMsiiDcQm52JFuj8J9FBa1soPu2Yx6HJq4Wy8vTPUzMHTA4PJ3W2NoVUF9oYD 9/RNr8sI1U4EPie2SBFsI2qoRzXgEYcjXO5VZaFwMiZZSXqkNUehmZdvzitSM/+eRVtdFkx3Z WxhtPTYyMU2UNXherRR1UBHhzUXQQda2tEVlOWjf3770Hpjhs0SzBWunDhpg+KQ7kZaZMt0vG QBuU0EtU9+KDEKkLoWwjz5mwhPQqtKoc7yfCvvm7geS0po/YM+pIcFdMj/5BpqtssepA3f6Bz OErmMmu2G16RG9C3iqlnun9N1XgUYQRltkhNi4Zm+XZ7FuYUK3bUPYEU8NSUntjiS3o+a5lBj Ee9dkWBUs0CYvQpMEnxEZO+t+eXKVEinyB4g5MkCOPwOoXgYZDPvT5U1XroYNl5WozUuXwZcR XxERTAJ1O7P9tyZCFFeKYcIKcNY0GHvhmqf1mIEyghXe/qTvw1FY4Ow3JEyzgBTLyGvrZLqbH lIkrKkVCsq+gz+ujRsV5UD7dD/HnFDfBl/hIMiBkRKNwqDVohEoVoXvhORp1CqQ6XZmK+oYBD nsri8Ae1Ul+TMhPu9yWNpgtPuK1qmUwQPS8JrNQhJ/nl2u/aeC9KH/h7dyYoPNFl/ayYJ0rRx U7/aYZYE0effrlUfIFGdPTB7XYSF85EYnenGe7ddp5/bLXxTIIMfS4MD2NABwgXtaOcRkPOi5 hRegDHrWg04J30Yg3Mkjo2XdR9nJAynZY6CRvqHI5kn2Nsxa7C9cQOO8ECdhO29hgMpXK1g7s 7PT6Akb+U5ruCXB/24la+hJJOB4JqPR8u+Ri6dSQXiwmhgR39vS4MOp+WetGh7bsL8QiG5e2Z rxcwaCoECaMgLF2r24a/J25JRCcUsXWR68B8s5gInF+5pdk9so6A+hXNN1WPr4sJVBKaNCwK/ 8ru3GBZI3xHISH9kP X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: 36672 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.2 (/) > > I wonder if support is a WM thing? > > Indirectly, maybe. I have to try with window maker later. Window maker shows the same behavior. That is, moving a parent frame does not move the child frame and in addition the child frame does not necessarily appear on top of the parent frame. I doubt that we can do much about this. martin From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 13 19:53:18 2020 Received: (at 36672) by debbugs.gnu.org; 13 Mar 2020 23:53:18 +0000 Received: from localhost ([127.0.0.1]:60393 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCu7C-0002PA-Hr for submit@debbugs.gnu.org; Fri, 13 Mar 2020 19:53:18 -0400 Received: from mailout-l3b-97.contactoffice.com ([212.3.242.97]:51540) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jCu7A-0002Ow-Kq for 36672@debbugs.gnu.org; Fri, 13 Mar 2020 19:53:17 -0400 Received: from smtpauth2.co-bxl (smtpauth2.co-bxl [10.2.0.24]) by mailout-l3b-97.contactoffice.com (Postfix) with ESMTP id 2A7D89D6; Sat, 14 Mar 2020 00:53:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1584143590; s=20200222-6h9o; d=idiocy.org; i=alan@idiocy.org; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version:Content-Type:Content-Transfer-Encoding:In-Reply-To; l=685; bh=Xmjz5+p9BxOqqrQ2+hKWH0v0j6stbxCSvCaNvQCkShE=; b=E8gxaYX0YVc1bt7/Ve7uj+9Tey8PJMkPrzsvAAqoEFzRngc5LiQmlj4WR35We0De KHaaNy6eC23gsTnUAetf0t7/dBu8b/NoofmWMWCxbzyzNjftzdykDsp4+aKFLf6weTJ nyS+n90nuVyX5nVyduYa43gzZNt8WZi0hbBe286eK847cAem/gj7JCBJEMi/aoVD876 d5EP9W7zylgcqeT9APtceYe+p3Mz/Fll7E4RlgyPLvCo2/1YTYSfio97ezfmLNeA4Qv HYjwsoZHfl+LEe2OERqe7oD2Xw8UOsf/lp+Sii6sG3C4Rfl+RmgyJCEFsNY6wPNqN6O k4BbWxn55w== Received: by smtp.mailfence.com with ESMTPA ; Sat, 14 Mar 2020 00:53:06 +0100 (CET) Received: by idiocy.org (Postfix, from userid 501) id A56A02020403B8; Fri, 13 Mar 2020 23:53:05 +0000 (GMT) Date: Sat, 14 Mar 2020 00:53:07 +0100 (CET) From: Alan Third To: martin rudalics Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space Message-ID: <20200313235305.GA13702@breton.holly.idiocy.org> Mail-Followup-To: Alan Third , martin rudalics , Andrii Kolomoiets , 36672@debbugs.gnu.org References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> <20200312232706.GA84518@breton.holly.idiocy.org> <96e82dad-b72f-d8c5-29d4-4e02d9bb127b@gmx.at> <20200313151322.GA2905@breton.holly.idiocy.org> <72f46966-46a1-f470-18ff-9ba1ff5ad5db@gmx.at> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <72f46966-46a1-f470-18ff-9ba1ff5ad5db@gmx.at> X-Spam-Flag: NO X-Spam-Status: No, hits=-2.9 required=4.7 symbols=ALL_TRUSTED, BAYES_00 device=10.2.0.20 X-ContactOffice-Account: com:241649512 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 36672 Cc: Andrii Kolomoiets , 36672@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) On Fri, Mar 13, 2020 at 05:29:17PM +0100, martin rudalics wrote: > > I thought GNUstep > > worked that way too, but in my own experiments I can’t get them to > > move at all, even with clicking in the windows like you’re doing. > > Indeed. What I tried was to move the child frame by dragging its mode > line. What happens when you call (set-frame-position child-frame x y) > for a child frame and some values of x and y? It does what I expect. So the Emacs side child frame stuff appears to work, but the GNUstep stuff doesn’t. As far as I can see in the code we are setting the child frame correctly, so I have to assume it just doesn’t work. -- Alan Third From debbugs-submit-bounces@debbugs.gnu.org Sat Mar 14 04:48:40 2020 Received: (at 36672) by debbugs.gnu.org; 14 Mar 2020 08:48:40 +0000 Received: from localhost ([127.0.0.1]:60588 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jD2TI-00027a-HY for submit@debbugs.gnu.org; Sat, 14 Mar 2020 04:48:40 -0400 Received: from mout.gmx.net ([212.227.17.22]:50937) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jD2TG-00027B-Vj for 36672@debbugs.gnu.org; Sat, 14 Mar 2020 04:48:39 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1584175710; bh=aoYbSCyZ5+JgS0cdB3CFs/5DPZ3lvkd50PkKdb41M8M=; h=X-UI-Sender-Class:Subject:To:References:From:Date:In-Reply-To; b=M8uD06c69q/gjCa5KRkjQ6GhU5ybpKITVAKGkeN/BQLf1TK4IFB3qT+EgeKdgl9ft rY/hTj7i6Z2uoZoW3t1HvF4Ysb2JGf9e2OhkZ/FtDVEg24xZwNAs4O0v52eDOEJ8Sv fZltL0N2FaBxzniITSYz8pTqCqLE0wMDNkT9NbPQ= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.1.101] ([212.95.5.28]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MKsnF-1isTqN2M4D-00LCt4; Sat, 14 Mar 2020 09:48:30 +0100 Subject: Re: bug#36672: 27.0.50; NS build: Creating child frame leads to empty space To: Alan Third , Andrii Kolomoiets , 36672@debbugs.gnu.org References: <04CF7A6F-C1E7-4FE5-B648-8DA8CBD3B1ED@gmail.com> <20190716192822.GA63701@breton.holly.idiocy.org> <20200301161605.GA8290@breton.holly.idiocy.org> <20200312232706.GA84518@breton.holly.idiocy.org> <96e82dad-b72f-d8c5-29d4-4e02d9bb127b@gmx.at> <20200313151322.GA2905@breton.holly.idiocy.org> <72f46966-46a1-f470-18ff-9ba1ff5ad5db@gmx.at> <20200313235305.GA13702@breton.holly.idiocy.org> From: martin rudalics Message-ID: <997ff355-4273-5971-d907-8398bb62794f@gmx.at> Date: Sat, 14 Mar 2020 09:48:29 +0100 MIME-Version: 1.0 In-Reply-To: <20200313235305.GA13702@breton.holly.idiocy.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:DPBk/pFQzcpQ2/8dpJpqlN+23HZCEml1BqlhqpMdhJhofNLxq5L ah4rLhJhtjZSRLcDvG7rFUt2Omd3ZUCzL7LD0zJx/S8YreyZsySLkY7RYeRTAGZmPpSkGIU G7K9/fdbHfhwUcI8zyowx+e8sFUzZCup8//2+Bi7Tnt6Iu/U/Zf1a3sjKhXuY3M6Inzhrvn QSHdj3mgi5i32cuNfJPEw== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:S0zh31hDXF4=:XYvCgyVK5RDDXqpHPO3Ms3 G6GpxUZHLOdAnSN2onrsiX6YHsy1rXWovAyV6M8EDW+AoKqrnRbKUCwjSXlwCF1b0ODaJjjtG 6Ku7/Rqvk+fkxHDQ9fQQYYFWIDkrgESq1b3+dNkhg8/gOA24B2bXpaGCr+FUXb6hOOxeSSHYn B2XStzLYzTXHcpY4IGFUGEs1WuDE6CpV+Xj390srQo+6Eg+3S9RghXqLlJ2HILEVoxhf0RzSB 5ssl0NWovAnYWZSy7EdYgVkZ1LX7yc5RdJd0cbJr2/Y7b6NLQHB9CiF4XXqgZHI0OI8a/w9F6 k2NSdRPxKe7IxoPj0rG08ofcl/Wa0saoNkardxPoVbRBbNfZz+YGhQ/oIb7ODeRdv50HWDEcl 0trNgF2agtKqqVDePkOvT+6iYXmFk2t++tQ5CPYKG4FlbFGGB33eNGcwkC9ZYI8pIEcoerCUq lycHAEX68ZsaAxIfjl3rYgqu/IGhEBSXA8isSeWXP9s6cuLDzr/xp4Fblo9UqtmH5VYdHX5L0 rUPLDHNZrHt6RKds2uwLkLhZIYiAzILqoq5izBdYJAwy2qV49xwWios9kBz2II6BOqzJjan0e 6kzHouepkQmd//HobjynRVfo0mLIb9uyziHHg1WcqCOu5hFY8od/B0kSiMoMhPLDktab/sOhd SS6mZ9tJAbZSCoZlxRGqVwoJA/TnB0pxUbwI/UY8foQ8dNmOooZeG6CXC+24/k0Vd/DmrZ2Mg tPnj9lBU4Sp106Z9PCt83qKcn5UaK7m/HZ26Yy1hMeKZTzmJoJSe++VklGHIf5HYyKlcbORBD ke9ccFQqyWs+Gih5rOk8Z2QIEmHKGIeXliX6CPofVFT2TXoDk3gt/p8VRrqs8qqa4+PVBhrxi tYLINvXu1LrzVDXcMTbwG7a0baYn5xda2Y33EebrlWyaaqjfdA8QTer2V8VM3EF4vtX4Gbl8z aiEW2Q3HnzJjsDLTeGuhuV1oLz0bj7lUdnuuN7zZPB6SLCACmemW7A1nMM1I6da2gMMhyTghq iudyiLVHrqcsJmdQM1wljy8pTyz0hWFb8b048kc9RC3VmPrwSRrecva9e5UGoKKMDGwi6iiTs cS2hbvLwkyAA3KMqJhDyZF/AzPUNpWHD0gvk+FqjtHzeqigPUKrB0MQOM9RZ0VnsKGrfvL9Bu AqHwSUIzQ8eqNx7UbuiFLWtAMJWeJVxr4hoq86EYPPMdOLfvSLTYyMSE48QsaNAEd1TYlo67M GnzkrmLOiqteQOK8a X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 36672 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > It does what I expect. So the Emacs side child frame stuff appears to > work, but the GNUstep stuff doesn=E2=80=99t. As far as I can see in th= e code > we are setting the child frame correctly, so I have to assume it just > doesn=E2=80=99t work. OK. Thanks for looking into it, martin From unknown Sun Jun 22 11:44:59 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 11 Apr 2020 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator