Skip to content

Instantly share code, notes, and snippets.

@dchakro
Created January 15, 2022 11:17
Show Gist options
  • Save dchakro/1319fd4c76a0dcb241f1cca1d97593d9 to your computer and use it in GitHub Desktop.
Save dchakro/1319fd4c76a0dcb241f1cca1d97593d9 to your computer and use it in GitHub Desktop.
Fix font smoothing on MacOS onexternal displays without high ppi
#!/usr/bin/bash
# These commands can help you fix font smoothing on MacOS Catalina & Big Sur
# on non-retina external displays i.e. external displays without high ppi.
# Levels 0 (no smoothing), 1 (low) - 3 (strong)
printf '
-------: Menu :--------
1) Settings for Monitor
2) Settings for rMBP display
3) Exit
Enter: ';
read var;
echo ""
case $var in
1)
# Settings for Monitor
defaults write -g CGFontRenderingFontSmoothingDisabled -bool FALSE
defaults -currentHost write -globalDomain AppleFontSmoothing -int 2
defaults write com.microsoft.office.plist CGFontRenderingFontSmoothingDisabled 3
defaults write com.microsoft.shared.plist CGFontRenderingFontSmoothingDisabled 3
defaults write net.cozic.joplin-desktop.plist CGFontRenderingFontSmoothingDisabled 0
;;
2)
# Reset to rMBP
defaults -currentHost delete -globalDomain AppleFontSmoothing
defaults write -g CGFontRenderingFontSmoothingDisabled -bool True
;;
3)
exit 0
;;
*)
echo
echo "Valid range of choices [1-3]."
echo "Try again..."
echo
sleep 0.5
continue
esac
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment