Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(164)

Unified Diff: Source/WebCore/platform/graphics/opentype/OpenTypeVerticalData.h

Issue 11299089: Merge 134871 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1312/
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/WebCore/platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/platform/graphics/opentype/OpenTypeVerticalData.h
===================================================================
--- Source/WebCore/platform/graphics/opentype/OpenTypeVerticalData.h (revision 135210)
+++ Source/WebCore/platform/graphics/opentype/OpenTypeVerticalData.h (working copy)
@@ -29,6 +29,8 @@
#include "Glyph.h"
#include <wtf/HashMap.h>
+#include <wtf/PassRefPtr.h>
+#include <wtf/RefCounted.h>
#include <wtf/Vector.h>
namespace WebCore {
@@ -37,9 +39,12 @@
class GlyphPage;
class SimpleFontData;
-class OpenTypeVerticalData {
+class OpenTypeVerticalData : public RefCounted<OpenTypeVerticalData> {
public:
- OpenTypeVerticalData(const FontPlatformData&);
+ static PassRefPtr<OpenTypeVerticalData> create(const FontPlatformData& platformData)
+ {
+ return adoptRef(new OpenTypeVerticalData(platformData));
+ }
bool isOpenType() const { return !m_advanceWidths.isEmpty(); }
bool hasVerticalMetrics() const { return !m_advanceHeights.isEmpty(); }
@@ -48,6 +53,8 @@
void substituteWithVerticalGlyphs(const SimpleFontData*, GlyphPage*, unsigned offset, unsigned length) const;
private:
+ explicit OpenTypeVerticalData(const FontPlatformData&);
+
void loadMetrics(const FontPlatformData&);
void loadVerticalGlyphSubstitutions(const FontPlatformData&);
bool hasVORG() const { return !m_vertOriginY.isEmpty(); }
« no previous file with comments | « Source/WebCore/platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698