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

Unified Diff: printing/pdf_ps_metafile_cairo.h

Issue 2847025: Implement limited paged media support for linux. (Closed)
Patch Set: disallow non-positive content area Created 10 years, 6 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 | « chrome/renderer/print_web_view_helper_linux.cc ('k') | printing/pdf_ps_metafile_cairo.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: printing/pdf_ps_metafile_cairo.h
diff --git a/printing/pdf_ps_metafile_cairo.h b/printing/pdf_ps_metafile_cairo.h
index 8027188419e437350a4c511acf99f0dc54237e4a..24b5d36784797aa7a7cc05cba3d5ac4d4330c858 100644
--- a/printing/pdf_ps_metafile_cairo.h
+++ b/printing/pdf_ps_metafile_cairo.h
@@ -53,7 +53,12 @@ class PdfPsMetafile {
// Prepares a new cairo surface/context for rendering a new page.
// The unit is in point (=1/72 in).
// Returns NULL when failed.
- cairo_t* StartPage(double width, double height);
+ cairo_t* StartPage(double width_in_points,
+ double height_in_points,
+ double margin_top_in_points,
+ double margin_right_in_points,
+ double margin_bottom_in_points,
+ double margin_left_in_points);
// Destroys the surface and the context used in rendering current page.
// The results of current page will be appended into buffer |data_|.
@@ -79,10 +84,10 @@ class PdfPsMetafile {
// The hardcoded margins, in points. These values are based on 72 dpi,
// with 0.25 margins on top, left, and right, and 0.56 on bottom.
- static const double kTopMargin;
- static const double kRightMargin;
- static const double kBottomMargin;
- static const double kLeftMargin;
+ static const double kTopMarginInInch;
+ static const double kRightMarginInInch;
+ static const double kBottomMarginInInch;
+ static const double kLeftMarginInInch;
private:
// Cleans up all resources.
« no previous file with comments | « chrome/renderer/print_web_view_helper_linux.cc ('k') | printing/pdf_ps_metafile_cairo.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698