Skip to content
  • rjw's avatar
    979d2676
    Added support for khtml's justified text drawing. Additional padding is distributed · 979d2676
    rjw authored
            to space widths.  (Sites like www.osnews.com now render correctly.)
    
            Change word end rounding hack to use ceil of word width.  I'm still noticing a spacing anomaly
            that is fixed by a reload.  Occasionally text runs are still crammed together, but a reload uses
            correct spacing.  This anomaly is often visible on www.arstechnica.com.  Still investigating.
    
            * WebCoreSupport.subproj/WebTextRenderer.m:
            (-[WebTextRenderer drawGlyphs:numGlyphs:fromGlyphPosition:toGlyphPosition:atPoint:withPadding:withTextColor:backgroundColor:]):
            (-[WebTextRenderer slowDrawCharacters:length:fromCharacterPosition:toCharacterPosition:atPoint:withPadding:withTextColor:backgroundColor:attemptFontSubstitution:]):
            (-[WebTextRenderer _drawCharacters:length:fromCharacterPosition:toCharacterPosition:atPoint:withPadding:withTextColor:backgroundColor:]):
            (-[WebTextRenderer drawCharacters:stringLength:fromCharacterPosition:toCharacterPosition:atPoint:withPadding:withTextColor:backgroundColor:]):
            (-[WebTextRenderer slowFloatWidthForCharacters:stringLength:fromCharacterPostion:numberOfCharacters:applyRounding:]):
            (-[WebTextRenderer floatWidthForCharacters:stringLength:fromCharacterPosition:numberOfCharacters:applyRounding:attemptFontSubstitution:]):
    
            Tweaks to dragged image.
    
            * WebView.subproj/WebHTMLView.m:
            (-[WebHTMLView mouseDragged:]):
    
            Start using khtml's 'toAdd' parameter to justify text.
    
            * khtml/rendering/font.cpp:
            (Font::drawText):
    
            Normalize all calls to get width to minimize use of
            ObjC.  Will make it easier to use IMPL cache later.
    
            * kwq/KWQFontMetrics.mm:
            (QFontMetrics::width):
            (QFontMetrics::floatWidth):
            (QFontMetrics::floatCharacterWidth):
    
            Pass additional 'toAdd' parameter.
    
            * kwq/KWQPainter.mm:
            (QPainter::drawText):
            * kwq/qt/qpainter.h:
    
            Remove methods now that width calls are normalized to single
            method.
            * kwq/WebCoreTextRenderer.h:
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@1989 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    979d2676
    Added support for khtml's justified text drawing. Additional padding is distributed
    rjw authored
            to space widths.  (Sites like www.osnews.com now render correctly.)
    
            Change word end rounding hack to use ceil of word width.  I'm still noticing a spacing anomaly
            that is fixed by a reload.  Occasionally text runs are still crammed together, but a reload uses
            correct spacing.  This anomaly is often visible on www.arstechnica.com.  Still investigating.
    
            * WebCoreSupport.subproj/WebTextRenderer.m:
            (-[WebTextRenderer drawGlyphs:numGlyphs:fromGlyphPosition:toGlyphPosition:atPoint:withPadding:withTextColor:backgroundColor:]):
            (-[WebTextRenderer slowDrawCharacters:length:fromCharacterPosition:toCharacterPosition:atPoint:withPadding:withTextColor:backgroundColor:attemptFontSubstitution:]):
            (-[WebTextRenderer _drawCharacters:length:fromCharacterPosition:toCharacterPosition:atPoint:withPadding:withTextColor:backgroundColor:]):
            (-[WebTextRenderer drawCharacters:stringLength:fromCharacterPosition:toCharacterPosition:atPoint:withPadding:withTextColor:backgroundColor:]):
            (-[WebTextRenderer slowFloatWidthForCharacters:stringLength:fromCharacterPostion:numberOfCharacters:applyRounding:]):
            (-[WebTextRenderer floatWidthForCharacters:stringLength:fromCharacterPosition:numberOfCharacters:applyRounding:attemptFontSubstitution:]):
    
            Tweaks to dragged image.
    
            * WebView.subproj/WebHTMLView.m:
            (-[WebHTMLView mouseDragged:]):
    
            Start using khtml's 'toAdd' parameter to justify text.
    
            * khtml/rendering/font.cpp:
            (Font::drawText):
    
            Normalize all calls to get width to minimize use of
            ObjC.  Will make it easier to use IMPL cache later.
    
            * kwq/KWQFontMetrics.mm:
            (QFontMetrics::width):
            (QFontMetrics::floatWidth):
            (QFontMetrics::floatCharacterWidth):
    
            Pass additional 'toAdd' parameter.
    
            * kwq/KWQPainter.mm:
            (QPainter::drawText):
            * kwq/qt/qpainter.h:
    
            Remove methods now that width calls are normalized to single
            method.
            * kwq/WebCoreTextRenderer.h:
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@1989 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Loading