diff options
author | sanjeevr@chromium.org <sanjeevr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-29 07:18:29 +0000 |
---|---|---|
committer | sanjeevr@chromium.org <sanjeevr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-05-29 07:18:29 +0000 |
commit | 6ab86acd95c830be779fdddbbc1230e8b73c21bc (patch) | |
tree | 0513fe4fa922c08856287caa0d1d48a7fb6c751f /printing/printed_document_win.cc | |
parent | a93885094715c2d23953f9139d61e1071d8006a5 (diff) | |
download | chromium_src-6ab86acd95c830be779fdddbbc1230e8b73c21bc.zip chromium_src-6ab86acd95c830be779fdddbbc1230e8b73c21bc.tar.gz chromium_src-6ab86acd95c830be779fdddbbc1230e8b73c21bc.tar.bz2 |
Changed printer page setup units to be in device co-ordinates (this is pixels on Windows and points on the Mac). Also fixed a bug with Mac dpi calculation.
BUG=None.
TEST=Test printing on Windows and Mac.
Review URL: http://codereview.chromium.org/2351003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48558 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'printing/printed_document_win.cc')
-rw-r--r-- | printing/printed_document_win.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/printing/printed_document_win.cc b/printing/printed_document_win.cc index 0c17201..42c1b45 100644 --- a/printing/printed_document_win.cc +++ b/printing/printed_document_win.cc @@ -50,7 +50,7 @@ void PrintedDocument::RenderPrintedPage( #endif const printing::PageSetup& page_setup( - immutable_.settings_.page_setup_pixels()); + immutable_.settings_.page_setup_device_units()); // Save the state to make sure the context this function call does not modify // the device context. @@ -116,7 +116,7 @@ void PrintedDocument::RenderPrintedPage( int base_font_size = gfx::Font().height(); int new_font_size = ConvertUnit(10, immutable_.settings_.desired_dpi, - immutable_.settings_.dpi()); + immutable_.settings_.device_units_per_inch()); DCHECK_GT(new_font_size, base_font_size); gfx::Font font(gfx::Font().DeriveFont(new_font_size - base_font_size)); HGDIOBJ old_font = SelectObject(context, font.hfont()); |