From: Alan Third Date: Tue, 28 Dec 2021 11:36:46 +0000 (+0000) Subject: Remove macOS drop-shadows on some frames (bug#28512) X-Git-Tag: emacs-29.0.90~3263 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=2d4b2e296b5c13a8b8481e7c0d0c26f52d2de257;p=emacs.git Remove macOS drop-shadows on some frames (bug#28512) * src/nsterm.m ([EmacsWindow setParentChildRelationships]): Remove shadows on undecorated child frames. --- diff --git a/src/nsterm.m b/src/nsterm.m index 2318f7beab3..41c311e04dc 100644 --- a/src/nsterm.m +++ b/src/nsterm.m @@ -8435,6 +8435,15 @@ not_in_argv (NSString *arg) #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 [ourView updateCollectionBehavior]; #endif + + /* Child frames are often used in ways that may mean they should + "disappear" into the contents of the parent frame. macOs's + drop-shadows break this effect, so remove them on undecorated + child frames. */ + if (parentFrame && FRAME_UNDECORATED (ourFrame)) + [self setHasShadow:NO]; + else + [self setHasShadow:YES]; #endif