bug-groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #62238] Add a PAPER_FLAG for groff when creating PostScript or PDF


From: G. Branden Robinson
Subject: [bug #62238] Add a PAPER_FLAG for groff when creating PostScript or PDF files
Date: Sat, 9 Apr 2022 21:41:57 -0400 (EDT)

Update of bug #62238 (project groff):

                Severity:              3 - Normal => 1 - Wish               
                  Status:                    None => Need Info              

    _______________________________________________________

Follow-up Comment #1:


[comment #0 original submission:]
> Subject: add a PAPER_FLAG for groff when creating PostScript or PDF
> files
> 
>   In the file "contrib/pdfmark/pdfmark.am" there is a flag
> "PDFMARK_PFLAG"

...not in groff Git HEAD or the groff 1.22.4 tag, there isn't.

Is this one of your customizations?

> to define the paper size with the options
> "-dpaper=$(PAGE) -P-p$(PAGE)" where "PAGE" is a configuration variable.

Yes, and since `PAGE` is a build-time macro defining the default paper size
for the formatter, it's superfluous to pass a `-dpaper` option to the
formatter to assign the same value.

The paper size used by the output driver is another matter, and discussed in
detail in the groff(1) man page.


   Paper size
       In GNU roff, the page dimensions for the formatter troff and for
       output devices are handled separately.  In the formatter,
       requests are used to set the page length (.pl), page offset (or
       left margin, .po), and line length (.ll).  The right margin is
       not explicitly configured; the combination of page offset and
       line length provides the information necessary to derive it.  The
       papersize macro package, automatically loaded by troff, provides
       an interface for configuring page dimensions by convenient names,
       like “letter” or “A4”; see groff_tmac(5).  The default used by
       the formatter depends on its build configuration; in this
       installation, it is “a4”.

       It is up to each macro package to respect the page dimensions
       configured in this way.  Some offer alternative mechanisms.

       For each output device, the size of the output medium can be set
       in its DESC file.  Most also recognize a command‐line option -p
       to override the default dimensions and an option -l to use
       landscape orientation.  See groff_font(5) for a description of
       the papersize directive, which takes an argument of the same form
       as -p.  The output driver’s man page, such as grops(1), may also
       be helpful.  groff uses the command‐line option -P to pass
       options to output devices; for example, use the following for
       PostScript output on A4 paper in landscape orientation.

              groff -Tps -dpaper=a4l -P-pa4 -P-l -ms foo.ms > foo.ps


What is deficient in this presentation?

>   These options should also be used for groff to define the (printer's) page
size
> for the output on discrete pages to synchronise the typesetting on a
> page and its expected size when printed.

Yes, that is what `-dpaper` and `-P-p` (where supported) are for. 
Manipulating these flags is what permits such synchronicity.

What is it you're asking for?


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?62238>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]