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

Unified Diff: third_party/WebKit/public/web/WebPrintParams.h

Issue 2524143003: Print Preview: Add option to rasterize PDFs and add JPEG compression. (Closed)
Patch Set: Fix initialization Created 4 years 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 | « printing/printing_context.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/public/web/WebPrintParams.h
diff --git a/third_party/WebKit/public/web/WebPrintParams.h b/third_party/WebKit/public/web/WebPrintParams.h
index a28f836fd9ba7863f2a8a59a28e3093f170b76bc..70a99ce69d5113a731e690df29cf76199bcbffe7 100644
--- a/third_party/WebKit/public/web/WebPrintParams.h
+++ b/third_party/WebKit/public/web/WebPrintParams.h
@@ -51,12 +51,16 @@ struct WebPrintParams {
// Specifies user selected DPI for printing.
int printerDPI;
+ // Specifies whether to print PDFs as image.
+ bool rasterizePDF;
dcheng 2016/12/16 01:44:27 Consider just writing: bool rasterizePDF = false;
rbpotter 2016/12/20 22:41:04 Done.
+
// Specifies whether to reduce/enlarge/retain the print contents to fit the
// printable area. (This is used only by plugin printing).
WebPrintScalingOption printScalingOption;
WebPrintParams()
: printerDPI(72),
+ rasterizePDF(false),
printScalingOption(WebPrintScalingOptionFitToPrintableArea) {}
WebPrintParams(const WebSize& paperSize)
@@ -64,6 +68,7 @@ struct WebPrintParams {
printableArea(WebRect(0, 0, paperSize.width, paperSize.height)),
paperSize(paperSize),
printerDPI(72),
+ rasterizePDF(false),
printScalingOption(WebPrintScalingOptionSourceSize) {}
WebPrintParams(const WebRect& printContentArea,
@@ -75,6 +80,7 @@ struct WebPrintParams {
printableArea(printableArea),
paperSize(paperSize),
printerDPI(printerDPI),
+ rasterizePDF(false),
printScalingOption(printScalingOption) {}
};
« no previous file with comments | « printing/printing_context.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698