aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorYAMAMOTO Mitsuharu2015-12-09 18:16:09 +0900
committerYAMAMOTO Mitsuharu2015-12-09 18:20:25 +0900
commit59d08e9898cd9096c6c70be45b2f4752d4ee7397 (patch)
tree08e4117c8f1065b2d30e0694e5d63e17771e4a4d /src
parentae3057412a0673667e76cd281e5c5db46be18254 (diff)
downloademacs-59d08e9898cd9096c6c70be45b2f4752d4ee7397.tar.gz
emacs-59d08e9898cd9096c6c70be45b2f4752d4ee7397.zip
Remove font workaround for limited outdated versions
* src/macfont.m (mac_font_descriptor_get_adjusted_weight): Remove workaround for HiraginoSans-W7 on OS X 10.11 and 10.11.1.
Diffstat (limited to 'src')
-rw-r--r--src/macfont.m19
1 files changed, 5 insertions, 14 deletions
diff --git a/src/macfont.m b/src/macfont.m
index fae284fad89..3023fbea78c 100644
--- a/src/macfont.m
+++ b/src/macfont.m
@@ -771,7 +771,7 @@ mac_font_descriptor_get_adjusted_weight (CTFontDescriptorRef desc, CGFloat val)
771{ 771{
772 long percent_val = lround (val * 100); 772 long percent_val = lround (val * 100);
773 773
774 if (percent_val == -40 || percent_val == 56) 774 if (percent_val == -40)
775 { 775 {
776 CTFontRef font = NULL; 776 CTFontRef font = NULL;
777 CFStringRef name = 777 CFStringRef name =
@@ -786,19 +786,10 @@ mac_font_descriptor_get_adjusted_weight (CTFontDescriptorRef desc, CGFloat val)
786 { 786 {
787 CFIndex weight = mac_font_get_weight (font); 787 CFIndex weight = mac_font_get_weight (font);
788 788
789 if (percent_val == -40) 789 /* Workaround for crash when displaying Oriya characters
790 { 790 with Arial Unicode MS on OS X 10.11. */
791 /* Workaround for crash when displaying Oriya characters 791 if (weight == 5)
792 with Arial Unicode MS on OS X 10.11. */ 792 val = 0;
793 if (weight == 5)
794 val = 0;
795 }
796 else /* percent_val == 56 */
797 {
798 if (weight == 9)
799 /* Adjustment for HiraginoSans-W7 on OS X 10.11. */
800 val = 0.4;
801 }
802 CFRelease (font); 793 CFRelease (font);
803 } 794 }
804 } 795 }