From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alan Third Newsgroups: gmane.emacs.bugs Subject: bug#31795: 26.1; Undecorated frame resize issues on macOS Date: Tue, 12 Jun 2018 21:07:48 +0100 Message-ID: <20180612200748.GB889@breton.holly.idiocy.org> References: NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: blaine.gmane.org 1528834039 19276 195.159.176.226 (12 Jun 2018 20:07:19 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 12 Jun 2018 20:07:19 +0000 (UTC) User-Agent: Mutt/1.10.0 (2018-05-17) Cc: 31795@debbugs.gnu.org To: Boris Buliga Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Jun 12 22:07:15 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fSpZP-0004qk-Ca for geb-bug-gnu-emacs@m.gmane.org; Tue, 12 Jun 2018 22:07:11 +0200 Original-Received: from localhost ([::1]:58241 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSpbU-0005Th-Uq for geb-bug-gnu-emacs@m.gmane.org; Tue, 12 Jun 2018 16:09:20 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:46084) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSpaH-0004oF-S6 for bug-gnu-emacs@gnu.org; Tue, 12 Jun 2018 16:08:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSpaE-0006lV-Mv for bug-gnu-emacs@gnu.org; Tue, 12 Jun 2018 16:08:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:37488) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fSpaE-0006lL-Hz for bug-gnu-emacs@gnu.org; Tue, 12 Jun 2018 16:08:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fSpaE-00054L-Cq for bug-gnu-emacs@gnu.org; Tue, 12 Jun 2018 16:08:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Third Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 12 Jun 2018 20:08:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 31795 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 31795-submit@debbugs.gnu.org id=B31795.152883407819469 (code B ref 31795); Tue, 12 Jun 2018 20:08:02 +0000 Original-Received: (at 31795) by debbugs.gnu.org; 12 Jun 2018 20:07:58 +0000 Original-Received: from localhost ([127.0.0.1]:45383 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fSpa9-00053w-VG for submit@debbugs.gnu.org; Tue, 12 Jun 2018 16:07:58 -0400 Original-Received: from mail-wr0-f171.google.com ([209.85.128.171]:36063) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fSpa9-00053g-7t; Tue, 12 Jun 2018 16:07:57 -0400 Original-Received: by mail-wr0-f171.google.com with SMTP id f16-v6so283216wrm.3; Tue, 12 Jun 2018 13:07:57 -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=t+ihej7cJGNMzTpVpsH9FAVluOoF7VL+FbliIzGxAQw=; b=r7aTwYR4QIE/2ituHLJ4y5+1Y1yTziPvYLVoNbUNrry/vsECG+P2roKpLGB8f3Pu7A XQGPLVtu2xB102r9wZvsruqwkReXZYLvvE9Z+C69krVYRiyjxD3Xn7Lo5mCcebTakOOL 8gEJ3FY/a62sz6gyrLNfCsbobZoGmGOd+cM6pveh+cCcZTnEaj765spVP3ofbnIkOiOY Fn5khgevaC3UH1/LKsEUWcUXvK3O7BtjEfWzRHyf/+bcWTuzvGDk9ZyIKIZ/hoxMexm6 oBIMJknu7dZPZ4oaJZzwFKRFQFSVNcyixZFrvz7rW5K0qGfR5B0Fzl2K/V+XZT9un6A3 Q7gA== 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=t+ihej7cJGNMzTpVpsH9FAVluOoF7VL+FbliIzGxAQw=; b=Y88o7YFJgLDyk5Xh0bq0vWPdSlu3Vfr6JgGm/kh0ttIdaX1E0PArUAQSZuA9VNcnx4 Ca+E9PZezlIQFAyehllajSsCLp8kmVaY8Ei5AdYZ0sjOM3Zg8XZlMUD7tv3mRAmQQ3oc 6Or4CG1GjDM9rUxUpnvkaO/UlniBtBUccNsK36XudO1Uvp9mQXbi8Lh21398Lt+3Q+42 bP28D/taY97rtqyW1uraf0LXHlVI0xjGO1Rhjmm24/Uyp/1AHmwwd34ZitOsNIXol5Yo 6/FjXqM2R4FtFrl3+cot0OakIB4vV1kpVSk21xtghnox8krTOUUHUHaVfG/tyF7i8vCh J6XA== X-Gm-Message-State: APt69E3hU0N1Ecm+pZWZ+ny49C8D77/gqbG+TMuKllVu5oeI/9AF0/dB Z5QKDFwBeDRWymEpCM+58/w= X-Google-Smtp-Source: ADUXVKKzs9bQRPWum3jcxZaNBJb2vuJCaq+wx8iadAtm2XWGgyaTstKmHXJBWqTtdiz5Q8gzJ/3+UA== X-Received: by 2002:adf:9aa5:: with SMTP id a34-v6mr1839594wrc.50.1528834071473; Tue, 12 Jun 2018 13:07:51 -0700 (PDT) Original-Received: from breton.holly.idiocy.org (ip6-2001-08b0-03f8-8129-2050-339f-0e48-d89b.holly.idiocy.org. [2001:8b0:3f8:8129:2050:339f:e48:d89b]) by smtp.gmail.com with ESMTPSA id e14-v6sm1117061wmh.17.2018.06.12.13.07.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 12 Jun 2018 13:07:50 -0700 (PDT) Content-Disposition: inline In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:147339 Archived-At: merge 31795 28512 thank you On Mon, Jun 11, 2018 at 09:38:57PM +0300, Boris Buliga wrote: > 3. Try one of the following actions > > 3.1. M-x toggle-frame-fullsreen > > Frames' window (in macOS sense) becomes fullscreen. But it doesn't > cover all screen, instead it remains of the same default size with > black area around. Hmm, this isn’t very good. Maybe we should be resetting the window style before and after toggling fullscreen. > 3.2. Use Spectacle.app (or similar application for resizing windows in > macOS) > > Frame is not resized. Unfortunately this is expected. Apparently macOS doesn’t like you changing the window style on the fly, and resizing breaks. The solution appears to be to recreate the NSWindow, or give up on NSWindowStyleMaskBorderless and switch to using NSFullSizeContentViewWindowMask and its relatives. > I've tried patching src/nsterm.m file by chaning definition of > FRAME_DECORATED_FLAGS from > > #define FRAME_UNDECORATED_FLAGS NSWindowStyleMaskBorderless > > to > > #define FRAME_UNDECORATED_FLAGS NSWindowStyleMaskBorderless | > NSWindowStyleMaskResizable I would expect that to work. Is the line break just because of your email client? If not then you need to escape the newline like this: #define FRAME_UNDECORATED_FLAGS NSWindowStyleMaskBorderless \ | NSWindowStyleMaskResizable > and creating EmacsFSWindow instead of EmacsWindow (so canBecomeKeyWindow > and canBecomeMainWindow both return YES). You don’t need this. IIRC EmacsFSWindow exists solely for non‐native fullscreen. -- Alan Third