[Webkit-unassigned] [Bug 157066] REGRESSION(r200094): [FreeType] Vertical text is broken after r200094

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Apr 27 07:50:14 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=157066

Martin Robinson <mrobinson at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #277470|review?                     |review+
              Flags|                            |

--- Comment #9 from Martin Robinson <mrobinson at webkit.org> ---
Comment on attachment 277470
  --> https://bugs.webkit.org/attachment.cgi?id=277470
Try to fix EFL build

View in context: https://bugs.webkit.org/attachment.cgi?id=277470&action=review

> Source/WebCore/platform/graphics/cairo/CairoUtilities.h:64
> +#if USE(FREETYPE)
> +class CairoFtFaceLocker {
> +public:
> +    CairoFtFaceLocker(cairo_scaled_font_t*);
> +    ~CairoFtFaceLocker();
> +
> +    FT_Face ftFace() const { return m_ftFace; }
> +
> +private:
> +    cairo_scaled_font_t* m_scaledFont { nullptr };
> +    FT_Face m_ftFace { nullptr };
> +};

One note is that by not putting the implementation of the constructor and destructor here, it is impossible for the compiler to inline them. It might be better to avoid changing that.

> Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp:253
> +    // We need to reinitialize the instance, because the difference in size
> +    // necessitates a new scaled font instance.
> +    ASSERT(copy.m_scaledFont.get());
> +    copy.buildScaledFont(cairo_scaled_font_get_font_face(copy.m_scaledFont.get()));

Why don't you also check if the size is different here similar to the methods above?

> Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp:291
> -    return m_scaledFont == other.m_scaledFont
> -        && m_size == other.m_size
> -        && m_syntheticOblique == other.m_syntheticOblique
> -        && m_orientation == other.m_orientation
> -        && m_syntheticBold == other.m_syntheticBold; 
> +    return m_scaledFont == other.m_scaledFont;
>  }

Yay!

> Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp:349
> +    ASSERT(m_scaledFont.get());

I'm not sure you need .get() here.

> Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp:-412
> -    cairo_ft_scaled_font_unlock_face(m_scaledFont);

Wow. Really nice fix here.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160427/ad28ab04/attachment.html>


More information about the webkit-unassigned mailing list