2

enter image description here

I am looking for something like this:

SetOptions[EvaluationNotebook[], "PaperSize" -> "A3"]

The options are listed, but where do I find the arguments? Say for A3 paper, do I use A3 or "A3" or "a3paper"?

and it looks like it takes two inputs? How?

I can change them everytime from the drop down menu, but it's not very efficient.

Chen Stats Yu
  • 4,986
  • 2
  • 24
  • 50

2 Answers2

2

According to this A3 is {842, 1190} printers points, so to set that and a variety of print related options programmatically:

SetOptions[EvaluationNotebook[],
 RulerUnits -> "Points",
  PageHeaders -> {{
        Cell[
          TextData[{
              CounterBox["Page"]}], "PageNumber"], 
        Cell[
          TextData[{"Author"}], "Header"], None}, {None, 
        Cell[
          TextData["Article title"], "Header"], 
        Cell[
          TextData[{
              CounterBox["Page"]}], "PageNumber"]}},
  PageFooters -> {{None, None, None}, {None, None, None}},
  PageHeaderLines -> {False, False},
  PrintingOptions -> {"FacingPages" -> True,
    "FirstPageFace" -> Right,
    "FirstPageFooter" -> True,
    "FirstPageHeader" -> False,
    "Magnification" -> 1,
    "PageFooterMargins" -> {30, 30},
    "PageHeaderMargins" -> {60, 60},
    "PageSize" -> {842, 1190},
    "PaperSize" -> {842, 1190},
    "PrintCellBrackets" -> False,
    "PrintRegistrationMarks" -> False,
    "PrintingMargins" -> {{90, 90}, {60, 90}}}
 ]
Mike Honeychurch
  • 37,541
  • 3
  • 85
  • 158
1

This should get you started for A3:

SetOptions[EvaluationNotebook[], 
 PrintingOptions -> {"PaperSize" -> 
  Round[72*
   QuantityMagnitude@
    UnitConvert[Quantity[#, "Millimeters"] & /@ {2*210, 297}, 
     "Inches"]]}]

Background

Mathematica assumes 72pt per inch for the PaperSize-option. The example above just uses the Quantity functionality for conversion from the DIN-dimensions (I used the equivalent of two A4 sheets for reference).

Be aware, though, that the PrintingOptions feature might change in the future (see the online reference for that warning).

Jinxed
  • 3,753
  • 10
  • 24