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

Unified Diff: content/common/dwrite_font_proxy_messages.h

Issue 1846433005: Implement direct write fallback proxy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add a missing SUCCEEDED call Created 4 years, 8 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/common/dwrite_font_proxy_messages.h
diff --git a/content/common/dwrite_font_proxy_messages.h b/content/common/dwrite_font_proxy_messages.h
index cc8aced1dec3a14f2452cba92d6a7c900e3a1cb0..288a3cf0d05cb300b8ff35a0499e567997b3afed 100644
--- a/content/common/dwrite_font_proxy_messages.h
+++ b/content/common/dwrite_font_proxy_messages.h
@@ -23,6 +23,20 @@ typedef std::pair<base::string16, base::string16> DWriteStringPair;
#endif // CONTENT_COMMON_DWRITE_FONT_PROXY_MESSAGES_H_
+IPC_STRUCT_BEGIN(DWriteFontStyle)
+ IPC_STRUCT_MEMBER(uint16_t, font_weight)
+ IPC_STRUCT_MEMBER(uint8_t, font_slant)
+ IPC_STRUCT_MEMBER(uint8_t, font_stretch)
+IPC_STRUCT_END()
+
+IPC_STRUCT_BEGIN(MapCharactersResult)
+ IPC_STRUCT_MEMBER(uint32_t, family_index)
+ IPC_STRUCT_MEMBER(base::string16, family_name)
+ IPC_STRUCT_MEMBER(uint32_t, mapped_length)
+ IPC_STRUCT_MEMBER(float, scale)
+ IPC_STRUCT_MEMBER(DWriteFontStyle, font_style)
+IPC_STRUCT_END()
+
// Locates the index of the specified font family within the system collection.
IPC_SYNC_MESSAGE_CONTROL1_1(DWriteFontProxyMsg_FindFamily,
base::string16 /* family_name */,
@@ -44,3 +58,18 @@ IPC_SYNC_MESSAGE_CONTROL1_1(
IPC_SYNC_MESSAGE_CONTROL1_1(DWriteFontProxyMsg_GetFontFiles,
uint32_t /* family_index */,
std::vector<base::string16> /* out file_paths */)
+
+// Locates a font family that is able to render the specified text using the
+// specified style. If successful, the family_index and family_name will
+// indicate which family in the system font collection can render the requested
+// text and the mapped_length will indicate how many characters can be
+// rendered. If no font exists that can render the text, family_index will be
+// UINT32_MAX and mapped_length will indicate how many characters cannot be
+// rendered by any installed font.
+IPC_SYNC_MESSAGE_CONTROL5_1(DWriteFontProxyMsg_MapCharacters,
+ base::string16 /* text */,
+ DWriteFontStyle /* font_style */,
+ base::string16 /* locale_name */,
+ uint32_t /* reading_direction */,
+ base::string16 /* base_family_name - optional */,
+ MapCharactersResult /* out */)
« no previous file with comments | « content/child/dwrite_font_proxy/font_fallback_win_unittest.cc ('k') | content/common/dwrite_text_analysis_source_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698