Are they being actively obscured by the operative system without there being icons with that real appearance?
Folder icons are indeed displayed with a darker shade of blue and a darkened tab when using Dark Mode.
In this case, any idea to apply this method to the custom icons without modifying it into a new coloration?
I think you will have to modify your custom folder icons, but beware the darker look is not consistent: Folder icons are darkened when placed on the desktop and previewed with Quick Look, but when displayed in a Finder window, they maintain their bright appearance, as you can see in the following screenshots:
Folder on Desktop:
Same folder in Finder window, with a Quick Look preview to its right:
So you are out of luck if you want your custom folders to match the way Finder folders look like. I think this behavior is more of an omission than a deliberate design decision, and checking "Reduce Transparency" in System Preferences>Accessibility>Display doesn't change how folders are displayed, that is, this is not caused by Desktop Tinting (more on Desktop Tinting below).
About Desktop Tinting
There is a new Mojave feature called Desktop Tinting that only is activated when using Dark Mode. Desktop Tinting slightly modifies the color of windows to match your desktop picture.
If you want to disable Desktop Tinting, Graphite Mode will disable the color tinting altogether, according to, for example, Apple's Introducing Dark Mode WWDC 2018 Session and Ars Technica Mojave review.
You can find additional information about Desktop Tinting in the Introducing Dark Mode WWDC 2018 video (select the Transcript tab and search for "desktop tinting"):
[D]esktop tinting (...) causes the window's background colors to camouflage
themselves with the desktop picture.
We found that completely
desaturated gray colors have a tendency to have a color temperature
that was sometimes in conflict with what your desktop picture was, and
this effect was magnified when you have a translucent sidebar area,
for example, against a solid opaque area of your window, and so
desktop tinting helps mitigate that.
Once applied, the desktop tinting
gives the whole window a harmonious color scheme, which helps it to
blend in with the surrounding areas and really reduces that color
temperature disparity.
and the Ars Technica Mojave review:
One separate but related feature exclusive to Dark Mode is called
Desktop Tinting, which goes beyond the translucent sidebars and other
UI elements.
Each window samples an “average” color from whatever
piece of your desktop wallpaper it’s on top of and uses that color to
subtly tint every single window in the operating system. (...) Apple says that it’s meant to keep the bold Dark Mode windows from clashing with your chosen wallpaper.
Update:
This bug is potentially fixed in macOS 11 Big Sur. The bug report I filed is now marked as:
Potential fix identified - In macOS 11
One commenter, Curtis Hard, has stated the issue no longer happens for them with Big Sur.
It's unclear if the fix will be backported to 10.15 or 10.14.
It's definitely not a dead-pixel issue. I've determined it's probably a software bug introduced in Mojave and still present in Catalina. I'm not able to screenshot the glitch in most cases (the glitch will typically immediately disappear), but I have managed to capture it on a couple of videos and screenshots.
The fact that it can be captured in software and the fact that the cursor can cover over the glitched pixels indicates the issue is not in the screen but happening in software.
Examples:
Firefox
Here's a screenshot from a screen recording of Firefox, where you can see the grey pixels.
Interestingly, if we zoom in a bit, we can see the pixels are actually outside the window itself.
Finder
I've also captured similar glitches happening in Apple's own Finder on regular screenshots.
Notes:
Some interesting things to note about it.
- I've only seen it happen against dark areas of a window.
- It can happen in both light mode and dark mode (if the window is dark anyway).
- It mostly happens at the edge of a window (where the shadow is), though I have seen it on the inside of some.
- It often (but not always) disappears when window focus changes, among other things (window focus changing causes window shadows to change).
- I've been able to change focus to and from an iTerm window with no shadow (when transparency is enabled), and the glitch outside the bottom edge of the window persisted.
- It can be captured with QuickTime Player's Screen Recording feature.
- Mysteriously, though it can be capture with QuickTime, it is invisible to Apple's developer tool Pixie, as seen in this screen recording. Likewise, the Digital Color Meter app does not see it either.
- I've seen it mostly in grey and red, but also green, yellow, and more colors.
- The glitch can happen even when Finder is not running, so it's not a part of Finder.
- Running
killall Dock
while SSH'd into a machine displaying the glitch may cause it to stop, though this may just be a side-effect of shadow changes.
- I tried suspending all the Firefox processes (
firefox
+ plugin-container
processes) over SSH with kill -SIGSTOP
while the glitch was happening and the glitch continued to blink, further indicating the glitch is happening outside the Firefox processes.
- Going further, I tried systematically suspending processes over SSH, to see which one might be responsible. The only one suspending causes the flashing to freeze with was
WindowServer
.
- Using the Quartz Debug developer tool (one of the Xcode addition tools, mentioned here), I tested some of the options it had. When the "Disable 2D Acceleration" option was enabled, I was unable to reproduce the glitch like I could when it was disabled. The Autoflush drawing and Vertical Sync options had no effect.
- It seems to only happen with the integrated graphics card. I have not been able to reproduce it while the discrete card is active.
- So far I've only heard reports of it happening on recent MacBook Pro and MacBook Air models. I was unable to reproduce this issue on a previous generation MacBook Air running the same OS version.
- I've not yet seen it happen in a Mojave VM using VMware Fusion, further indicating it only happens with certain hardware.
- To remove all variables, I tried running a clean install of Mojave 10.14.1 on an external drive. With all default settings, I was quickly able to reproduce it Light Mode with Firefox 63.0.1 with the dark theme and dark developer tools theme enabled and the console open (screen recording).
- Browser-like applications appear especially likely to trigger it (ie. Firefox and Electron-based apps).
- Applications I've seen it with (I've probably forgotten some):
- Firefox (especially versions < 70)
- Top edge (requires dark Firefox theme)
- Bottom edge (requires dark bottom of window from open search bar with dark theme, dev tools with dark theme, or dark web page content). Also done on a clean 10.14.1 install.
- Atom (may require Settings > Core > Title Bar > custom)
- Discord
- Bottom edge
- Inside window
- iTerm (with a black, semi-transparent background; it does not seem to happen with an opaque background)
- Top edge
- Bottom edge
- Inside window (at the bottom edge of one pane with split panes)
- Finder
- Activity Monitor
- Disk Utility
- Console
- Inside window (over the transparent column headers)
- Mail
- Inside window (over the transparent column headers)
- Archive Utility
- Hex Fiend
- Google Chrome (when using macOS dark mode)
- Inside window at
chrome://downloads/
under light grey horizontal line of top menu bar)
- I've also seen it happen once at the bottom edge of the drop-down menus from the top menu bar.
- The selection of apps and places I've seen it with make me suspicious it may in some way be window transparency related.
Things that have no impact on the glitch (tested with Firefox):
- Doing a clean install of 10.14.1.
- Resetting PRAM.
- Resetting SMC.
- Open the app in low resolution mode.
- System Preferences:
- Display resolution scaling.
- Display color profile.
- Night Shift.
- System accent color.
- Auto-hiding dock.
- Accessibility > Display > Use grayscale
- Accessibility > Display > Invert colors
Hardware:
I've only heard claims of it affecting different MacBook Pro models from 2016+ and the 2018+ MacBook Air (the models with USB Type-C). If you are seeing this issue on another Apple computer model, or don't have this issue on one of the affected models, I would be interested to hear about it.
Conclusion:
Unfortunately, I don't think there is any way to prevent this glitch at this point, aside from forcing the use of the discrete card if your computer has one (and you don't mind the reduced battery life), but hopefully it will be resolved in a future update.
Even more unfortunate, it still has not been fixed in any version from 10.14.0 through 10.14.6 or the second supplemental update since, and remains unfixed in the first supplemental update for 10.15.7. A comment from Curtis Hard confirms it was still present in the Big Sur betas at the time (it would be great if someone could confirm or deny it exists in newer builds).
I filed a bug report on bugreport.apple.com (not public, but 46079638
), which has been marked as a duplicate of 45841204
. I don't have access to that bug report, but thought I would mention it in case anyone wants to reference it.
On a side note, there's a good change Apple's future ARM-based computers won't have this issue since they won't have the Intel integrated GPU's. That won't fix the issue for existing Intel computers though.
Firefox 70+:
Since Firefox 70 it doesn't happen as often as it did before, though it still does happen. I suspect this is related to some improvements that reduce the amount of screen drawing.
Steps to reproduce:
I've had the best luck reproducing the bug with Firefox.
- Open Firefox (63.0.1 in my case)
- Set Firefox theme to Dark
- View > Toolbars > Customize... > Themes > Dark
- Navigate to a page like http://example.com/
- Open developer tools
- Tools > Web Developer > Inspector
- Set developer tools theme to dark
- In the top right, click ... > Settings > Themes > Dark
- Click the Inspector tab
- Open the console
- In the top right, click ... > Show Split Console
- Ensure the developer tools covers the bottom of the window
- If it doesn't, in the top right, click ... > Dock to Bottom
- Reload the page until the glitch happens
References:
Possibly loosely related: Avoid using a transparent surface by using CoreAnimation (if my suspicion that it is transparency related is correct, that change may eventually have an impact on this bug happening with Firefox, if only by avoiding the OS bug).
Note: If you have any info to share but don't have an account here, you can contact me here.
Best Answer
Create a script to enable dark mode
This shell file will run an AppleScript command to enable Dark Mode. The first time this script is run, it may require permission to modify your system settings.
It is critical to mark the file executable with
chmod +x
- otherwise, it will not run and you will get a vague 'Load Failed: 5: Input/output error' from the launchctl service.Create a launch agent
Create a new text file in
~/Library/LaunchAgents
titledAlwaysDarkMode.plist
(or something else, if you'd like). Paste in the following contents, ensuring to change the username to your own. You cannot use relative paths like~/AlwaysDarkMode.sh
- you must write out the full path to the file.Test the launch agent
Because the plist is stored in
~/Library/LaunchAgents
, it should run automatically when logging in. However, it might request permissions the first time it runs, so you can load it manually withlaunchctl load ~/Library/LaunchAgents/AlwaysDarkMode.plist
.