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

Unified Diff: chrome/common/chrome_switches.cc

Issue 2503663002: Printing: Add command line switch to rendering text with GDI. (Closed)
Patch Set: Sort Created 4 years, 1 month 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 | « chrome/common/chrome_switches.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/chrome_switches.cc
diff --git a/chrome/common/chrome_switches.cc b/chrome/common/chrome_switches.cc
index 7336c235939dc234307523b74b3881446017f9a7..d7f97920703f0f77a6b8b4ec81b37f903a11bcc9 100644
--- a/chrome/common/chrome_switches.cc
+++ b/chrome/common/chrome_switches.cc
@@ -1183,7 +1183,7 @@ const char kMakeChromeDefault[] = "make-chrome-default";
#if defined(OS_WIN)
// Disables using GDI to print text as simply text. Fallback to printing text
-// as paths.
+// as paths. Overrides --enable-gdi-text-printing.
const char kDisableGDITextPrinting[] = "disable-gdi-text-printing";
// Disables per monitor DPI for supported Windows versions.
@@ -1193,6 +1193,9 @@ const char kDisablePerMonitorDpi[] = "disable-per-monitor-dpi";
// Fallback to XPS. By default connector uses CDD.
const char kEnableCloudPrintXps[] = "enable-cloud-print-xps";
+// Enables using GDI to print text as simply text.
+const char kEnableGDITextPrinting[] = "enable-gdi-text-printing";
+
// Enables per monitor DPI for supported Windows versions.
const char kEnablePerMonitorDpi[] = "enable-per-monitor-dpi";
@@ -1307,6 +1310,15 @@ bool PowerOverlayEnabled() {
}
#endif
+#if defined(OS_WIN)
+bool GDITextPrintingEnabled() {
+ const auto& command_line = *base::CommandLine::ForCurrentProcess();
+ if (command_line.HasSwitch(kDisableGDITextPrinting))
+ return false;
+ return command_line.HasSwitch(kEnableGDITextPrinting);
+}
+#endif
+
// -----------------------------------------------------------------------------
// DO NOT ADD YOUR VERY NICE FLAGS TO THE BOTTOM OF THIS FILE.
//
« no previous file with comments | « chrome/common/chrome_switches.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698