Add build configuration for experimental Windows GDI code. BUG=409472 Review-Url: https://codereview.chromium.org/2193783002
diff --git a/BUILD.gn b/BUILD.gn index 872baf7..f7a6007 100644 --- a/BUILD.gn +++ b/BUILD.gn
@@ -30,6 +30,10 @@ if (pdf_enable_xfa) { defines += [ "PDF_ENABLE_XFA" ] } + + if (pdf_use_win32_gdi) { + defines += [ "PDFIUM_PRINT_TEXT_WITH_GDI" ] + } } config("pdfium_core_config") {
diff --git a/build_overrides/pdfium.gni b/build_overrides/pdfium.gni index 246671b..f3cddb7 100644 --- a/build_overrides/pdfium.gni +++ b/build_overrides/pdfium.gni
@@ -12,3 +12,6 @@ # Build PDFium against skia (experimental) rather than agg. pdf_use_skia_override = false + +# Build PDFium either with or without experimental win32 GDI APIs. +pdf_use_win32_gdi_override = false
diff --git a/pdfium.gni b/pdfium.gni index 9e20f96..ede452f 100644 --- a/pdfium.gni +++ b/pdfium.gni
@@ -20,6 +20,9 @@ # Build PDFium against skia (experimental) rather than agg. pdf_use_skia = pdf_use_skia_override + # Build PDFium with or without experimental win32 GDI APIs. + pdf_use_win32_gdi = pdf_use_win32_gdi_override + # Build PDFium standalone pdf_is_standalone = false }
diff --git a/pdfium.gyp b/pdfium.gyp index 3a3c71e..fe2d176 100644 --- a/pdfium.gyp +++ b/pdfium.gyp
@@ -8,6 +8,7 @@ 'pdf_use_skia%': 0, 'pdf_enable_v8%': 1, 'pdf_enable_xfa%': 0, # Set to 1 by standalone.gypi in a standalone build. + 'pdf_use_win32_gdi%': 0, 'variables': { 'clang_use_chrome_plugins': 1, }, @@ -44,6 +45,9 @@ ['pdf_enable_xfa==1', { 'defines': ['PDF_ENABLE_XFA'], }], + ['pdf_use_win32_gdi==1', { + 'defines': ['PDFIUM_PRINT_TEXT_WITH_GDI'], + }], ['OS=="linux"', { 'conditions': [ ['target_arch=="x64"', {