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

Unified Diff: public/fpdfview.h

Issue 2113563003: Implement CGdiPrinterDriver::DrawDeviceText(). (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: rebase Created 4 years, 5 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 | « fpdfsdk/fpdfview.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/fpdfview.h
diff --git a/public/fpdfview.h b/public/fpdfview.h
index cea431a498378c3d7b29b67584881a9f47260b67..cbb577b2fd476c93b05dc9960112722de2dfcc14 100644
--- a/public/fpdfview.h
+++ b/public/fpdfview.h
@@ -211,6 +211,34 @@ DLLEXPORT void STDCALL FPDF_DestroyLibrary();
DLLEXPORT void STDCALL FPDF_SetSandBoxPolicy(FPDF_DWORD policy,
FPDF_BOOL enable);
+#if defined(_WIN32) && defined(PDFIUM_PRINT_TEXT_WITH_GDI)
+// Pointer to a helper function to make |font| with |text| of |text_length|
+// accessible when printing text with GDI. This is useful in sandboxed
+// environments where PDFium's access to GDI may be restricted.
+typedef void (*PDFiumEnsureTypefaceCharactersAccessible)(const LOGFONT* font,
+ const wchar_t* text,
+ size_t text_length);
+
+// Function: FPDF_SetTypefaceAccessibleFunc
+// Set the function pointer that makes GDI fonts available in sandboxed
+// environments. Experimental API.
+// Parameters:
+// func - A function pointer. See description above.
+// Return value:
+// None.
+DLLEXPORT void STDCALL
+FPDF_SetTypefaceAccessibleFunc(PDFiumEnsureTypefaceCharactersAccessible func);
+
+// Function: FPDF_SetPrintTextWithGDI
+// Set whether to use GDI to draw fonts when printing on Windows.
+// Experimental API.
+// Parameters:
+// use_gdi - Set to true to enable printing text with GDI.
+// Return value:
+// None.
+DLLEXPORT void STDCALL FPDF_SetPrintTextWithGDI(FPDF_BOOL use_gdi);
+#endif
+
// Function: FPDF_LoadDocument
// Open and load a PDF document.
// Parameters:
« no previous file with comments | « fpdfsdk/fpdfview.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698