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

Unified Diff: chrome/renderer/print_web_view_helper_win.cc

Issue 6879098: Fix print preview clipping issues due to scaling. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Fix mac build. Created 9 years, 8 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_mac.mm ('k') | chrome/utility/utility_thread.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/print_web_view_helper_win.cc
===================================================================
--- chrome/renderer/print_web_view_helper_win.cc (revision 83537)
+++ chrome/renderer/print_web_view_helper_win.cc (working copy)
@@ -207,10 +207,12 @@
}
gfx::Size page_size(width, height);
- gfx::Point content_origin(static_cast<int>(margin_left_in_points),
- static_cast<int>(margin_top_in_points));
+ gfx::Rect content_area(static_cast<int>(margin_left_in_points),
+ static_cast<int>(margin_top_in_points),
+ static_cast<int>(content_width_in_points),
+ static_cast<int>(content_height_in_points));
skia::PlatformDevice* device = (*metafile)->StartPageForVectorCanvas(
- page_size, content_origin, frame->getPrintPageShrink(page_number));
+ page_size, content_area, frame->getPrintPageShrink(page_number));
DCHECK(device);
skia::VectorCanvas canvas(device);
« no previous file with comments | « chrome/renderer/print_web_view_helper_mac.mm ('k') | chrome/utility/utility_thread.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698