Bug 575960 - [Mac] Light theme not rendering on child Eclipse if system theme is set to dark
Summary: [Mac] Light theme not rendering on child Eclipse if system theme is set to dark
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.21   Edit
Hardware: Macintosh Mac OS X
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 578260
  Show dependency tree
 
Reported: 2021-09-14 03:36 EDT by Phil Beauvoir CLA
Modified: 2022-01-18 08:19 EST (History)
1 user (show)

See Also:


Attachments
Screenshot (679.45 KB, image/png)
2021-09-14 03:37 EDT, Phil Beauvoir CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Phil Beauvoir CLA 2021-09-14 03:36:47 EDT
Eclipse 4.21
AdoptOpenJDK-11.0.11+9
macOS Mojave, Catalina and Big Sur

1. Set the macOS system theme to Dark (System Preferences, General, Appearance, Dark)
2. Launch Eclipse
3. Run/Debug a child Eclipse instance
4. Set the child Eclipse theme to Light (Preferences, General, Appearance, Theme)

Only some of the light theme is working.
Comment 1 Phil Beauvoir CLA 2021-09-14 03:37:32 EDT
Created attachment 287125 [details]
Screenshot

Screenshot of child Eclipse
Comment 2 Alexis Drogoul CLA 2021-10-18 15:11:16 EDT
Interestingly, I have exactly the same issue when running a RCP application from Eclipse (see this issue here: https://github.com/gama-platform/gama/issues/3193). All modes work fine except the "light application in a dark os".
Comment 3 Phil Beauvoir CLA 2021-10-18 15:15:31 EDT
Add the following to Info.plist in the RCP app:

<key>NSRequiresAquaSystemAppearance</key>
<true/>

See https://bugs.eclipse.org/bugs/show_bug.cgi?id=543889
See https://bugs.eclipse.org/bugs/show_bug.cgi?id=540357
Comment 4 Alexis Drogoul CLA 2021-10-18 15:22:58 EDT
Hi Phil, will try and report back. Thanks for the tip !
Comment 5 Alexis Drogoul CLA 2021-10-18 15:26:25 EDT
@Phil: you saved my day. This is perfectly working. Thanks.
Comment 6 Phil Beauvoir CLA 2021-10-18 15:28:08 EDT
(In reply to Alexis Drogoul from comment #5)
> @Phil: you saved my day. This is perfectly working. Thanks.

Good.

It was only by a random chance that I discovered this. But, hey, that's how Eclipse development works - trial and error and no documentation.
Comment 7 Alexis Drogoul CLA 2021-10-18 15:32:50 EDT
Yep. I know ! However, it does not change the fact that running the application from Eclipse (w/o the Info.plist being used and read) exposes the same weird combinations of light/dark modes.