Adding a new keyword `papersize' to the DESC file format (similar
commit14a3a47465a19a986ae43f80e1fca76c7ae4e17e
authorWerner LEMBERG <wl@gnu.org>
Sun, 2 Jun 2002 07:53:30 +0000 (2 07:53 +0000)
committerWerner LEMBERG <wl@gnu.org>
Sun, 2 Jun 2002 07:53:30 +0000 (2 07:53 +0000)
tree939e973d5582935b4710f17a3a5c1236252b7288
parent16133e14330cd8e1b96fbfcd2d6f5a5c540a0458
Adding a new keyword `papersize' to the DESC file format (similar
but not completely identical to grolbp's extension).  grops now has
a -p command line option to override `papersize'.  Finally, grolbp
has been adapted to the new syntax.

* src/libs/libgroff/paper.cc, src/include/paper.h: New files.  It
defines and initializes the `papersizes[]' array with NUM_PAPERSIZES
elements.
* src/libs/libgroff/Makefile.sub (OBJS): Add `paper.o'.
(CCSRCS): Add `paper.cc'.

* src/include/font.h (font): Add `papersize' element.
* src/libs/libgroff/font.cc (font::unit_scale): New helper function.
(font::scan_papersize): New function.
(font::load_desc): Use it for handling `papersize' keyword.
* src/libs/libgroff/fontfile.cc: Initialize `font::papersize'.

* src/devices/grops/ps.cc: Include paper.h.
(user_paper_length): New global variable.
(ps_printer): Use paper length as initializer.
(make_printer): Updated.
(main): Handle new `-p' option.
* src/devices/grops/grops.man: Updated.

* src/devices/grolbp/lbp.cc: Include paper.h.
s/papersizes/lbp_papersizes/.
(set_papersize): Use new `papersizes' array.
(handle_unknown_desc_command): Don't handle `papersize'.
(main): Use `font::scan_papersize' for handling `-p' option.
* src/devices/grolbp/grolbp.man: Updated.

* man/groff_font.man: Document `papersize'.
* NEWS: Updated.
14 files changed:
ChangeLog
NEWS
man/groff_font.man
src/devices/grolbp/grolbp.man
src/devices/grolbp/lbp.cc
src/devices/grops/TODO
src/devices/grops/grops.man
src/devices/grops/ps.cc
src/include/font.h
src/include/paper.h [new file with mode: 0644]
src/libs/libgroff/Makefile.sub
src/libs/libgroff/font.cc
src/libs/libgroff/fontfile.cc
src/libs/libgroff/paper.cc [new file with mode: 0644]