Shrink/Fit command-line options


#1

Hello,

I try to print a A3 paper on a A4 printer with the line-command option:
-print settings “fit”
The printing is working but the content is not full, it contains a A4 topright part of the A3 paper.
I have also tried with
-zoom = “fit content” or -zoom = “fit page”
and it is the same problem.
With the optiion:
-print settings “shrink”
It is not working (unable to init the printer).

Can you help me?
Thank a lot!

wadel


#2

@wadel
-print settings is not valid it must be -print-settings
you seem to be mixing pages and paper
for example you cannot print A3 paper on an A4 printer (unless you cut in half and use tape)
If you are printing A3 page on A4 paper you need -print-settings “shrink” (or use “fit” for smaller)
if you are printing A4 page on A3 paper you need -print-settings “fit” (for bigger or use “noscale”)
-zoom should not have any effect on printing from the command line


#3

Hello,
Thank you for your reply.
I have used -print-settings. it was a typing error,in the previous topic.
I have a problem when I’m printing A3 page in A4 printer with -print-settings “shrink”. I have mentioned it in the previous topic that it is not working, I have the SumatraPDF error message “Impossible d’initialiser l’imprimante” (“Can not initialize the printer”). See screenshot. Why ?
errorSumatraPDF


#4

Hello again,
the printer \elbsms104\elbpinf1 is working.
I use -print-to-default and it is the same result. See screenshot.


#5

It will because you are trying to access a network printer, there are several reasons why this may be an issue see



there are sugestions that the name needs to be changed to the ip value
192.168… 10.8. … or the printer needs to have a “shared printer” name and either way remote access rights may need to be checked


#6

Hello,

Hum…
c:\temp\sumatrapdf.exe -print-to “\elbsms104\elbpinf1” c:\temp\test_A4.pdf :
the A4 paper is working on the network printer

c:\temp\sumatrapdf.exe -print-to “\elbsms104\elbpinf1” c:\temp\test_A3.pdf :
the A3 paper is not working

I tried the A3 paper on a A3 network printer, it is working.
The network A4 printer is well recognized only if the A4 paper is printing…

sumatrapdf-prerelease-10766-64.exe or the use of printer IP adress give gives the same result.

Thank you for keeping me informed if you find a solution for me :slight_smile:


#7

In the case that you are not having a problem with name or rights but are having a problem with acceptable page size then the logical cause is file size, can you print to file the A3 should be double A4 in Kb (or more likely MB) then there are three issues
User rights to transmit so many data blocks
server / spool file / printer memory abilities to handle so much data
and network time outs related to either of those two.

One possible solution is to replace (only for CLI printing) a copy of SumatraPDF version 3.0 or 2.52 which normally produces smaller print files but can lead to other complaints about less control of CLI rotation and other format related issues.


#8

Hello,

I have tried the version 3.0 and the result is:

  • the printing of the A3/A4 paper on the A4 paper is working without -print-setting
  • the printing of the A4 is working on the A3 printer without -print-setting
  • the printing of the A3 paper isn’t well working on the A3 printer : the A4 format is used instead of the A3 format on the printer, I can’t force the A3 format with the parmater -print-settings “bin=#” (where #=1 or 2 or 3 or 4) or -print-settings “shrink” or “fit” or 'noscale".
    I have also tried the version 2.52 and it is the same problem.
    The version 3.1.2 is working for this A3 paper on the A3 printer…

Are-you an idea to resolve this problem?

Thank you.


#9

I think 3.0 should certainly work with A3 so it must be a syntax issue
how does your command differ from

SumatraPDF.exe -print-to “\elbsms104\elbpinf1” -print-settings “fit,paper=A3” “example.pdf”


#10

I have tried
c:\temp\sumatrapdf.exe -print-settings “paper=A3,fit” -print-to “\\elbsms104\elbpcpt1” “c:\temp\test_A3.pdf”
or
c:\temp\sumatrapdf.exe -print-settings “paper=A3,shrink” -print-to “\\elbsms104\elbpcpt1” “c:\temp\test_A3.pdf”
These two commandes give the priting in the A4 format :frowning:

Notify that the line command where -print-to is placed before -print-settings, such c:\temp\sumatrapdf.exe -print-to “…” -print-settings “…” “c:\temp\test_A3.pdf”, is not working. The error message is “Unale to print this file”.


#11

OK
the error message because of the order is odd, however that could be because of \ acting as some escape but in your original post you said simply using “shrink” gave a problem thus I have to suspect there is some driver communication issues however you can manage to print both sizes

Your prime issue is still down to the printer only using A4 by default ? (its windows default setting?)

In such cases I find the sure fire way to settle this is to have multiple copies of the driver with names I like
one may be “A4printerLand” with default settings for Landscape A4 paper another “A3printerPort” with default settings for Portrait A3 posters sending the correct input to each should work around any driver mismatch

It is important that you check in each case the settings for scaling so in the windows driver there should be preferences for page size rotation and scaling either as % or similar to [shrink | fit | none]


#12

Hello,
It is a good idea.
I can’t test it this week. I will keep you informed next week.
Thank.