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

Unified Diff: ui/gfx/font_fallback.h

Issue 2927953003: Use CTFontCreateForString for RenderTextHarfbuzz on Mac (Closed)
Patch Set: Fix views::Label tests Created 3 years, 6 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
« no previous file with comments | « no previous file | ui/gfx/font_fallback_mac.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/font_fallback.h
diff --git a/ui/gfx/font_fallback.h b/ui/gfx/font_fallback.h
index d0d838f9574ac362a5ac6cdb825d2bac5b6d2f7f..2e5d50add67b7ccc85c9624a537e361bcc8cf5a3 100644
--- a/ui/gfx/font_fallback.h
+++ b/ui/gfx/font_fallback.h
@@ -7,6 +7,8 @@
#include <vector>
+#include "base/strings/string16.h"
+#include "build/build_config.h"
#include "ui/gfx/font.h"
#include "ui/gfx/gfx_export.h"
@@ -17,6 +19,18 @@ class Font;
// Given a font, returns the fonts that are suitable for fallback.
GFX_EXPORT std::vector<Font> GetFallbackFonts(const Font& font);
+#if defined(OS_MACOSX) || defined(OS_WIN)
+
+// Finds a fallback font to render the specified |text| with respect to an
+// initial |font|. Returns the resulting font via out param |result|. Returns
+// |true| if a fallback font was found.
+bool GFX_EXPORT GetFallbackFont(const Font& font,
+ const base::char16* text,
+ int text_length,
+ Font* result);
+
+#endif
+
} // namespace gfx
#endif // UI_GFX_FONT_FALLBACK_H_
« no previous file with comments | « no previous file | ui/gfx/font_fallback_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698