<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Add support for printing to a Windows printer from pdftocairo"
href="https://bugs.freedesktop.org/show_bug.cgi?id=79936#c20">Comment # 20</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Add support for printing to a Windows printer from pdftocairo"
href="https://bugs.freedesktop.org/show_bug.cgi?id=79936">bug 79936</a>
from <span class="vcard"><a class="email" href="mailto:ajohnson@redneon.com" title="Adrian Johnson <ajohnson@redneon.com>"> <span class="fn">Adrian Johnson</span></a>
</span></b>
<pre>(In reply to <a href="show_bug.cgi?id=79936#c18">comment #18</a>)
<span class="quote">> > I also noticed in the documentation for DocumentProperties() at
> > <a href="http://msdn.microsoft.com/en-us/library/windows/desktop/dd183576%28v=vs">http://msdn.microsoft.com/en-us/library/windows/desktop/dd183576%28v=vs</a>.
> > 85%29.aspx
> > that we are not doing step 5 in the "To make changes to print settings that
> > are local to an application, an application should follow these steps:"
> > section. It seems to work without the extra call to DocumentProperties() but
> > I am wondering if we should do exactly what the documentation says to do to
> > change the print settings.
>
> Interesting... I really don't what is this last call for. Maybe it is for
> user selection validation, or something like that. But that could easily
> been done at `CreateDC()`...</span >
I found another interesting example:
<a href="http://support.microsoft.com/kb/167345/en-us">http://support.microsoft.com/kb/167345/en-us</a>
I suggest we use this as a template for modifying the print settings.
<span class="quote">> But now that we are into it, would it make sense to add a CLI option to show
> the printer property sheet? That is, to call `DocumentProperties()` with the
> `DM_IN_PROMPT` flag. I think that it could be done easily. Add the call from
> step 5 of the reference doc, but just add the `DM_IN_PROMPT` flag iff the
> `-prnproperties` (or whatever) option is used.</span >
Interesting. But I would take it one step further and display the print dialog.
Then the user can select the printer as well as change the print settings. eg
-printdlg opens the print dialog.
One problem would be the page size selection. On the command line not
specifying the paper size means use whatever page size is in the PDF. This also
supports printing PDFs with different page sizes (assuming the printer also has
the different paper sizes available). Using the print dialog would require
adding an extra option to the dialog to specify "select paper size using PDF
page size".
I found another issue with the code. I don't like the names of the duplex
options "simplex", "horizontal", and "vertical". Most print dialogs I've seen
use options like "one sided" or "off", "long edge" and "short edge". I suggest
we use the names "off", "long", and "short".</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>