[macemacsjp-cvs 555] [574]

Back to archive index

svnno****@sourc***** svnno****@sourc*****
2011年 3月 21日 (月) 17:13:35 JST


Revision: 574
          http://sourceforge.jp/projects/macemacsjp/svn/view?view=rev&revision=574
Author:   taiichi
Date:     2011-03-21 17:13:35 +0900 (Mon, 21 Mar 2011)

Log Message:
-----------


Modified Paths:
--------------
    inline_patch/trunk/ChangeLog
    inline_patch/trunk/font.patch


-------------- next part --------------
Modified: inline_patch/trunk/ChangeLog
===================================================================
--- inline_patch/trunk/ChangeLog	2011-03-15 00:54:20 UTC (rev 573)
+++ inline_patch/trunk/ChangeLog	2011-03-21 08:13:35 UTC (rev 574)
@@ -1,3 +1,7 @@
+2011-03-21  HASHIMOTO Taiichi <taiic****@mac*****>
+
+	* font.patch (nsfont.m): バグを修正
+
 2011-03-15  HASHIMOTO Taiichi  <taiic****@mac*****>
 
 	* README を追加

Modified: inline_patch/trunk/font.patch
===================================================================
--- inline_patch/trunk/font.patch	2011-03-15 00:54:20 UTC (rev 573)
+++ inline_patch/trunk/font.patch	2011-03-21 08:13:35 UTC (rev 574)
@@ -1,23 +1,30 @@
-diff -rp ../emacs-23.3-0/src/nsfont.m src/nsfont.m
-*** ../emacs-23.3-0/src/nsfont.m	2011-01-09 02:45:14.000000000 +0900
---- src/nsfont.m	2011-03-15 09:41:15.000000000 +0900
+diff -pr ../emacs-23.3/src/nsfont.m src/nsfont.m
+*** ../emacs-23.3/src/nsfont.m	2011-01-09 02:45:14.000000000 +0900
+--- src/nsfont.m	2011-03-21 17:11:01.000000000 +0900
 *************** nsfont_open (FRAME_PTR f, Lisp_Object fo
-*** 846,851 ****
+*** 846,853 ****
+        lrint (hshrink * [sfont ascender] + expand * hd/2);
+      /* [sfont descender] is usually negative.  Use floor to avoid
+         clipping descenders. */
+!     font_info->max_bounds.descent =
+!       -lrint (floor(hshrink* [sfont descender] - expand*hd/2));
+      font_info->height =
+        font_info->max_bounds.ascent + font_info->max_bounds.descent;
+      font_info->max_bounds.width = lrint (font_info->width);
 --- 846,861 ----
         lrint (hshrink * [sfont ascender] + expand * hd/2);
       /* [sfont descender] is usually negative.  Use floor to avoid
          clipping descenders. */
-+     if ([sfont mostCompatibleStringEncoding] == 0x80000001) {
-+       /* If the font is Japanese (Mac OS) encoding, change descender to 2 times.
-+          Because most of Japanese font's decender, such as Hiragino, is 
-+          too short. */
-+       font_info->max_bounds.descent = 
-+         -lrint (floor(hshrink* [sfont descender] * 2 - expand*hd/2));
-+     } else {
-+       font_info->max_bounds.descent = 
-+         -lrint (floor(hshrink* [sfont descender] - expand*hd/2));
-+     }
-      font_info->max_bounds.descent =
-        -lrint (floor(hshrink* [sfont descender] - expand*hd/2));
+!     if ([sfont mostCompatibleStringEncoding] == 0x80000001) {
+!       /* If the font is Japanese (Mac OS) encoding, change descender to 2 times.
+!          Because most of Japanese font's decender, such as Hiragino, is 
+!          too short. */
+!       font_info->max_bounds.descent = 
+!         -lrint (floor(hshrink* [sfont descender] * 2 - expand*hd/2));
+!     } else {
+!       font_info->max_bounds.descent = 
+!         -lrint (floor(hshrink* [sfont descender] - expand*hd/2));
+!     }
       font_info->height =
-Only in src: nsfont.m.orig
+        font_info->max_bounds.ascent + font_info->max_bounds.descent;
+      font_info->max_bounds.width = lrint (font_info->width);



macemacsjp-cvs メーリングリストの案内
Back to archive index