Changeset 96404 in webkit
- Timestamp:
- Sep 30, 2011 10:05:22 AM (13 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r96403 r96404 1 2011-09-30 Ned Holbrook <nholbrook@apple.com> 2 3 Complex spaces with synthetic bold are too wide 4 https://bugs.webkit.org/show_bug.cgi?id=69033 5 6 Reviewed by Dan Bernstein. 7 8 * fast/text/complex-synthetic-bold-space-width.html: Added. 9 * platform/mac/fast/text/atsui-multiple-renderers-expected.png: 10 * platform/mac/fast/text/atsui-multiple-renderers-expected.txt: 11 * platform/mac/fast/text/complex-synthetic-bold-space-width-expected.png: Added. 12 * platform/mac/fast/text/complex-synthetic-bold-space-width-expected.txt: Added. 13 1 14 2011-09-30 Antaryami Pandia <antaryami.pandia@motorola.com> 2 15 -
trunk/LayoutTests/platform/mac/fast/text/atsui-multiple-renderers-expected.txt
r78867 r96404 36 36 RenderTableRow {TR} at (0,30) size 262x30 37 37 RenderTableCell {TD} at (0,30) size 131x30 [border: (1px solid #008000)] [r=1 c=0 rs=1 cs=1] 38 RenderText {#text} at (2,3) size 7 6x2539 text run at (2,3) width 7 6: "Lore\x{300}m "38 RenderText {#text} at (2,3) size 75x25 39 text run at (2,3) width 75: "Lore\x{300}m " 40 40 RenderInline {SPAN} at (0,0) size 53x23 41 RenderText {#text} at (7 8,5) size 53x2342 text run at (7 8,5) width 53: "ipsu\x{308}m"41 RenderText {#text} at (77,5) size 53x23 42 text run at (77,5) width 53: "ipsu\x{308}m" 43 43 RenderText {#text} at (0,0) size 0x0 44 44 RenderTableCell {TD} at (131,30) size 131x30 [border: (1px solid #008000)] [r=1 c=1 rs=1 cs=1] … … 66 66 RenderTableRow {TR} at (0,90) size 262x30 67 67 RenderTableCell {TD} at (0,90) size 131x30 [border: (1px solid #008000)] [r=3 c=0 rs=1 cs=1] 68 RenderText {#text} at (2,3) size 7 6x2569 text run at (2,3) width 7 6: "Lore\x{300}m "68 RenderText {#text} at (2,3) size 75x25 69 text run at (2,3) width 75: "Lore\x{300}m " 70 70 RenderInline {SPAN} at (0,0) size 51x23 71 RenderText {#text} at (7 8,5) size 51x2372 text run at (7 8,5) width 51: "ipsu\x{308}m"71 RenderText {#text} at (77,5) size 51x23 72 text run at (77,5) width 51: "ipsu\x{308}m" 73 73 RenderText {#text} at (0,0) size 0x0 74 74 RenderTableCell {TD} at (131,90) size 131x30 [border: (1px solid #008000)] [r=3 c=1 rs=1 cs=1] -
trunk/Source/WebCore/ChangeLog
r96398 r96404 1 2011-09-30 Ned Holbrook <nholbrook@apple.com> 2 3 Complex spaces with synthetic bold are too wide 4 https://bugs.webkit.org/show_bug.cgi?id=69033 5 6 Reviewed by Dan Bernstein. 7 8 Test: fast/text/complex-synthetic-bold-space-width.html 9 10 * platform/graphics/mac/ComplexTextController.cpp: 11 (WebCore::ComplexTextController::adjustGlyphsAndAdvances): Subtract synthetic bold offset from spaceWidth. 12 * platform/graphics/win/UniscribeController.cpp: 13 (WebCore::UniscribeController::shapeAndPlaceItem): Ditto. 14 1 15 2011-09-30 Pavel Feldman <pfeldman@google.com> 2 16 -
trunk/Source/WebCore/platform/graphics/mac/ComplexTextController.cpp
r95901 r96404 478 478 bool lastRun = r + 1 == runCount; 479 479 bool roundsAdvances = !m_font.isPrinterFont() && fontData->platformData().roundsGlyphAdvances(); 480 CGFloat roundedSpaceWidth = roundCGFloat(fontData->spaceWidth()); 480 float spaceWidth = fontData->spaceWidth() - fontData->syntheticBoldOffset(); 481 CGFloat roundedSpaceWidth = roundCGFloat(spaceWidth); 481 482 const UChar* cp = complexTextRun.characters(); 482 483 CGPoint glyphOrigin = CGPointZero; … … 505 506 bool treatAsSpace = Font::treatAsSpace(ch); 506 507 CGGlyph glyph = treatAsSpace ? fontData->spaceGlyph() : glyphs[i]; 507 CGSize advance = treatAsSpace ? CGSizeMake( fontData->spaceWidth(), advances[i].height) : advances[i];508 CGSize advance = treatAsSpace ? CGSizeMake(spaceWidth, advances[i].height) : advances[i]; 508 509 509 510 if (ch == '\t' && m_run.allowTabs()) { -
trunk/Source/WebCore/platform/graphics/win/UniscribeController.cpp
r88277 r96404 267 267 268 268 const float cLogicalScale = fontData->platformData().useGDI() ? 1.0f : 32.0f; 269 unsigned logicalSpaceWidth = fontData->spaceWidth() * cLogicalScale;270 float spaceWidth = fontData->spaceWidth();269 float spaceWidth = fontData->spaceWidth() - fontData->syntheticBoldOffset(); 270 unsigned logicalSpaceWidth = spaceWidth * cLogicalScale; 271 271 272 272 for (int k = 0; k < len; k++) {
Note: See TracChangeset
for help on using the changeset viewer.