haikuwebkit/LayoutTests/svg/custom/glyph-selection-arabic-form...

11 lines
722 B
Plaintext
Raw Permalink Normal View History

2012-02-09 Philip Rogers <pdr@google.com> Fix mirroring with SVG fonts https://bugs.webkit.org/show_bug.cgi?id=77067 Reviewed by Nikolas Zimmermann. SVG fonts were incorrectly handling mirrored characters in bidi text. In this change I added the function createStringWithMirroredCharacters which handles mirroring the characters when selecting glyphs for SVG fonts. I also made a small cosmetic change in the function charactersWithArabicForm, changing the bool parameter "mirror" to "rtl" which better reflects what it actually does. Several new tests were added to test mirroring with SVG fonts in the presence of Arabic forms and non-BMP characters. * platform/gtk/test_expectations.txt: * platform/win/test_expectations.txt: * svg/custom/glyph-selection-arabic-forms-expected.txt: Added. * svg/custom/glyph-selection-arabic-forms.svg: Added. * svg/custom/glyph-selection-bidi-mirror-expected.txt: Added. * svg/custom/glyph-selection-bidi-mirror.svg: Added. * svg/custom/glyph-selection-non-bmp-expected.png: Added. * svg/custom/glyph-selection-non-bmp-expected.txt: Added. * svg/custom/glyph-selection-non-bmp.svg: Added. 2012-02-09 Philip Rogers <pdr@google.com> Fix mirroring with SVG fonts https://bugs.webkit.org/show_bug.cgi?id=77067 Reviewed by Nikolas Zimmermann. SVG fonts were incorrectly handling mirrored characters in bidi text. In this change I added the function createStringWithMirroredCharacters which handles mirroring the characters when selecting glyphs for SVG fonts. I also made a small cosmetic change in the function charactersWithArabicForm, changing the bool parameter "mirror" to "rtl" which better reflects what it actually does. Several new tests were added to test mirroring with SVG fonts in the presence of Arabic forms and non-BMP characters. Tests: svg/custom/glyph-selection-arabic-forms.svg svg/custom/glyph-selection-bidi-mirror.svg svg/custom/glyph-selection-non-bmp.svg * platform/graphics/SVGGlyph.cpp: (WebCore::charactersWithArabicForm): * svg/SVGFontData.cpp: (WebCore::SVGFontData::applySVGGlyphSelection): (WebCore::SVGFontData::createStringWithMirroredCharacters): * svg/SVGFontData.h: (SVGFontData): Canonical link: https://commits.webkit.org/95118@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@107211 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-02-09 11:40:53 +00:00
layer at (0,0) size 800x600
RenderView at (0,0) size 800x600
layer at (0,0) size 400x50
RenderSVGRoot {svg} at (10,7) size 348x18
2012-02-09 Philip Rogers <pdr@google.com> Fix mirroring with SVG fonts https://bugs.webkit.org/show_bug.cgi?id=77067 Reviewed by Nikolas Zimmermann. SVG fonts were incorrectly handling mirrored characters in bidi text. In this change I added the function createStringWithMirroredCharacters which handles mirroring the characters when selecting glyphs for SVG fonts. I also made a small cosmetic change in the function charactersWithArabicForm, changing the bool parameter "mirror" to "rtl" which better reflects what it actually does. Several new tests were added to test mirroring with SVG fonts in the presence of Arabic forms and non-BMP characters. * platform/gtk/test_expectations.txt: * platform/win/test_expectations.txt: * svg/custom/glyph-selection-arabic-forms-expected.txt: Added. * svg/custom/glyph-selection-arabic-forms.svg: Added. * svg/custom/glyph-selection-bidi-mirror-expected.txt: Added. * svg/custom/glyph-selection-bidi-mirror.svg: Added. * svg/custom/glyph-selection-non-bmp-expected.png: Added. * svg/custom/glyph-selection-non-bmp-expected.txt: Added. * svg/custom/glyph-selection-non-bmp.svg: Added. 2012-02-09 Philip Rogers <pdr@google.com> Fix mirroring with SVG fonts https://bugs.webkit.org/show_bug.cgi?id=77067 Reviewed by Nikolas Zimmermann. SVG fonts were incorrectly handling mirrored characters in bidi text. In this change I added the function createStringWithMirroredCharacters which handles mirroring the characters when selecting glyphs for SVG fonts. I also made a small cosmetic change in the function charactersWithArabicForm, changing the bool parameter "mirror" to "rtl" which better reflects what it actually does. Several new tests were added to test mirroring with SVG fonts in the presence of Arabic forms and non-BMP characters. Tests: svg/custom/glyph-selection-arabic-forms.svg svg/custom/glyph-selection-bidi-mirror.svg svg/custom/glyph-selection-non-bmp.svg * platform/graphics/SVGGlyph.cpp: (WebCore::charactersWithArabicForm): * svg/SVGFontData.cpp: (WebCore::SVGFontData::applySVGGlyphSelection): (WebCore::SVGFontData::createStringWithMirroredCharacters): * svg/SVGFontData.h: (SVGFontData): Canonical link: https://commits.webkit.org/95118@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@107211 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-02-09 11:40:53 +00:00
RenderSVGHiddenContainer {defs} at (0,0) size 0x0
RenderSVGContainer {g} at (10,7) size 348x18
RenderSVGText {text} at (10,7) size 348x18 contains 1 chunk(s)
RenderSVGInlineText {#text} at (0,0) size 348x18
chunk 1 text run 1 at (10.00,20.00) startOffset 0 endOffset 56 width 340.79 RTL: "\x{62E}] [\x{62E}][\x{62E}][\x{62E}] | [\x{62E}] [\x{62E}\x{62E}][\x{62E}] | [\x{62E}] [\x{62E}\x{62E}\x{62E}] | [\x{62E} \x{62E}\x{62E}\x{62E}] | \x{62E} \x{62E}\x{62E}\x{62E}"
chunk 1 text run 1 at (350.79,20.00) startOffset 0 endOffset 1 width 6.88: "]"