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

Unified Diff: content/renderer/fontmgr_proxy.h

Issue 132113015: IPC interface for font management. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Match final interface and cleanup usage. Created 6 years, 9 months 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
Index: content/renderer/fontmgr_proxy.h
===================================================================
--- content/renderer/fontmgr_proxy.h (revision 0)
+++ content/renderer/fontmgr_proxy.h (working copy)
@@ -0,0 +1,48 @@
+// Copyright (c) 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_RENDERER_FONTMGR_PROXY_H
+#define CONTENT_RENDERER_FONTMGR_PROXY_H
+
+#include "base/values.h"
+#include "third_party/skia/include/ports/SkRemotableFontMgr.h"
+
+class SkDataTable;
+class SkStreamAsset;
+
+namespace content {
+
+class CONTENT_EXPORT FontMgrProxy : public SkRemotableFontMgr {
+ public:
+ // If we support multiple of these at the same time, this constructor
+ // could take a parameter stating which one to talk to.
+ // There could even be some statics for getting the available ones.
+ FontMgrProxy() { }
+ virtual ~FontMgrProxy() { }
+
+ virtual SkDataTable* getFamilyNames() const OVERRIDE;
+
+ virtual SkRemotableFontIdentitySet* getIndex(int family_index) const OVERRIDE;
+
+ virtual SkFontIdentity matchIndexStyle(int family_index,
+ const SkFontStyle&) const OVERRIDE;
+
+ virtual SkRemotableFontIdentitySet* matchName(
+ const char family_name[]) const OVERRIDE;
+
+ virtual SkFontIdentity matchNameStyle(const char family_name[],
+ const SkFontStyle&) const OVERRIDE;
+
+ virtual SkFontIdentity matchNameStyleCharacter(const char family_name[],
+ const SkFontStyle&,
+ const char bpc47[],
+ SkUnichar character) const
+ OVERRIDE;
+
+ virtual SkStreamAsset* getData(int data_id) const OVERRIDE;
+};
+
+} // namespace content
+
+#endif // CONTENT_RENDERER_FONTMGR_PROXY_H

Powered by Google App Engine
This is Rietveld 408576698