apimall / chromiumembedded

Automatically exported from code.google.com/p/chromiumembedded
0 stars 1 forks source link

CSS page size poorly supported #1465

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Open the CEF sample app using Windows.
2. Visit a site with @page{size:legal landscape;}
3. Print the page.

What is the expected output? What do you see instead?

I would expect the page to print legal-size, landscape. Instead, I see the page 
printing letter-size, with the content box legal-size, landscape.

It appears that the content is rendered at the size specified by @page{size} 
but the print settings are not set for the printer.

What version of the product are you using? On what operating system?

I tested on Windows 8 using both CEF 3.2171.1902 and CEF 3.2217.1922.

Please provide any additional information below.

Here is a simple data-uri to produce a test page. It is short enough you can 
paste it into the CEF sample app's URL field:

data:text/html,<html><style>@page{size:legal landscape;}</style><body><p>Bacon 
ipsum dolor amet salami capicola meatloaf, beef ribs biltong chuck sausage pork 
loin shoulder meatball ribeye.</p></body></html>

Original issue reported on code.google.com by cameron....@gmail.com on 1 Dec 2014 at 9:27

GoogleCodeExporter commented 9 years ago
How does it behave in Google Chrome version 39?

Original comment by magreenb...@gmail.com on 2 Dec 2014 at 12:20

GoogleCodeExporter commented 9 years ago
Using the Chrome print dialog, it gets the orientation right but uses whatever 
page size is specified manually.

Using the system print dialog, it uses the default orientation and page size. 
In other words it behaves exactly like CEF.

The Chrome "Save as PDF" option gets the orientation right and the page size 
right.

I was expecting this last behavior.

(I am trying to set the printer page size programmatically. I would normally do 
this by setting dmPaperSize on the Windows DEVMODE struct. Since this is not 
yet supported in CEF, I thought plain CSS could work.)

Original comment by cameron....@gmail.com on 2 Dec 2014 at 10:19

GoogleCodeExporter commented 9 years ago
CEF is transitioning from Google Code to Bitbucket project hosting. If you 
would like to continue receiving notifications on this issue please add 
yourself as a Watcher at the new location: 
https://bitbucket.org/chromiumembedded/cef/issue/1465

Original comment by magreenb...@gmail.com on 14 Mar 2015 at 3:36