[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677

rjw rjw at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:19:32 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 1c8a077220849100a0d76aaf2fdc8b414a1c41a3
Author: rjw <rjw at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Wed Dec 17 01:33:45 2003 +0000

    	Fixed 3503011.  Added '-' and '?' to rounding hack.
    
            Reviewed by John.
    
            * WebCoreSupport.subproj/WebTextRenderer.m:
            (isRoundingHackCharacter):
            (widthForNextCharacter):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@5809 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index 6b63d88..e03d6a1 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,13 @@
+2003-12-16  Richard Williamson   <rjw at apple.com>
+
+	Fixed 3503011.  Added '-' and '?' to rounding hack.
+
+        Reviewed by John.
+
+        * WebCoreSupport.subproj/WebTextRenderer.m:
+        (isRoundingHackCharacter):
+        (widthForNextCharacter):
+
 2003-12-16  Darin Adler  <darin at apple.com>
 
         Reviewed by Richard.
diff --git a/WebKit/WebCoreSupport.subproj/WebTextRenderer.m b/WebKit/WebCoreSupport.subproj/WebTextRenderer.m
index 1ba70a2..d21bad8 100644
--- a/WebKit/WebCoreSupport.subproj/WebTextRenderer.m
+++ b/WebKit/WebCoreSupport.subproj/WebTextRenderer.m
@@ -180,6 +180,11 @@ static inline BOOL isSpace(UniChar c)
     return c == SPACE || isAlternateSpace(c);
 }
 
+static inline BOOL isRoundingHackCharacter(UniChar c)
+{
+    return isSpace(c) || c == '-' || c == '?';
+}
+
 
 // Map utility functions
 static void freeWidthMap(WidthMap *map);
@@ -1965,15 +1970,7 @@ static float widthForNextCharacter(CharacterWidthIterator *iterator, ATSGlyphRef
     // floats we can remove this (and related) hacks.
     //
     // Check to see if the next character is a space, if so, adjust.
-    if (currentCharacter < run->length && isSpace(cp[clusterLength])) {
-        width += ceilCurrentWidth(iterator);
-    }
-
-    // Ceil the width of the last glyph in a run, but only if
-    // 1) The string is longer than one character
-    // 2) or the entire stringLength is one character
-    int len = run->to - run->from;
-    if (currentCharacter >= (unsigned)run->to && (len > 1 || run->length == 1) && iterator->style->applyRounding){
+    if (currentCharacter < run->length && isRoundingHackCharacter(cp[clusterLength])) {
         width += ceilCurrentWidth(iterator);
     }
     

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list