From c96557721be60d942f4d486b9ea7f9b7cbb034cc Mon Sep 17 00:00:00 2001 From: ru Date: Thu, 1 May 2003 13:09:50 +0000 Subject: Virgin import of FSF groff v1.19 --- contrib/groff/ChangeLog | 1733 ++++- contrib/groff/INSTALL | 4 +- contrib/groff/MANIFEST | 21 +- contrib/groff/Makefile.ccpg | 4 +- contrib/groff/Makefile.comm | 43 +- contrib/groff/Makefile.dev | 4 +- contrib/groff/Makefile.in | 144 +- contrib/groff/Makefile.lib | 6 +- contrib/groff/Makefile.sub | 1 + contrib/groff/NEWS | 231 +- contrib/groff/PROBLEMS | 76 +- contrib/groff/README.CVS | 6 + contrib/groff/REVISION | 2 +- contrib/groff/VERSION | 2 +- contrib/groff/aclocal.m4 | 86 +- contrib/groff/configure | 421 +- contrib/groff/configure.ac | 14 +- contrib/groff/contrib/groffer/ChangeLog | 97 + contrib/groff/contrib/groffer/Makefile.sub | 6 +- contrib/groff/contrib/groffer/README | 23 + contrib/groff/contrib/groffer/TODO | 11 +- contrib/groff/contrib/groffer/groffer.man | 769 +- contrib/groff/contrib/groffer/groffer.sh | 198 +- contrib/groff/contrib/mm/ChangeLog | 30 + contrib/groff/contrib/mm/groff_mm.man | 12 +- contrib/groff/contrib/mm/m.tmac | 16 +- contrib/groff/contrib/mm/mm/4.MT | 19 +- contrib/groff/contrib/mom/BUGS | 22 +- contrib/groff/contrib/mom/ChangeLog | 40 + contrib/groff/contrib/mom/Makefile.sub | 11 +- contrib/groff/contrib/mom/NEWS | 26 + contrib/groff/contrib/mom/examples/elvis_syntax | 4 +- contrib/groff/contrib/mom/examples/typeset.mom | 11 +- contrib/groff/contrib/mom/momdoc/docelement.html | 8 +- .../groff/contrib/mom/momdoc/docprocessing.html | 144 +- contrib/groff/contrib/mom/momdoc/goodies.html | 1 + contrib/groff/contrib/mom/momdoc/inlines.html | 16 + contrib/groff/contrib/mom/momdoc/intro.html | 2 +- contrib/groff/contrib/mom/momdoc/reserved.html | 31 +- contrib/groff/contrib/mom/momdoc/toc.html | 5 +- contrib/groff/contrib/mom/momdoc/typesetting.html | 23 +- contrib/groff/contrib/mom/om.tmac | 642 +- contrib/groff/contrib/pic2graph/pic2graph.sh | 4 +- contrib/groff/doc/Makefile.in | 16 +- contrib/groff/doc/Makefile.sub | 14 +- contrib/groff/doc/groff | 546 +- contrib/groff/doc/groff-1 | 137 +- contrib/groff/doc/groff-10 | 287 +- contrib/groff/doc/groff-11 | 143 +- contrib/groff/doc/groff-2 | 734 +- contrib/groff/doc/groff-3 | 754 +- contrib/groff/doc/groff-4 | 498 +- contrib/groff/doc/groff-5 | 726 +- contrib/groff/doc/groff-6 | 575 +- contrib/groff/doc/groff-7 | 768 +- contrib/groff/doc/groff-8 | 730 +- contrib/groff/doc/groff-9 | 534 +- contrib/groff/doc/groff.texinfo | 1998 +++-- contrib/groff/doc/pic.ms | 122 +- contrib/groff/doc/texinfo.tex | 2220 +++--- contrib/groff/doc/webpage.ms | 443 +- contrib/groff/font/devX100-12/CB | 5 +- contrib/groff/font/devX100-12/CBI | 5 +- contrib/groff/font/devX100-12/CI | 5 +- contrib/groff/font/devX100-12/CR | 5 +- contrib/groff/font/devX100-12/HB | 5 +- contrib/groff/font/devX100-12/HBI | 5 +- contrib/groff/font/devX100-12/HI | 5 +- contrib/groff/font/devX100-12/HR | 5 +- contrib/groff/font/devX100-12/NB | 5 +- contrib/groff/font/devX100-12/NBI | 5 +- contrib/groff/font/devX100-12/NI | 5 +- contrib/groff/font/devX100-12/NR | 5 +- contrib/groff/font/devX100-12/S | 4 +- contrib/groff/font/devX100-12/TB | 5 +- contrib/groff/font/devX100-12/TBI | 5 +- contrib/groff/font/devX100-12/TI | 5 +- contrib/groff/font/devX100-12/TR | 5 +- contrib/groff/font/devX100/CB | 5 +- contrib/groff/font/devX100/CBI | 5 +- contrib/groff/font/devX100/CI | 5 +- contrib/groff/font/devX100/CR | 5 +- contrib/groff/font/devX100/HB | 5 +- contrib/groff/font/devX100/HBI | 5 +- contrib/groff/font/devX100/HI | 5 +- contrib/groff/font/devX100/HR | 5 +- contrib/groff/font/devX100/NB | 5 +- contrib/groff/font/devX100/NBI | 5 +- contrib/groff/font/devX100/NI | 5 +- contrib/groff/font/devX100/NR | 5 +- contrib/groff/font/devX100/S | 4 +- contrib/groff/font/devX100/TB | 5 +- contrib/groff/font/devX100/TBI | 5 +- contrib/groff/font/devX100/TI | 5 +- contrib/groff/font/devX100/TR | 5 +- contrib/groff/font/devX75-12/CB | 5 +- contrib/groff/font/devX75-12/CBI | 5 +- contrib/groff/font/devX75-12/CI | 5 +- contrib/groff/font/devX75-12/CR | 5 +- contrib/groff/font/devX75-12/HB | 5 +- contrib/groff/font/devX75-12/HBI | 5 +- contrib/groff/font/devX75-12/HI | 5 +- contrib/groff/font/devX75-12/HR | 5 +- contrib/groff/font/devX75-12/NB | 5 +- contrib/groff/font/devX75-12/NBI | 5 +- contrib/groff/font/devX75-12/NI | 5 +- contrib/groff/font/devX75-12/NR | 5 +- contrib/groff/font/devX75-12/S | 4 +- contrib/groff/font/devX75-12/TB | 5 +- contrib/groff/font/devX75-12/TBI | 5 +- contrib/groff/font/devX75-12/TI | 5 +- contrib/groff/font/devX75-12/TR | 5 +- contrib/groff/font/devX75/CB | 5 +- contrib/groff/font/devX75/CBI | 5 +- contrib/groff/font/devX75/CI | 5 +- contrib/groff/font/devX75/CR | 5 +- contrib/groff/font/devX75/HB | 5 +- contrib/groff/font/devX75/HBI | 5 +- contrib/groff/font/devX75/HI | 5 +- contrib/groff/font/devX75/HR | 5 +- contrib/groff/font/devX75/NB | 5 +- contrib/groff/font/devX75/NBI | 5 +- contrib/groff/font/devX75/NI | 5 +- contrib/groff/font/devX75/NR | 5 +- contrib/groff/font/devX75/S | 4 +- contrib/groff/font/devX75/TB | 5 +- contrib/groff/font/devX75/TBI | 5 +- contrib/groff/font/devX75/TI | 5 +- contrib/groff/font/devX75/TR | 5 +- contrib/groff/font/devascii/R.proto | 44 +- contrib/groff/font/devcp1047/R.proto | 79 +- contrib/groff/font/devdvi/CW | 4 +- contrib/groff/font/devdvi/CWEC | 116 +- contrib/groff/font/devdvi/CWI | 4 +- contrib/groff/font/devdvi/CWIEC | 116 +- contrib/groff/font/devdvi/CWITC | 71 +- contrib/groff/font/devdvi/CWTC | 71 +- contrib/groff/font/devdvi/EX | 9 +- contrib/groff/font/devdvi/HB | 4 +- contrib/groff/font/devdvi/HBEC | 616 +- contrib/groff/font/devdvi/HBI | 4 +- contrib/groff/font/devdvi/HBIEC | 616 +- contrib/groff/font/devdvi/HBITC | 71 +- contrib/groff/font/devdvi/HBTC | 71 +- contrib/groff/font/devdvi/HI | 4 +- contrib/groff/font/devdvi/HIEC | 616 +- contrib/groff/font/devdvi/HITC | 71 +- contrib/groff/font/devdvi/HR | 4 +- contrib/groff/font/devdvi/HREC | 616 +- contrib/groff/font/devdvi/HRTC | 71 +- contrib/groff/font/devdvi/MI | 34 +- contrib/groff/font/devdvi/Makefile.sub | 12 +- contrib/groff/font/devdvi/S | 75 +- contrib/groff/font/devdvi/SC | 137 + contrib/groff/font/devdvi/TB | 14 +- contrib/groff/font/devdvi/TBEC | 716 +- contrib/groff/font/devdvi/TBI | 12 +- contrib/groff/font/devdvi/TBIEC | 1113 ++- contrib/groff/font/devdvi/TBITC | 71 +- contrib/groff/font/devdvi/TBTC | 71 +- contrib/groff/font/devdvi/TI | 6 +- contrib/groff/font/devdvi/TIEC | 1113 ++- contrib/groff/font/devdvi/TITC | 71 +- contrib/groff/font/devdvi/TR | 12 +- contrib/groff/font/devdvi/TREC | 716 +- contrib/groff/font/devdvi/TRTC | 71 +- contrib/groff/font/devdvi/generate/Makefile | 6 +- contrib/groff/font/devdvi/generate/ec.map | 61 +- contrib/groff/font/devdvi/generate/tc.map | 38 +- contrib/groff/font/devdvi/generate/texb.map | 1 + contrib/groff/font/devdvi/generate/texex.map | 10 +- contrib/groff/font/devdvi/generate/texi.map | 1 + contrib/groff/font/devdvi/generate/texmi.map | 16 +- contrib/groff/font/devdvi/generate/texr.map | 1 + contrib/groff/font/devdvi/generate/texsy.map | 45 +- contrib/groff/font/devdvi/generate/textex.map | 34 + contrib/groff/font/devdvi/generate/textt.map | 2 + contrib/groff/font/devhtml/DESC.proto | 2 +- contrib/groff/font/devhtml/R.proto | 72 +- contrib/groff/font/devlatin1/R.proto | 78 +- contrib/groff/font/devlbp/CB | 1 + contrib/groff/font/devlbp/CI | 1 + contrib/groff/font/devlbp/CR | 1 + contrib/groff/font/devlbp/EB | 1 + contrib/groff/font/devlbp/EI | 1 + contrib/groff/font/devlbp/ER | 1 + contrib/groff/font/devlbp/HB | 5 +- contrib/groff/font/devlbp/HBI | 5 +- contrib/groff/font/devlbp/HI | 5 +- contrib/groff/font/devlbp/HNB | 5 +- contrib/groff/font/devlbp/HNBI | 5 +- contrib/groff/font/devlbp/HNI | 5 +- contrib/groff/font/devlbp/HNR | 5 +- contrib/groff/font/devlbp/HR | 5 +- contrib/groff/font/devlbp/TB | 5 +- contrib/groff/font/devlbp/TBI | 5 +- contrib/groff/font/devlbp/TI | 5 +- contrib/groff/font/devlbp/TR | 5 +- contrib/groff/font/devlj4/ALBB | 4 +- contrib/groff/font/devlj4/ALBR | 4 +- contrib/groff/font/devlj4/AOB | 4 +- contrib/groff/font/devlj4/AOI | 4 +- contrib/groff/font/devlj4/AOR | 4 +- contrib/groff/font/devlj4/CB | 4 +- contrib/groff/font/devlj4/CBI | 4 +- contrib/groff/font/devlj4/CI | 4 +- contrib/groff/font/devlj4/CLARENDON | 4 +- contrib/groff/font/devlj4/CORONET | 4 +- contrib/groff/font/devlj4/CR | 4 +- contrib/groff/font/devlj4/GB | 4 +- contrib/groff/font/devlj4/GBI | 4 +- contrib/groff/font/devlj4/GI | 4 +- contrib/groff/font/devlj4/GR | 4 +- contrib/groff/font/devlj4/LGB | 4 +- contrib/groff/font/devlj4/LGI | 4 +- contrib/groff/font/devlj4/LGR | 4 +- contrib/groff/font/devlj4/MARIGOLD | 4 +- contrib/groff/font/devlj4/OB | 6 +- contrib/groff/font/devlj4/OBI | 4 +- contrib/groff/font/devlj4/OI | 4 +- contrib/groff/font/devlj4/OR | 4 +- contrib/groff/font/devlj4/S | 22 +- contrib/groff/font/devlj4/TB | 4 +- contrib/groff/font/devlj4/TBI | 4 +- contrib/groff/font/devlj4/TI | 4 +- contrib/groff/font/devlj4/TR | 4 +- contrib/groff/font/devlj4/UB | 6 +- contrib/groff/font/devlj4/UBI | 6 +- contrib/groff/font/devlj4/UCB | 6 +- contrib/groff/font/devlj4/UCBI | 6 +- contrib/groff/font/devlj4/UCI | 6 +- contrib/groff/font/devlj4/UCR | 6 +- contrib/groff/font/devlj4/UI | 6 +- contrib/groff/font/devlj4/UR | 6 +- contrib/groff/font/devlj4/generate/special.map | 12 +- contrib/groff/font/devlj4/generate/text.map | 3 +- contrib/groff/font/devps/AB | 455 +- contrib/groff/font/devps/ABI | 455 +- contrib/groff/font/devps/AI | 455 +- contrib/groff/font/devps/AR | 455 +- contrib/groff/font/devps/BMB | 455 +- contrib/groff/font/devps/BMBI | 455 +- contrib/groff/font/devps/BMI | 455 +- contrib/groff/font/devps/BMR | 455 +- contrib/groff/font/devps/CB | 487 +- contrib/groff/font/devps/CBI | 487 +- contrib/groff/font/devps/CI | 487 +- contrib/groff/font/devps/CR | 487 +- contrib/groff/font/devps/EURO | 19 + contrib/groff/font/devps/HB | 455 +- contrib/groff/font/devps/HBI | 455 +- contrib/groff/font/devps/HI | 455 +- contrib/groff/font/devps/HNB | 455 +- contrib/groff/font/devps/HNBI | 455 +- contrib/groff/font/devps/HNI | 455 +- contrib/groff/font/devps/HNR | 455 +- contrib/groff/font/devps/HR | 455 +- contrib/groff/font/devps/Makefile.sub | 9 +- contrib/groff/font/devps/NB | 455 +- contrib/groff/font/devps/NBI | 455 +- contrib/groff/font/devps/NI | 455 +- contrib/groff/font/devps/NR | 455 +- contrib/groff/font/devps/PB | 455 +- contrib/groff/font/devps/PBI | 455 +- contrib/groff/font/devps/PI | 455 +- contrib/groff/font/devps/PR | 455 +- contrib/groff/font/devps/S | 380 +- contrib/groff/font/devps/SS | 377 +- contrib/groff/font/devps/TB | 455 +- contrib/groff/font/devps/TBI | 455 +- contrib/groff/font/devps/TI | 455 +- contrib/groff/font/devps/TR | 455 +- contrib/groff/font/devps/ZCMI | 455 +- contrib/groff/font/devps/ZD | 390 +- contrib/groff/font/devps/ZDR | 390 +- contrib/groff/font/devps/download | 1 + contrib/groff/font/devps/freeeuro.afm | 34 + contrib/groff/font/devps/freeeuro.pfa | 316 + contrib/groff/font/devps/generate/Makefile | 11 +- contrib/groff/font/devps/generate/freeeuro.sfd | 610 ++ contrib/groff/font/devps/generate/sfdtopfa.pe | 9 + contrib/groff/font/devps/generate/symbolchars | 2 + contrib/groff/font/devps/generate/textmap | 28 +- contrib/groff/font/devps/prologue.ps | 19 +- contrib/groff/font/devps/symbolmap | 30 +- contrib/groff/font/devutf8/NOTES | 14 - contrib/groff/font/devutf8/R.proto | 144 +- contrib/groff/man/groff.man | 66 +- contrib/groff/man/groff_char.man | 1697 +++-- contrib/groff/man/groff_diff.man | 286 +- contrib/groff/man/groff_font.man | 38 +- contrib/groff/man/groff_out.man | 21 +- contrib/groff/man/groff_tmac.man | 132 +- contrib/groff/man/roff.man | 9 +- contrib/groff/src/devices/grodvi/Makefile.sub | 2 +- contrib/groff/src/devices/grodvi/dvi.cpp | 973 +++ contrib/groff/src/devices/grodvi/grodvi.man | 125 +- contrib/groff/src/devices/grohtml/Makefile.sub | 8 +- contrib/groff/src/devices/grohtml/html-table.cpp | 728 ++ contrib/groff/src/devices/grohtml/html-table.h | 4 +- contrib/groff/src/devices/grohtml/html-text.cpp | 965 +++ contrib/groff/src/devices/grohtml/html-text.h | 8 +- contrib/groff/src/devices/grohtml/output.cpp | 356 + contrib/groff/src/devices/grohtml/post-html.cpp | 3812 ++++++++++ contrib/groff/src/devices/grolbp/Makefile.sub | 2 +- contrib/groff/src/devices/grolbp/charset.h | 2 +- contrib/groff/src/devices/grolbp/lbp.cpp | 739 ++ contrib/groff/src/devices/grolbp/lbp.h | 4 +- contrib/groff/src/devices/grolj4/Makefile.sub | 2 +- contrib/groff/src/devices/grolj4/lj4.cpp | 706 ++ contrib/groff/src/devices/grops/Makefile.sub | 4 +- contrib/groff/src/devices/grops/TODO | 2 - contrib/groff/src/devices/grops/grops.man | 282 +- contrib/groff/src/devices/grops/ps.cpp | 1869 +++++ contrib/groff/src/devices/grops/ps.h | 6 +- contrib/groff/src/devices/grops/psrm.cpp | 1178 +++ contrib/groff/src/devices/grotty/Makefile.sub | 2 +- contrib/groff/src/devices/grotty/tty.cpp | 815 ++ contrib/groff/src/include/color.h | 11 +- contrib/groff/src/include/config.hin | 101 +- contrib/groff/src/include/driver.h | 1 - contrib/groff/src/include/error.h | 4 +- contrib/groff/src/include/html-strings.h | 4 +- contrib/groff/src/include/lib.h | 29 +- contrib/groff/src/include/nonposix.h | 17 +- contrib/groff/src/include/printer.h | 14 +- contrib/groff/src/include/ptable.h | 11 +- contrib/groff/src/libs/libbib/Makefile.sub | 8 +- contrib/groff/src/libs/libbib/common.cpp | 38 + contrib/groff/src/libs/libbib/index.cpp | 640 ++ contrib/groff/src/libs/libbib/linear.cpp | 503 ++ contrib/groff/src/libs/libbib/search.cpp | 133 + contrib/groff/src/libs/libdriver/Makefile.sub | 4 +- contrib/groff/src/libs/libdriver/input.cpp | 1831 +++++ contrib/groff/src/libs/libdriver/printer.cpp | 214 + contrib/groff/src/libs/libgroff/Makefile.sub | 74 +- contrib/groff/src/libs/libgroff/assert.cpp | 34 + contrib/groff/src/libs/libgroff/change_lf.cpp | 37 + contrib/groff/src/libs/libgroff/cmap.cpp | 56 + contrib/groff/src/libs/libgroff/color.cpp | 427 ++ contrib/groff/src/libs/libgroff/cset.cpp | 102 + contrib/groff/src/libs/libgroff/device.cpp | 36 + contrib/groff/src/libs/libgroff/errarg.cpp | 128 + contrib/groff/src/libs/libgroff/error.cpp | 142 + contrib/groff/src/libs/libgroff/fatal.cpp | 27 + contrib/groff/src/libs/libgroff/filename.cpp | 2 + contrib/groff/src/libs/libgroff/font.cpp | 1034 +++ contrib/groff/src/libs/libgroff/fontfile.cpp | 67 + contrib/groff/src/libs/libgroff/geometry.cpp | 286 + contrib/groff/src/libs/libgroff/htmlhint.cpp | 59 + contrib/groff/src/libs/libgroff/invalid.cpp | 60 + contrib/groff/src/libs/libgroff/lf.cpp | 62 + contrib/groff/src/libs/libgroff/lineno.cpp | 1 + contrib/groff/src/libs/libgroff/macropath.cpp | 30 + contrib/groff/src/libs/libgroff/maxfilename.cpp | 69 + contrib/groff/src/libs/libgroff/mksdir.cpp | 34 + contrib/groff/src/libs/libgroff/mkstemp.cpp | 34 + contrib/groff/src/libs/libgroff/nametoindex.cpp | 117 + contrib/groff/src/libs/libgroff/new.cpp | 71 + contrib/groff/src/libs/libgroff/paper.cpp | 84 + contrib/groff/src/libs/libgroff/prime.cpp | 26 + contrib/groff/src/libs/libgroff/progname.cpp | 1 + contrib/groff/src/libs/libgroff/ptable.cpp | 52 + contrib/groff/src/libs/libgroff/searchpath.cpp | 132 + contrib/groff/src/libs/libgroff/strcasecmp.c | 66 + contrib/groff/src/libs/libgroff/string.cpp | 341 + contrib/groff/src/libs/libgroff/strncasecmp.c | 2 + contrib/groff/src/libs/libgroff/strsave.cpp | 31 + contrib/groff/src/libs/libgroff/tmpfile.cpp | 172 + contrib/groff/src/libs/libgroff/tmpname.cpp | 116 + contrib/groff/src/preproc/eqn/Makefile.sub | 31 +- contrib/groff/src/preproc/eqn/box.cpp | 611 ++ contrib/groff/src/preproc/eqn/delim.cpp | 401 + contrib/groff/src/preproc/eqn/eqn.cpp | 1170 +++ contrib/groff/src/preproc/eqn/lex.cpp | 1166 +++ contrib/groff/src/preproc/eqn/limit.cpp | 195 + contrib/groff/src/preproc/eqn/list.cpp | 237 + contrib/groff/src/preproc/eqn/main.cpp | 395 + contrib/groff/src/preproc/eqn/mark.cpp | 121 + contrib/groff/src/preproc/eqn/neqn.sh | 2 +- contrib/groff/src/preproc/eqn/other.cpp | 601 ++ contrib/groff/src/preproc/eqn/over.cpp | 197 + contrib/groff/src/preproc/eqn/pile.cpp | 293 + contrib/groff/src/preproc/eqn/script.cpp | 221 + contrib/groff/src/preproc/eqn/special.cpp | 115 + contrib/groff/src/preproc/eqn/sqrt.cpp | 180 + contrib/groff/src/preproc/eqn/text.cpp | 528 ++ contrib/groff/src/preproc/grn/Makefile.sub | 8 +- contrib/groff/src/preproc/grn/README | 4 +- contrib/groff/src/preproc/grn/hdb.cpp | 339 + contrib/groff/src/preproc/grn/hgraph.cpp | 1054 +++ contrib/groff/src/preproc/grn/hpoint.cpp | 49 + contrib/groff/src/preproc/grn/main.cpp | 907 +++ contrib/groff/src/preproc/html/Makefile.sub | 2 +- contrib/groff/src/preproc/html/pre-html.cpp | 1530 ++++ contrib/groff/src/preproc/html/pushback.cpp | 333 + contrib/groff/src/preproc/html/pushback.h | 6 +- contrib/groff/src/preproc/pic/Makefile.sub | 14 +- contrib/groff/src/preproc/pic/common.cpp | 496 ++ contrib/groff/src/preproc/pic/lex.cpp | 1993 +++++ contrib/groff/src/preproc/pic/main.cpp | 642 ++ contrib/groff/src/preproc/pic/object.cpp | 1898 +++++ contrib/groff/src/preproc/pic/pic.cpp | 5619 ++++++++++++++ contrib/groff/src/preproc/pic/pic.h | 27 +- contrib/groff/src/preproc/pic/pic.man | 55 +- contrib/groff/src/preproc/pic/pic.y | 39 +- contrib/groff/src/preproc/pic/pic_tab.h | 187 +- contrib/groff/src/preproc/pic/tex.cpp | 446 ++ contrib/groff/src/preproc/pic/troff.cpp | 559 ++ contrib/groff/src/preproc/refer/Makefile.sub | 10 +- contrib/groff/src/preproc/refer/command.cpp | 809 ++ contrib/groff/src/preproc/refer/label.cpp | 1605 ++++ contrib/groff/src/preproc/refer/ref.cpp | 1160 +++ contrib/groff/src/preproc/refer/refer.cpp | 1235 +++ contrib/groff/src/preproc/refer/refer.man | 10 +- contrib/groff/src/preproc/refer/token.cpp | 378 + contrib/groff/src/preproc/soelim/Makefile.sub | 2 +- contrib/groff/src/preproc/soelim/soelim.cpp | 359 + contrib/groff/src/preproc/soelim/soelim.man | 22 +- contrib/groff/src/preproc/tbl/Makefile.sub | 4 +- contrib/groff/src/preproc/tbl/main.cpp | 1529 ++++ contrib/groff/src/preproc/tbl/table.cpp | 2767 +++++++ contrib/groff/src/preproc/tbl/tbl.man | 7 +- contrib/groff/src/roff/groff/Makefile.sub | 2 +- contrib/groff/src/roff/groff/groff.cpp | 753 ++ contrib/groff/src/roff/groff/groff.man | 145 +- contrib/groff/src/roff/groff/pipeline.c | 417 +- contrib/groff/src/roff/grog/grog.man | 4 +- contrib/groff/src/roff/nroff/Makefile.sub | 1 + contrib/groff/src/roff/nroff/nroff.man | 16 +- contrib/groff/src/roff/nroff/nroff.sh | 4 +- contrib/groff/src/roff/troff/Makefile.sub | 45 +- contrib/groff/src/roff/troff/charinfo.h | 21 +- contrib/groff/src/roff/troff/column.cpp | 732 ++ contrib/groff/src/roff/troff/dictionary.cpp | 212 + contrib/groff/src/roff/troff/div.cpp | 1182 +++ contrib/groff/src/roff/troff/div.h | 5 +- contrib/groff/src/roff/troff/env.cpp | 3818 ++++++++++ contrib/groff/src/roff/troff/glyphuni.cpp | 503 ++ contrib/groff/src/roff/troff/input.cpp | 7879 ++++++++++++++++++++ contrib/groff/src/roff/troff/node.cpp | 5993 +++++++++++++++ contrib/groff/src/roff/troff/node.h | 16 +- contrib/groff/src/roff/troff/number.cpp | 697 ++ contrib/groff/src/roff/troff/reg.cpp | 474 ++ contrib/groff/src/roff/troff/reg.h | 4 +- contrib/groff/src/roff/troff/symbol.cpp | 154 + contrib/groff/src/roff/troff/token.h | 9 + contrib/groff/src/roff/troff/troff.man | 7 +- contrib/groff/src/roff/troff/unicode.cpp | 67 + contrib/groff/src/roff/troff/unicode.h | 26 + contrib/groff/src/roff/troff/uniglyph.cpp | 503 ++ contrib/groff/src/roff/troff/uniuni.cpp | 1994 +++++ contrib/groff/src/utils/addftinfo/Makefile.sub | 4 +- contrib/groff/src/utils/addftinfo/addftinfo.cpp | 218 + contrib/groff/src/utils/addftinfo/guess.cpp | 490 ++ contrib/groff/src/utils/afmtodit/Makefile.sub | 2 + contrib/groff/src/utils/afmtodit/afmtodit.man | 135 +- contrib/groff/src/utils/afmtodit/afmtodit.pl | 6111 ++++++++++++++- contrib/groff/src/utils/hpftodit/Makefile.sub | 2 +- contrib/groff/src/utils/hpftodit/hpftodit.cpp | 811 ++ contrib/groff/src/utils/hpftodit/hpftodit.man | 4 +- contrib/groff/src/utils/indxbib/Makefile.sub | 2 +- contrib/groff/src/utils/indxbib/indxbib.cpp | 790 ++ contrib/groff/src/utils/lkbib/Makefile.sub | 2 +- contrib/groff/src/utils/lkbib/lkbib.cpp | 137 + contrib/groff/src/utils/lookbib/Makefile.sub | 2 +- contrib/groff/src/utils/lookbib/lookbib.cpp | 141 + contrib/groff/src/utils/pfbtops/pfbtops.c | 190 +- contrib/groff/src/utils/pfbtops/pfbtops.man | 5 +- contrib/groff/src/utils/tfmtodit/Makefile.sub | 2 +- contrib/groff/src/utils/tfmtodit/tfmtodit.cpp | 874 +++ contrib/groff/src/xditview/ChangeLog | 57 +- contrib/groff/src/xditview/DviChar.c | 522 +- contrib/groff/src/xditview/Imakefile.in | 7 +- contrib/groff/src/xditview/draw.c | 8 +- contrib/groff/tmac/Makefile.sub | 20 +- contrib/groff/tmac/README | 13 +- contrib/groff/tmac/X.tmac | 84 +- contrib/groff/tmac/Xps.tmac | 9 +- contrib/groff/tmac/a4.tmac | 18 +- contrib/groff/tmac/an-old.tmac | 112 +- contrib/groff/tmac/composite.tmac | 24 + contrib/groff/tmac/cp1047.tmac | 192 +- contrib/groff/tmac/doc-common | 34 +- contrib/groff/tmac/doc-ditroff | 11 - contrib/groff/tmac/doc-nroff | 12 +- contrib/groff/tmac/doc.tmac | 22 +- contrib/groff/tmac/dvi.tmac | 102 +- contrib/groff/tmac/ec.tmac | 19 +- contrib/groff/tmac/eqnrc | 2 +- contrib/groff/tmac/europs.tmac | 38 + contrib/groff/tmac/groff_man.man | 291 +- contrib/groff/tmac/groff_mdoc.man | 19 +- contrib/groff/tmac/html-end.tmac | 25 + contrib/groff/tmac/html.tmac | 196 +- contrib/groff/tmac/hyphen.us | 3 + contrib/groff/tmac/hyphenex.pl | 78 + contrib/groff/tmac/hyphenex.us | 896 +++ contrib/groff/tmac/latin1.tmac | 198 +- contrib/groff/tmac/latin2.tmac | 107 + contrib/groff/tmac/latin9.tmac | 107 + contrib/groff/tmac/lbp.tmac | 67 + contrib/groff/tmac/lj4.tmac | 15 +- contrib/groff/tmac/papersize.tmac | 146 + contrib/groff/tmac/ps.tmac | 85 +- contrib/groff/tmac/pspic.tmac | 4 +- contrib/groff/tmac/troffrc | 11 +- contrib/groff/tmac/troffrc-end | 3 +- contrib/groff/tmac/tty-char.tmac | 10 +- contrib/groff/tmac/tty.tmac | 18 +- contrib/groff/tmac/www.tmac | 373 +- 511 files changed, 119296 insertions(+), 17879 deletions(-) create mode 100644 contrib/groff/README.CVS create mode 100644 contrib/groff/contrib/groffer/README create mode 100644 contrib/groff/font/devdvi/SC create mode 100644 contrib/groff/font/devdvi/generate/textex.map create mode 100644 contrib/groff/font/devps/EURO create mode 100644 contrib/groff/font/devps/freeeuro.afm create mode 100644 contrib/groff/font/devps/freeeuro.pfa create mode 100644 contrib/groff/font/devps/generate/freeeuro.sfd create mode 100644 contrib/groff/font/devps/generate/sfdtopfa.pe create mode 100644 contrib/groff/src/devices/grodvi/dvi.cpp create mode 100644 contrib/groff/src/devices/grohtml/html-table.cpp create mode 100644 contrib/groff/src/devices/grohtml/html-text.cpp create mode 100644 contrib/groff/src/devices/grohtml/output.cpp create mode 100644 contrib/groff/src/devices/grohtml/post-html.cpp create mode 100644 contrib/groff/src/devices/grolbp/lbp.cpp create mode 100644 contrib/groff/src/devices/grolj4/lj4.cpp create mode 100644 contrib/groff/src/devices/grops/ps.cpp create mode 100644 contrib/groff/src/devices/grops/psrm.cpp create mode 100644 contrib/groff/src/devices/grotty/tty.cpp create mode 100644 contrib/groff/src/libs/libbib/common.cpp create mode 100644 contrib/groff/src/libs/libbib/index.cpp create mode 100644 contrib/groff/src/libs/libbib/linear.cpp create mode 100644 contrib/groff/src/libs/libbib/search.cpp create mode 100644 contrib/groff/src/libs/libdriver/input.cpp create mode 100644 contrib/groff/src/libs/libdriver/printer.cpp create mode 100644 contrib/groff/src/libs/libgroff/assert.cpp create mode 100644 contrib/groff/src/libs/libgroff/change_lf.cpp create mode 100644 contrib/groff/src/libs/libgroff/cmap.cpp create mode 100644 contrib/groff/src/libs/libgroff/color.cpp create mode 100644 contrib/groff/src/libs/libgroff/cset.cpp create mode 100644 contrib/groff/src/libs/libgroff/device.cpp create mode 100644 contrib/groff/src/libs/libgroff/errarg.cpp create mode 100644 contrib/groff/src/libs/libgroff/error.cpp create mode 100644 contrib/groff/src/libs/libgroff/fatal.cpp create mode 100644 contrib/groff/src/libs/libgroff/filename.cpp create mode 100644 contrib/groff/src/libs/libgroff/font.cpp create mode 100644 contrib/groff/src/libs/libgroff/fontfile.cpp create mode 100644 contrib/groff/src/libs/libgroff/geometry.cpp create mode 100644 contrib/groff/src/libs/libgroff/htmlhint.cpp create mode 100644 contrib/groff/src/libs/libgroff/invalid.cpp create mode 100644 contrib/groff/src/libs/libgroff/lf.cpp create mode 100644 contrib/groff/src/libs/libgroff/lineno.cpp create mode 100644 contrib/groff/src/libs/libgroff/macropath.cpp create mode 100644 contrib/groff/src/libs/libgroff/maxfilename.cpp create mode 100644 contrib/groff/src/libs/libgroff/mksdir.cpp create mode 100644 contrib/groff/src/libs/libgroff/mkstemp.cpp create mode 100644 contrib/groff/src/libs/libgroff/nametoindex.cpp create mode 100644 contrib/groff/src/libs/libgroff/new.cpp create mode 100644 contrib/groff/src/libs/libgroff/paper.cpp create mode 100644 contrib/groff/src/libs/libgroff/prime.cpp create mode 100644 contrib/groff/src/libs/libgroff/progname.cpp create mode 100644 contrib/groff/src/libs/libgroff/ptable.cpp create mode 100644 contrib/groff/src/libs/libgroff/searchpath.cpp create mode 100644 contrib/groff/src/libs/libgroff/strcasecmp.c create mode 100644 contrib/groff/src/libs/libgroff/string.cpp create mode 100644 contrib/groff/src/libs/libgroff/strncasecmp.c create mode 100644 contrib/groff/src/libs/libgroff/strsave.cpp create mode 100644 contrib/groff/src/libs/libgroff/tmpfile.cpp create mode 100644 contrib/groff/src/libs/libgroff/tmpname.cpp create mode 100644 contrib/groff/src/preproc/eqn/box.cpp create mode 100644 contrib/groff/src/preproc/eqn/delim.cpp create mode 100644 contrib/groff/src/preproc/eqn/eqn.cpp create mode 100644 contrib/groff/src/preproc/eqn/lex.cpp create mode 100644 contrib/groff/src/preproc/eqn/limit.cpp create mode 100644 contrib/groff/src/preproc/eqn/list.cpp create mode 100644 contrib/groff/src/preproc/eqn/main.cpp create mode 100644 contrib/groff/src/preproc/eqn/mark.cpp create mode 100644 contrib/groff/src/preproc/eqn/other.cpp create mode 100644 contrib/groff/src/preproc/eqn/over.cpp create mode 100644 contrib/groff/src/preproc/eqn/pile.cpp create mode 100644 contrib/groff/src/preproc/eqn/script.cpp create mode 100644 contrib/groff/src/preproc/eqn/special.cpp create mode 100644 contrib/groff/src/preproc/eqn/sqrt.cpp create mode 100644 contrib/groff/src/preproc/eqn/text.cpp create mode 100644 contrib/groff/src/preproc/grn/hdb.cpp create mode 100644 contrib/groff/src/preproc/grn/hgraph.cpp create mode 100644 contrib/groff/src/preproc/grn/hpoint.cpp create mode 100644 contrib/groff/src/preproc/grn/main.cpp create mode 100644 contrib/groff/src/preproc/html/pre-html.cpp create mode 100644 contrib/groff/src/preproc/html/pushback.cpp create mode 100644 contrib/groff/src/preproc/pic/common.cpp create mode 100644 contrib/groff/src/preproc/pic/lex.cpp create mode 100644 contrib/groff/src/preproc/pic/main.cpp create mode 100644 contrib/groff/src/preproc/pic/object.cpp create mode 100644 contrib/groff/src/preproc/pic/pic.cpp create mode 100644 contrib/groff/src/preproc/pic/tex.cpp create mode 100644 contrib/groff/src/preproc/pic/troff.cpp create mode 100644 contrib/groff/src/preproc/refer/command.cpp create mode 100644 contrib/groff/src/preproc/refer/label.cpp create mode 100644 contrib/groff/src/preproc/refer/ref.cpp create mode 100644 contrib/groff/src/preproc/refer/refer.cpp create mode 100644 contrib/groff/src/preproc/refer/token.cpp create mode 100644 contrib/groff/src/preproc/soelim/soelim.cpp create mode 100644 contrib/groff/src/preproc/tbl/main.cpp create mode 100644 contrib/groff/src/preproc/tbl/table.cpp create mode 100644 contrib/groff/src/roff/groff/groff.cpp create mode 100644 contrib/groff/src/roff/troff/column.cpp create mode 100644 contrib/groff/src/roff/troff/dictionary.cpp create mode 100644 contrib/groff/src/roff/troff/div.cpp create mode 100644 contrib/groff/src/roff/troff/env.cpp create mode 100644 contrib/groff/src/roff/troff/glyphuni.cpp create mode 100644 contrib/groff/src/roff/troff/input.cpp create mode 100644 contrib/groff/src/roff/troff/node.cpp create mode 100644 contrib/groff/src/roff/troff/number.cpp create mode 100644 contrib/groff/src/roff/troff/reg.cpp create mode 100644 contrib/groff/src/roff/troff/symbol.cpp create mode 100644 contrib/groff/src/roff/troff/unicode.cpp create mode 100644 contrib/groff/src/roff/troff/unicode.h create mode 100644 contrib/groff/src/roff/troff/uniglyph.cpp create mode 100644 contrib/groff/src/roff/troff/uniuni.cpp create mode 100644 contrib/groff/src/utils/addftinfo/addftinfo.cpp create mode 100644 contrib/groff/src/utils/addftinfo/guess.cpp create mode 100644 contrib/groff/src/utils/hpftodit/hpftodit.cpp create mode 100644 contrib/groff/src/utils/indxbib/indxbib.cpp create mode 100644 contrib/groff/src/utils/lkbib/lkbib.cpp create mode 100644 contrib/groff/src/utils/lookbib/lookbib.cpp create mode 100644 contrib/groff/src/utils/tfmtodit/tfmtodit.cpp create mode 100644 contrib/groff/tmac/composite.tmac create mode 100644 contrib/groff/tmac/europs.tmac create mode 100644 contrib/groff/tmac/html-end.tmac create mode 100644 contrib/groff/tmac/hyphenex.pl create mode 100644 contrib/groff/tmac/hyphenex.us create mode 100644 contrib/groff/tmac/latin2.tmac create mode 100644 contrib/groff/tmac/latin9.tmac create mode 100644 contrib/groff/tmac/papersize.tmac diff --git a/contrib/groff/ChangeLog b/contrib/groff/ChangeLog index 926b60b..ff97293 100644 --- a/contrib/groff/ChangeLog +++ b/contrib/groff/ChangeLog @@ -1,3 +1,1728 @@ +2003-04-29 Werner LEMBERG + + * VERSION: Set to 1.19. + * REVISION: Set to 0. + * doc/groff.texinfo, doc/webpage.ms, NEWS: Updated. + + * src/devices/grohtml/post-html.cpp (html_printer::~html_printer): + Define charset as `US-ASCII' in html output. + + * tmac/www.tmac (ULE): Add missing scaling indicator. + + * win32-diffs: Removed. + +2003-04-28 Werner LEMBERG + + * doc/groff.texinfo: Document `dn' and `dl' registers if used with + `.da' and `.boxa'. + Document how to insert discardable whitespace with `.ss'. + +2003-04-27 Werner LEMBERG + + * src/preproc/pic/tex.cpp (tex_output::start_picture): Make code + work with plain TeX also. + + * src/preproc/pic/pic.man, doc/pic.ms: Fix TeX code example. + +2003-04-25 Gaius Mulley + + * src/devices/grohtml/post-html.cpp (html_printer::~html_printer): + Use a loose DTD. + +2003-04-24 Werner LEMBERG + + * src/preproc/pic/pic.man, doc/pic.ms: Explain how to get a + vbox with positive height and zero depth if in TeX mode. + + * NEWS: Document glyph name changes for grodvi and grolj4. + +2003-04-23 Werner LEMBERG + + * src/preproc/pic/tex.cpp (tex_output::start_picture): Fix TeX code. + * doc/pic.ms: Fixed. + +2003-04-21 Werner LEMBERG + + HP-UX 10.20 has `snprintf' but it isn't declared. + + * configure.ac: Add declaration test for snprintf. + * configure: Regenerated. + * src/include/lib.h: Handle `NEED_DECLARATION_SNPRINTF'. + * src/include/config.hin: Regenerated. + +2003-04-19 Werner LEMBERG + + Add keyword `figname' to pic, specifying the name of the picture + box in TeX mode. Based on a patch from William J Poser + . + + * src/preproc/pic/pic.y: New token `FIGNAME'. + (macro_name): New rule of type . + (placeless_element): Handle `FIGNAME'. + * src/preproc/pic/lex.cpp (lookup_keyword): Add `figname'. + * src/preproc/pic/main.cpp (graphname): New global variable. + (do_picture): Initialize `graphname'. + * src/preproc/pic/pic.h: Updated. + * src/preproc/pic/tex.cpp (tex_output::start_picture): Use + `graphname'. + Simplify TeX code. + (tex_output::text): Beautify output. + * src/preproc/pic/object.cpp (object_spec::~object_spec): Deallocate + `shaded' and `outlined' unconditionally. + * NEWS, src/preproc/pic/pic.man, doc/pic.ms: Updated. + Minor improvements. + + * PROBLEMS, README.CVS: Mention that bison version 1.875b or + greater is necessary. + +2003-04-17 Hartmut Henkel + + Add option -r to soelim to avoid emission of `.lf' lines. + Add option -t to produces TeX comment lines instead of `.lf' lines. + + * src/preproc/soelim/soelim.cpp: New global variables `raw_flag' + and `tex_flag'. + (usage): Updated. + (main): Handle `-r' and `-t'. + (set_location): Handle `raw_flag' and `tex_flag'. + * src/preproc/soelim/soelim.man, NEWS: Updated. + +2003-04-17 Werner LEMBERG + + * tmac/hyphenex.sh: Replaced with... + * tmac/hyphenex.pl: This perl script to avoid sed compatibility + nightmares. + + * aclocal.m4 (GROFF_HTML_PROGRAMS): Emit useful warning message + if --quiet is used for the configure script. + * configure: Regenerated. + +2003-04-16 Werner LEMBERG + + * src/devices/grohtml/post-html.cpp (text_glob::text_glob): + Add `const' to second argument. + (html_printer::add_table_end): Add `const' to argument. + * src/devices/grohtml/html-text.cpp (html_text::issue_tag): Add + `const' to arguments. + * src/devices/grohtml/html-text.h: Updated. + + * src/devices/grolbp/charset.h (symset): Use `unsigned char'. + * src/devices/grolbp/lbp.h (lbpputc): Use `unsigned char' for + argument. + + * src/devices/grotty/tty.cpp (tty_printer::make_rgb_string): Use + cast for integer constant. + + * src/preproc/html/pre-html.cpp (image_device): Use `const'. + (writeNbytes): Add `const' to first argument. + (writeString): Add `const' to argument. + (char_buffer::can_see): Add `const' to third argument. + * src/preproc/html/pushback.cpp (pushBackBuffer::isString): Add + `const' to argument. + * src/preproc/html/pushback.h: Updated. + + * src/preproc/soelim/soelim.cpp (include_list): Add `const'. + (include_path_append): Add `const' to argument. + (do_file): Updated. + + * src/roff/troff/uniglyph.cpp (unicode_to_glyph_list): Use `const' + for `value'. + (unicode_to_glyph_init::unicode_to_glyph_init): Updated. + * src/roff/troff/uniuni.cpp (unicode_decompose_list): Use `const' + for `value'. + (unicode_decompose_init::unicode_decompose_init): Updated. + * src/roff/troff/glyphuni.cpp (glyph_to_unicode_list): Use `const' + for `value'. + (glyph_to_unicode_init::glyph_to_unicode_init): Updated. + * src/roff/troff/input.cc (process_startup_file): Add `const' to + argument. + + * tmac/hyphenex.sh: Make script more portable by using a here + document. + +2003-04-15 Werner LEMBERG + + Renamed all `*.cc' files to `*.cpp'. + Updated all configuration files, makefiles, and documentation. + +2003-04-14 Werner LEMBERG + + * tmac/hyphenex.sh: Slight improvements. + +2003-04-13 Werner LEMBERG + + * font/devascii/R.proto, font/devcp1037/R.proto, + font/devlatin1/R.proto, font/devutf8/R.proto: Fill up remaining + character slots with unnamed glyphs. + + * tmac/an-old.tmac: Fix hyphenation value if `cR' is active. + (an-first): New global variable. + (an-header): Emit vertical space between multiple man pages. + +2003-04-11 Werner LEMBERG + + * doc/groff.texinfo, man/groff_out.man: \S only accepts integer + values. + +2003-04-10 Werner LEMBERG + + * PROBLEMS: Revised. + +2003-04-10 Bernd Warken + + * doc/webpage.ms: Improved. + +2003-04-09 Werner LEMBERG + + Add register \n[.height] which returns the value of \H. + Add register \n[.slant] which returns the value of \S. + + * src/roff/troff/env.cc (init_env_requests): Implement. + * NEWS, man/groff_diff.man, man/groff.man, doc/groff.texinfo: + Document. + +2003-04-08 Werner LEMBERG + + * tmac/html.tmac: Move some of the data into html-end.tmac. + Remove most of the character translations for eqn since html fonts + now cover those characters. + Load www.tmac. + * tmac/html-end.tmac: New file. + * tmac/troffrc: Load html.tmac not www.tmac for -Thtml. + * tmac/troffrc-end: Load html-end.tmac not html.tmac for -Thtml. + * tmac/Makefile.sub (NORMALFILES): Add html-end.tmac. + +2003-04-07 Werner LEMBERG + + * man/groff_out.man: Document negative values of `N' if -Thtml is + used. + +2003-04-06 Werner LEMBERG + + * Makefile.comm (depend.temp): Check location of YTABC. + +2003-04-05 Maciej W. Rozycki + + * contrib/mom/Makefile.sub (GROFFBIN): New variable for groff + binary path. + (groff_bin_path): Rename to GROFF_BIN_PATH. + (GROFF): Use GROFFBIN and GROFF_BIN_PATH. + * doc/Makefile.in (TROFFBIN): New variable for troff + binary path. + (GROFFBIN): New variable for groff binary path. + (groff_bin_path): Rename to GROFF_BIN_PATH. + (TROFF): Use TROFFBIN. + (GROFF): Use GROFFBIN and GROFF_BIN_PATH. + * doc/Makefile.sub (GROFFBIN): New variable for groff + binary path. + (groff_bin_path): Rename to GROFF_BIN_PATH. + (GROFF): Use GROFFBIN and GROFF_BIN_PATH. + + * Makefile.comm (install_dev): Install scripts from DEVSCRIPTS + with INSTALL_SCRIPT. + (uninstall_dev): Uninstall scripts from DEVSCRIPTS. + * Makefile.dev (all): Depend on DEVSCRIPTS. + (install_dev): Likewise. + * font/devdvi/Makefile.sub (DEVSCRIPTS): New variable to hold + scripts. + * font/devps/Makefile.sub (DEVSCRIPTS): Likewise. + (DEVGENSCRIPTS): New variable to hold generated scripts. + +2003-04-05 Werner LEMBERG + + * src/libs/libdriver/input.cc (IntArray::operator[], + IntArray::get_data): Remove meaningless `const' in return value. + + * README.CVS: New file. + +2003-04-04 Werner LEMBERG + + Check for stdint.h in C++, not in C. + + * aclocal.m4 (GROFF_STDINT_H): New function, + * configure.ac: Check for stdint.h with GROFF_STDINT_H instead of + AC_CHECK_HEADERS. + * configure, src/include/config.hin: Regenerated. + * src/libs/libgroff/tmpname.cc: Use HAVE_CC_STDINT_H. + + + Fix handling of   in grohtml. To do this, troff emits `N' + with a negative value, representing the width of the unbreakable + space (only for -Thtml). grohtml then converts this back to +   and uses the value of N as its width. + + * src/roff/troff/node.cc (space_char_hmotion_node::tprint, + unbreakable_space_node::tprint): Emit `N-'. + * src/include/printer.h (printer::set_numbered_char): Make it + virtual. + Make members `font_table' and `nfonts' protected instead of private. + * src/devices/grohtml/post-html.cc + (html_printer::set_numbered_char): New member function. + + + * src/libs/libgroff/maxfilename.cc: + s/HAVE_LIMITS_H/HAVE_CC_LIMITS_H/. + + * src/roff/troff/node.cc (unbreakable_space_node::tprint): Don't + emit word marker. + +2003-04-03 Sergey A. Osokin + + * man/roff.man: Small fixes. + +2003-04-03 Werner LEMBERG + + Make groff independent from locale's numeric settings. + + * configure.ac: Check for `setlocale'. + * configure, src/include/config.hin: Regenerated. + + * src/include/lib.h: Handle HAVE_SETLOCALE. + + * src/devices/grodvi/dvi.cc (main), src/devices/grolj4/lj4.cc + (main), src/devices/grops/ps.cc (main), src/preproc/grn/main.cc + (main), src/preproc/pic/main.cc (main): Call `setlocale'. + + + * doc/groff.texinfo: Change dir category to `Typesetting'. + (Man font macros): Mention that there is no space between arguments + of .BI and friends. + + * src/libs/libdriver/printer.cc, src/devices/grotty/tty.cc + (*printer::change_color, *printer::change_fill_color): Add missing + `const'. + +2003-04-02 Werner LEMBERG + + * src/devices/grohtml/html-table.cc (html_table::emit_col, + html_table::is_gap): Compute table widths after converting border + positions to avoid rounding errors. + +2003-04-01 Werner LEMBERG + + * src/devices/grohtml/html-text.cc (html_text::do_space): Handle + `space_emitted' properly. + +2003-03-31 Werner LEMBERG + + * src/devices/grohtml/html-table.cc: Fix column width calculation. + (html_table::set_linelength): Don't add 1. + (html_table::add_indent): Don't subtract 1. + + * tmac/html.tmac: Set default page offset to zero. + +2003-03-30 Werner LEMBERG + + Make groff emit ` ' for `\ ' and `\~' if `-Thtml' is used. + + * src/roff/troff/node.cc (space_char_hmotion_node::tprint, + unbreakable_space_node::tprint): New functions. + (troff_output_file): Make space_char_hmotion_mode::tprint and + unbreakable_space_node::tprint to friends. + * src/roff/troff/node.h: Updated. + + * font/devhtml/R.proto: Add ` ' at position 0xA0 (as defined + in the HTML standard). + +2003-03-29 Werner LEMBERG + + * src/roff/troff/env.cc (point_size): Fix emission of html tag. + Otherwise, the following code + + .di xxx + .ps 10 + a + .br + .di + x\*[xxx] + + produces `x a' instead of `xa'. This is a temporary fix, disabling + font changes in diversions for -Thtml. + + * tmac/an-old.tmac (TH, SH): Use `HTML-TAG-NS' instead of + `HTML-TAG'. + (an-do-tag-html): Merge with ... + (an-do-tag): This macro. + Change code slightly to circumvent grohtml bug. + * tmac/troffrc-end: Define dummy for HTML-TAG-NS. + + * src/devices/grohtml/html-table.cc (html_table::emit_col, + html_table::is_gap): Round `width' properly. + + * tmac/html.tmac: Provide some default layout parameters for + grohtml. + + * font/devhtml/DESC.proto: Don't use discrete values for `sizes' + command. + +2003-03-28 Werner LEMBERG + + src/devices/grops/ps.cc (ps_printer::do_import): Fix error message. + +2003-03-27 Werner LEMBERG + + * tmac/an-old.tmac (BT): Don't call .tl if register `ps4html' is + defined. + +2003-03-20 Werner LEMBERG + + * src/roff/troff/env.cc (vertical_spacing): Allow zero value for + `.vs'. + * doc/groff.texinfo: Updated. + +2003-03-19 Werner LEMBERG + + * src/roff/troff/input.cc (process_input_stack) : Reset `have_input'. + +2003-03-18 Werner LEMBERG + + * src/roff/groff/groff.man: Mention groff_trace man page. + +2003-03-16 Werner LEMBERG + + * Makefile.in (LIBEXT): New variable to indicate the file extension + of library files. Computed heuristically from $(OBJEXT). + (MDEFINES): Add $(LIBEXT). + * Makefile.lib, Makefile.comm: Use it. + + * src/utils/pfbtops/pfbtops.c (get_text): New function. Split + overlong lines into smaller chunks. + (get_binary): New function. + (main): Use them. + * src/utils/pfbtops/pfbtops.man: Updated. + +2003-03-15 Colin Watson + + * src/roff/groff/groff.man: Minor syntax fix. + +2003-03-14 Egil Kvaleberg + + * src/devices/grops/ps.cc (ps_printer::media_set, + ps_printer::~ps_printer): Handle zero paper width and length. + +2003-03-13 Werner LEMBERG + + Add options -p and -l to grodvi. + + * src/devices/grodvi/dvi.cc: Include paper.h. + (landscape_flag, user_paper_length, user_paper_width): New global + variables. + (dvi_printer::begin_page): Emit `papersize' special. + Set color after initialization of `cur_h' and `cur_v'. + (main): Add options `-l' and `-p'. + * font/devdvi/Makefile.sub (DESC): Set `papersize'. + * src/devices/grodvi/grodvi.man, NEWS: Updated. + + * src/devices/grops/psrm.cc (valid_input_table): Fixed. + +2003-03-12 Werner LEMBERG + + * src/devices/grops/grops.man: Move documentation of .PSPIC to... + * man/groff_tmac.man: This man page. + * man/groff_font.man: Declare `paperwidth' and `paperlength' as + deprecated. + + * tmac/X.tmac: Don't load pspic.tmac. + +2003-03-11 Werner LEMBERG + + Make variable `pr' local to libdriver/input.cc. Based on a patch + by Bernd Warken . + + * src/include/driver.h (pr): Removed. + + * src/libs/libdriver/input.cc (pr): New global variable. + (do_file): Deallocate `pr'. + * src/libs/libdriver/printer.cc (pr): Removed. + + * src/devices/grodvi/dvi.cc (main), src/devices/grohtml/post-html.cc + (main), src/devices/grolbp/lbp.cc (main), src/devices/grolj4/lj4.cc + (main), src/devices/grops/ps.cc (main), src/devices/grotty/tty.cc + (main): Don't delete `pr'. + +2003-03-10 Werner LEMBERG + + * tmac/a4.tmac, tmac/composite.tmac: Use `.do'. + * tmac/papersize.tmac: New file. + * tmac/troffrc: Include `papersize.tmac'. + * tmac/Makefile.sub (NORMALFILES): Add `papersize.tmac'. + * tmac/an-old.tmac: Set LT to LL by default. + + * NEWS, MANIFEST, tmac/groff_man.man, man/groff_tmac.man, + doc/groff.texinfo: Updated. + + * src/libs/libgroff/paper.cc (add_iso_paper): Fix very embarassing + bug which caused all odd iso papers to have wrong dimensions. + + * src/devices/grops/ps.cc (user_paper_width): New global variable. + (main) <'p'>: Set `user_paper_width' also. + (ps_printer::media_width, ps_printer::media_height): Use values + given with option `-p'. + +2003-03-09 Werner LEMBERG + + * src/include/nonposix.h: Provide default for SET_BINARY. + + * src/devices/grodvi/dvi.cc, src/devices/grolbp/lbp.cc, + src/devices/grolj4/lj4.cc, src/devices/grops/ps.cc: Call SET_BINARY + unconditionally. + + * src/utils/pfbtops/pfbtops.c: Call SET_BINARY unconditionally. + (main): Treat \r\n as \n. + +2003-03-08 Werner LEMBERG + + * tmac/an-old.tmac: Use register `HY' to control hyphenation. + * NEWS, tmac/groff_man.man, doc/groff.texinfo: Document it. + +2003-03-07 Werner LEMBERG + + Added support to access more than 256 glyphs in Type 1 fonts. + + * src/devices/grops/ps.cc (subencoding): New structure. + (style): Add `sub' field. + Updated all users. + (ps_printer): Add `subencodings' and `next_subencoding_index' fields. + Add `set_subencoding', `get_subfont' and `encode_subfont' member + functions. + Updated all users. + (ps_printer::set_char): Use `set_subencoding'. + (make_subencoding_name): New function. + (ps_printer::set_style): Handle case where `sty.sub' is not zero. + (ps_printer::~ps_printer): Emit subencoding definitions. + + * src/devices/grops/psrm.cc (valid_input_table): New array to + properly support EBCDIC. + (white_space): Add `\f'. + (ps_get_line): Change first argument to be of type `string &'. + Updated all callers. + This allows to get lines of arbitrary length. + Use `valid_input_table'. + Remove warning about non-conforming PS line length. This seems + not to be of great importance -- for example, dvips don't emit + a warning either. + (PS_LINE_MAX): Removed. + (matches_comment): Change first argument to be of type `string &'. + + * src/devices/grops/grops.man, src/devices/grops/TODO: Updated. + + * src/utils/afmtodit/afmtodit.pl (%unicode_decomposed, + %AGL_to_unicode, %default_ligatures): New hash tables. + Read all map entries. + Add unencoded characters. + Check for default ligatures if there are no `L' entries. + Print all kern entries. + Print all characters in charset. + * src/utils/afmtodit/afmtodit.man: Updated. + + * font/devps/*: Regerated all fonts. + + * tmac/latin[129].tmac, tmac/cp1047.tmac: Don't test for existence + of characters, just use `.trin'. Otherwise the mapping depends + on the font encoding. + * tmac/ps.tmac: Add `fi' and `fl'. + Improve `Fi' and `Fl'. + * tmac/X.tmac, tmac/lbp.tmac, tmac/tty.tmac: Improve `Fi' and `Fl'. + * tmac/Xps.tmac: Fix `em'. + + * NEWS: Updated. + +2003-03-04 Werner LEMBERG + + * src/roff/troff/input.cc (charinfo_to_node_list): Reset + `have_input'. + +2003-03-03 Werner LEMBERG + + * Makefile.sub (DISTCLEANFILES): Add gxditview._man. + + * font/devps/generate/textmap: Remove entry `similarequal'. + * font/devps/symbolmap: Updated. + +2003-03-02 Werner LEMBERG + + * src/libs/libgroff/font.cc (font::load): Fix error message for + bad character type. + + * src/devices/grops/grops.man: Improve documentation of the -b + flag. + + * tmac/tty.tmac: Load latin1.tmac for all TTY devices except + `ascii' and `cp1047'. + +2003-03-01 Werner LEMBERG + + Document composite glyphs and the `composite' request. + + * man/groff.man, man/groff_diff.man, doc/groff.texinfo: Do it. + +2003-02-28 Werner LEMBERG + + * font/devdvi/generate/ec.map: Add some more Unicode entities. + * font/devdvi/*EC: Updated. + + * tmac/composite.tmac, tmac/latin2.tmac, tmac/latin9.tmac: New files. + * tmac/latin1 (latin1-tr): Undo any previous mapping. + * tmac/troffrc: Load `composite.tmac'. + * tmac/Makefile.sub (NORMALFILES): Updated. + + * doc/groff.texinfo (Input Encodings): New section. + * NEWS: Updated. + +2003-02-27 Werner LEMBERG + + * doc/texinfo.tex: New version 2003-02-11.06. + + * tmac/doc-common (Dt): Don't emit warning for unknown section. + * tmac/groff_mdoc.man: Fix description of `Dt'. + +2003-02-26 Egil Kvaleberg + + * font/devps/prologue.ps: Fix for included Postscript that does + a setpagedevice -- which is now safely ignored. + + * NEWS: Updated. + + * src/devices/grops/ps.cc: Now sets the page size in the generated + document. This is done in two ways: Via a %%-comment for gv and + the like, and via a PageSize and setpagedevice for programs that + understands Postscript proper, like ps2pdf. + + * src/devices/grops/ps.h: New broken-flag to avoid page size + definition, if required. + + * src/devices/grops/grops.man: New broken-flag 16 mentioned. + + * doc/Makefile.in: Added -nosetpage flag (via @pnmtops_nosetpage@). + Not really necessary due to the fix in prologue.ps, but cleaner: + Such information does not belong in an .eps file. + + * doc/Makefile.sub: See doc/Makefile.in. + +2003-02-26 Ralph Corderoy + + * aclocal.m4 (GROFF_PNMTOPS_NOSETPAGE): Use P2 format for testing + instead of P1 since the latter is broken in some versions of netpbm. + * configure: Updated. + +2003-02-26 Larry Kollar + + Make man pages more customizable. + + * tmac/an-old.tmac (FT): New register holding footer distance from + bottom. + (HF): New string holding the default heading font. + (TH): Handle registers `IN' and `SN' set on the command line. + Use `FT'. + (PT, BT): New strings to customize header and footer lines. + (an-header, an-footer): Use them. + (SH, SS): Use `HF'. + * tmac/groff_man.man: Document changes. + + * doc/groff.texinfo: Document man changes. + Document Ultrix extensions of man. + +2003-02-26 Werner LEMBERG + + * src/roff/troff/input.cc (do_width, do_if_request): Reset + `have_input' after changing back to old environment. + + * src/devices/grolbp/lbp.cc (lbp_printer::set_line_thickness): Move + function up to be defined before first call. This is necessary to + avoid a compilation problem with Sun's WorkShop 6 C++ compiler. + + * src/utils/afmtodit/afmtodit.pl: Make script search for files in + the default font directory also. Based on a patch from James + J. Ramsey . + * src/utils/afmtodit/Makefile.sub (afmtodit): Handle @FONTDIR@. + * src/utils/afmtodit/afmtodit.man: Document it. + + * NEWS: Updated. + + * tmac/groff_man.man, doc/groff.texinfo: Many minor fixes. + +2003-02-25 Gaius Mulley + + * aclocal.m4 (GROFF_HTML_PROGRAMS): Add test for pnmtops. + (GROFF_PNMTOPS_NOSETPAGE): New macro. + * configure.ac: Use it. + * configure: Regenerated. + * Makefile.in: Updated. + + * tmac/Makefile.sub (NORMALFILES): Remove www.tmac. + (CLEANADD): Add www.tmac-sed. + (pnmtops_nosetpage): Define default. + (install_data): Handle www.tmac-sed and substitute + @PNMTOPS_NOSETPAGE@. + (stamp-sed): Add www.tmac. + * tmac/www.tmac: Rewritten, based on a patch by Bernd Warken. + It now breaks URLs at suitable places. + (www:substring_ok): New register set by... + (www:@test_substring): New macro. + (www:error): New alias to www-error. + (www:lenstr, www:splitstr, www:url_breaks, www:url_breaks_splitted): + New macros. + (URL): Use www:url_breaks. + (PIMG, MPIMG): Use @PNMTOPS_NOSETPAGE@. + (CDS, CDE): New macros. + +2003-02-25 Werner LEMBERG + + * src/devices/grops/ps.cc (ps_printer::define_encoding): Avoid + buffer overflow. + +2003-02-24 Werner LEMBERG + + Contrary to the PCL5 Developer's Guide, the ascenders in TFM files + can be negative also. + + * src/utils/hpftodit/hpftodit.cc (char_info): `ascent' must be + `int16'. + (read_char_table): Avoid negative ascenders. + (output_charset): Add cast. + * font/devlj4/*: Regenerated. + + Replace unnamed glyphs for DVI fonts with `uXXXX' glyph names where + possible. + + * font/devdvi/generate/{tc,texttt,ec,texmi,texsy,textex}.map: Do it. + * font/devdvi/generate/textex.map: Map glyph 23 to `u21C6' instead + of `<>'. + * font/devdvi/*: Regenerated. + + Map `la' and `ra' to U+27E8 and U+27E9. These two characters have + normal width, while the previously used characters (U+2329 and + U+232A) are classified as wide due to canonical equivalence with the + CJK punctuation characters U+3008 and U+3009. + + * font/devutf8/R.proto: Updated. + * src/roff/troff/uniglyph.cc, src/roff/troff/glyphuni.cc: Ditto. + + * man/groff_char.man: Simplify handling of table traps by + introducing `start block' and `end block' macros. + (Ns, Ne, 2s, 2e, Ds, De): New macros. + (DL): Make it work with Unix troff also. + Fix code values of `la' and `ra'. + + * tmac/dvi.tmac: Define `<>' for CW and CWI. + +2003-02-23 Gaius Mulley + + * src/devices/grohtml/post-html.cc (element_list::~element_list): + New destructor, fixing a major memory leak. + +2003-02-22 Werner LEMBERG + + * font/devhtml/R.proto, font/devutf8/R.proto: Flip `*f' and `+f' + to be in conformance with Unicode 3.0 and newer. + + * font/devlj4/generate/text.map: Add `Eu'. + * font/devlj4/generate/special.map: Flip `*e' and `+e'. + * font/devlj4/S: Regenerated. + + * man/groff_char.man: Completely rewritten. + + * doc/groff.texinfo: Fix description of request and macro arguments. + +2003-02-20 Gaius Mulley + + Valgrind fixes. + + * src/devices/grohtml/html-table.cc (html_table::~html_table): + Deallocate `columns' list. + * src/devices/grohtml/post-html.cc (char_block::~char_block): + New destructor. + (text_glob::text_glob_html, text_glob::text_glob_special, + text_glob::text_glob_line, text_glob::text_glob_auto_image, + text_glob::text_glob_tag): Avoid memory leaks. + (text_glob::remember_table): Free memory before reassigning. + +2003-02-19 Werner LEMBERG + + Add glyph `+e', greek lunate epsilon symbol, and `-h' (with the + alias `hbar'), the Planck constant over two pi. + + * font/devdvi/generate/texmi.map: Use `*e' for position 15 and + `+e' for position 34. + * font/devdvi/generate/texsy.map: Replace `DI' and `HE' with + `u2662' and `u2661'. + * font/devdvi/{MI,S}: Regenerated. + * font/devhtml/R.proto, font/devutf8/R.proto: Add `+e', `-h', `hbar'. + * font/devlbp/*: Add `hbar' alias. + * font/devlj4/generate/special.map: Ditto. + * font/devlj4/S: Regenerated. + * font/devps/generate/symbolchars: Add `+e'. + * font/devps/generate/textmap: Fix PS name for `-h'. + Add `hbar' alias. + * font/devps/symbolmap: Regenerated. + + * src/devices/grops/ps.cc (transform_fill): Removed since unused. + + * src/roff/troff/glyphuni.cc (glyph_to_unicode_list): Add `+e', + `-h', `hbar'. + * src/roff/troff/uniglyph.cc (unicode_to_glyph_list): Add `+e', + `-h'. + + * tmac/X.tmac, tmac/ps.tmac: Provide definitions for `-h' and + `hbar'. + * tmac/tty-char.tmac: Add `+e'. + +2003-02-17 Werner LEMBERG + + Another round trying to really fix problems with `have_input'. + + * src/roff/troff/input.cc (input_stack::get): Handle `have_input'. + (token::next) <'\n'>, <\'\n'>: Don't handle `have_input'. + + * src/devices/grotty/tty.cc (tty_printer::put_color): Fix color + handling if both foreground and background colors are default. + + * doc/groff.texinfo (Debugging): Document .lf differences to + AT&T troff. + +2003-02-16 Werner LEMBERG + + * src/devices/grotty/tty.cc (tty_printer::make_rgb_string): Avoid + null-bytes in created string. + + * src/roff/troff/input.cc (lookup_color, interpolate_macro, + alias_macro, lookup_request): Improve warning messages. + + * src/roff/troff/node.cc (suppress_node::tprint): Use `strsave', + not `strdup'. + Free `last_image_filename'. + + * src/preproc/html/pre-html.cc (char_block::char_block): Initialize + `buffer'. + (imageList::createPage, imageList::createImage): Use `free', not + `a_delete'. + (imageItem::~imageItem): Free `imageName'. + (addRegDef): Use `strsave', not `strdup'. + (get_resolution): Free `pathp'. + +2003-02-15 Werner LEMBERG + + * src/devices/grotty/tty.cc (tty_printer::tty_printer): Fix pointer + to `dummy'. + +2003-02-14 Werner LEMBERG + + Add memory management for colors to deallocate unnamed colors + properly. + + * src/include/color.h (color): New members `free_list' and `next'. + New member functions `new' and `delete'. + Add destructor. + * src/libs/libgroff/color.cc: Implement it. + + * src/libs/libgroff/font.cc (font::add_kern): Use integer cast + for array size of new operator. + + * src/libs/libdriver/input.cc (IntArray::operator[]): Remove + redundant comparison. + + * src/roff/troff/input.cc (word_space_node::reread, + hmotion_node::reread): Avoid warning about unused parameter. + (reset_output_registers): Remove redundant parameter. + (define_color): Undo change 2003-02-12. + + * src/roff/troff/reg.h: Updated. + + * src/roff/troff/node.cc (troff_output_file::really_print_line, + output_file::put_filename, real_output_file::really_put_filename, + ascii_output_file::really_print_line, + break_char_node::get_hyphen_list): Avoid warning about unused + parameter. + (suppress_node::tprint): Updated. + + * configure.ac: Check declaration for rand() and srand(). + * configure: Regenerated. + + * src/preproc/pic/pic.h: Declare fmod(), rand(), and srand() + conditionally. + * src/preproc/pic/pic.y: Remove declaration of fmod(), rand(), + and srand(). + + * src/preproc/eqn/delim.cc (delim_table): Add missing initializers + to avoid compiler warnings. + + * src/preproc/grn/hgraph.cc (HGPrintElt): Second parameter is + unused. + + * src/devices/grops/ps.cc (ps_printer::set_char): Last parameter + is unused. + * src/devices/grops/psrm.cc (skip_possible_newline): Remove first + (unused) parameter. + Updated all callers. + + * src/devices/grotty/tty.cc (tty_printer::set_char): Last parameter + is unused. + * src/devices/grodvi/dvi.cc (dvi_printer::set_char): Ditto. + * src/devices/grolj4/lj4.cc (lj4_printer::set_char): Ditto. + + * src/devices/grohtml/post-html.cc (html_printer::emit_line): + Parameter is unused. + (html_printer::add_table_end): Define parameter conditionally. + * src/devices/grohtml/output.cc (simple_output::special): Parameter + is unused. + + * src/devices/grolbp/lbp.cc: Define _GNU_SOURCE conditionally. + (lbp_printer::set_char): Last parameter is unused. + + * src/utils/indxbib/indxbib.cc (main): Remove redundant comparison. + +2003-02-13 Werner LEMBERG + + New commands \D'Fr ...', \D'Fc ...', etc. for orthogonality. + Make \D'f ...' move horizontally again for backwards compatibility. + Replace it with \D'Fg ...' where appropriate to avoid dependency + on horizontal resolution. + + * src/roff/troff/input.cc (do_get_long_name): New function. + (get_long_name): Call it. + + (read_draw_node): Handle `\D'Fx ...' by calling ... + (read_color_draw_node): New function. + + (read_rgb, read_cmy, read_cmyk, read_gray): New optional argument + `end'. + Pass it to `do_get_long_name' which is used instead of + `get_long_name'. + + * src/libs/libdriver/input.cc (color_from_Df_command): Remove + unnecessary value guard. + (parse_D_command) <'f'>: Add horizontal shift. + + * src/preproc/grn/hgraph.cc (HGPrintElt) : Use \D'Fg ...'. + * src/preproc/pic/troff.cc (troff_output::set_fill): Ditto. + (FILL_MAX): Removed. + + * NEWS, man/groff_diff.man, man/groff.man, doc/groff.texinfo: + Updated. + +2003-02-12 Werner LEMBERG + + * src/roff/troff/input.cc (do_name_test, do_expr_test, + do_zero_width): Push `\n' if closing delimiter is missing. + + (token::next) , <'\n'>, <\'\n'>: Reset `have_input'. + <'F'>: Make \F non-transparent at the beginning of line. + (process_input_stack) : Don't handle + `have_input'. + + (define_color): Free color in case of reassignment. + + * doc/groff.texinfo (@Defesc, @DefescList, @DefescItem, + @DefescListEnd): Use @Var, not @var. + Fix all calls. + + * src/preproc/grn/hgraph.cc (HGPrintElt): Fix typo. + + * src/preproc/pic/object.cc (object_spec::~object_spec): Free + `shaded' and `outlined' arrays. + (object_spec::object_spec): Initialize `shaded' and `outlined'. + (graphic_object::set_fill_color, graphic_object::set_outline_color): + Use strsave. + (closed_object::set_fill_color): Ditto. + * src/preproc/pic/troff.cc (troff_output::set_color): Use strsave + instead of strdup. + (troff_output::reset_color): Use a_delete instead of free. + * src/preproc/pic/main.cc (do_file): Free `out' in case of error. + +2003-02-11 Werner LEMBERG + + * doc/groff.texinfo: Improve documentation of `ad'. + Document that \D'f...' is dependent on the horizontal resolution. + * man/groff_diff.man: Improve documentation of \D'f...'. + + * src/preproc/grn/hgraph.cc (HGPrintElt) : Don't emit + compensating \h'...' for \D'f ...' since the latter no longer moves + current position. + * src/preproc/pic/troff.cc (troff_output::set_fill): Ditto. + +2003-02-10 Werner LEMBERG + + Improve error messages for `x F' (and `F') commands. + + * src/include/error.h: Add declaration for + `current_source_filename'. + * src/libs/libgroff/filename.cc: Add `current_source_filename'. + * src/libs/libgroff/error.cc (do_error_with_file_and_line): Add + parameter for source file string. + Updated all callers. + + * src/libs/libdriver/input.cc: Add `current_source_filename'. + (remember_source_filename): New function. + (parse_x_command <'F'>, do_file <'F'>): Use it. + +2003-02-09 Werner LEMBERG + + Make grotty not emit warnings about unknown colors more than + necessary. + + * src/devices/grotty/tty.cc: Include `ptable.h'. + (TTY_MAX_COLORS): Removed. + (DEFAULT_COLOR_IDX): Defined to -1. + (glyph): Change `back_color_idx' and `fore_color_idx' to `char'. + (tty_printer): Change `curr_back_idx' and `curr_fore_idx' to `char'. + Change `tty_colors' to be a ptable. + First arg of `put_color' is now `char'. + New functions `make_rgb_string' and `tty_color'. + (tty_printer::tty_printer): Use `tty_color'. + (tty_printer::color_to_idx): Return value is now `char'. + Use `tty_color'. + + * src/include/color.h (color): Add `print_color' member function. + * src/libs/libgroff/color.cc (color::print_color): Implement it. + +2003-02-08 Werner LEMBERG + + Valgrind fixes. + + * src/devices/grops/ps.cc (ps_printer::define_encoding): Close + encoding file. + + * src/include/ptable.h (PTABLE::~PTABLE, PTABLE::define): Always + assume that value has been allocated with `new[]', thus use + `a_delete' for deallocation. + + * src/libs/libdriver/input.cc (get_integer_arg, + get_possibly_int_args, parse_x_command, do_file): Use `a_delete' + where appropriate. + + * src/libs/libgroff/new.cc (delete) [!COOKIE_BUG]: Define. + * src/libs/libgroff/nametoindex.cc + (character_indexer::named_char_index): Use `new [1]'. + + * src/preproc/eqn/lex.cc (init_table, do_definition): Use `new + [1]'. + * src/preproc/eqn/text.cc (set_special_char_type): Ditto. + (split_text): Use `a_delete'. + + * src/preproc/pic/pic.y (define_label, define_variable): Use `new + [1]'. + + * src/roff/troff/env.cc (environment::choose_breakpoint): Avoid + harmless memory leak. + (hyphen_trie::read_patterns_file): Initialize `buf'. + * src/roff/troff/node.cc (troff_output_file::troff_output_file): + Initialize `current_fill_color'and `current_glyph_color'. + * src/roff/troff/glyphuni.cc + (glyph_to_unicode_init::glyph_to_unicode_init): Use `new [1]'. + * src/roff/troff/uniuni.cc + (unicode_decompose_init::unicode_decompose_init): Ditto. + * src/roff/troff/uniglyph.cc + (unicode_to_glyph_init::unicode_to_glyph_init): Ditto. + +2003-01-26 Werner LEMBERG + + * src/utils/indxbib/indxbib.cc (main) [__EMX__]: Check with + `access' before calling `unlink'. + (do_file): Handle __EMX__. + + * src/include/nonposix.h: Handle __EMX__. + + * Makefile.in (SEP): New variable; set to @PATH_SEPARATOR@. + (fontpath,tmacpath): Use it. + (MDEFINES): Add it. + Sorted alphabetically. + + * src/preproc/eqn/neqn.sh, src/roff/nroff/nroff.sh: Use + @SEP@. + * src/preproc/eqn/Makefile.sub, src/roff/nroff/Makefile.sub: Handle + @SEP@. + +2003-01-27 Werner LEMBERG + + * src/libs/libgroff/strcasecmp.c, src/libs/libgroff/strncasecmp.c: + New files, copied from gnulib. + * src/libs/libgroff/Makefile.sub (CSRCS): Add them. + * configure.ac: Updated. + * configure: Regenerated. + + * src/include/config.hin: Regenerated. + * src/include/lib.h [!HAVE_STRCASECMP]: Declare `strcasecmp'. + Don't define `strcasecmp' as `strcmp'. + [!HAVE_STRNCASECMP]: Declare `strncasecmp'. + Dont define `strncasecmp' as `strncmp'. + + * src/roff/groff/pipeline.c [!HAVE_STRCASECMP, !HAVE_STRNCASECMP]: + Removed. + +2003-01-26 Werner LEMBERG + + * src/utils/indxbib/indxbib.cc (main) [__EMX__]: Fix typo: + s/unline/unlink/. + +2003-01-25 Werner LEMBERG + + * doc/groff.texinfo (Ligatures and Kerning): Mention limitations. + +2003-01-24 Werner LEMBERG + + Add US-english hyphenation exceptions (converted from Barbara + Beeton's hyphenation exception log reports which appear irregularly + in TUGBoat). + + * tmac/hyphen.us: Updated to latest version. + * tmac/README: Updated. + * tmac/hyphenex.us, tmac/hyphenex.sh: New files. + * tmac/troffrc: Load `hyphenex.us'. + * tmac/Makefile.sub (NORMALFILES): Add `hyphenex.us'. + * doc/groff.texinfo: Updated. + +2003-01-23 Werner LEMBERG + + Improve hyphenation slightly. This is a first step in redesigning + the hyphenation algorithm to make it more flexible (e.g. allowing + kerns and ligatures between the hyphenation character and the + following character -- while not used normally in English, other + languages like German would benefit). + + * src/roff/troff/env.cc (environment::hyphenate_line): Use + assertion instead of if-clause. + Let `get_hyphen_list' return the number of involved characters in + the hyphenation pattern instead of computing it directly (which + often yields too small values). + * src/roff/troff/node.h (*::get_hyphen_list): Add second parameter. + * src/roff/troff/node.cc (*::get_hyphen_list): Handle new second + parameter. + +2003-01-22 Werner LEMBERG + + Fixing a bug which caused groff to hang if the hyphenation exception + dictionary tried to grow. + + * src/roff/troff/env.cc (hyphen_trie::insert_hyphenation, + hyphen_trie::read_patterns_file, do_hyphenation_patterns_file): Use + pointer to dictionary. + +2003-01-20 Werner LEMBERG + + * src/utils/afmtodit/afmtodit.pl: Add switch `-m' to suppress + negative left italic correction. + * src/utils/afmtodit/afmtodit.man: Document it. + + * font/devps/generate/Makefile (RFLAG): Add `-m'. + * font/devps/{AB,AR,BMB,BMR,CB,CR,EURO,HB,HR,HNB,HNR,NB,NR,PB,PR, + S,TB,TR,ZD,ZDR}: Regenerated with afmtodit options `-i 0 -m'. + + * NEWS: Updated. + +2003-01-16 Werner LEMBERG + + * NEWS: Updated. + +2003-01-16 Jörgen Grahn + + * src/preproc/refer/refer.man: Mention REFER environment variable. + +2003-01-05 Werner LEMBERG + + Similar to \[is], the square root glyph (\[sr]) and the square root + extension glyph (\[radicalex]) are now text symbols. The new + mathematical versions are called \[sqrt] and \[sqrtex], + respectively. + + * font/devX*/S: Regenerated. + * font/devdvi/generate/texex.map: Rename `sr[0123]' to `sqrt[0123]'. + * font/devdvi/generate/texsy.map: Rename `sr' to `sqrt'. + * font/devdvi/EX, font/devdvi/S: Regenerated. + * font/devhtml/R.proto, font/devutf8/R.proto: Add `sqrt'. + * font/devlj4/generate/special.map: Add `sqrt'. + * font/devlj4/S: Regenerated. + * font/devps/generate/textmap: Add `sqrt'. + * font/devps/S, font/devps/symbolmap: Regenerated. + + * src/preproc/eqn/sqrt.cc (SQRT_CHAR, RADICAL_EXTENSION_CHAR, + SQRT_CHAIN, BAR_CHAIN): Use `sqrt*' and `sqrtex*'. + * src/roff/troff/input.cc (init_charset_table): Make `sqrtex' + overlap horizontally. + + * tmac/X.tmac, tmac/ps.tmac, tmac/lj4.tmac: Add `sqrtex'. + * tmac/dvi.tmac: Add `sr', and `sqrtex'. + Fix `radicalex'. + + * doc/groff.texinfo, man/groff_diff.man: Document that `radicalex' + and `sqrtex' are overlapping glyphs. + +2003-01-04 Werner LEMBERG + + * font/devdvi/generate/texsy.map: Add `is'. + * font/devps/symbolmap: Regenerated. + * font/devdvi/*TC, MI, S: Regenerated. + + * tmac/dvi.tmac: Remove `is'. + +2003-01-03 Werner LEMBERG + + `is' is now a text symbol (only relevant for dvi). The math variant + can be accessed with `integral'. + + * font/devX*/S: Regenerated. + * font/devdvi/generate/texex.map: Remove `is'. + * font/devdvi/EX: Updated. + * font/devhtml/R.proto, font/devutf8/R.proto: Add `integral'. + * font/devlj4/generate/special.map: Ditto. + * font/devlj4/S: Regenerated. + * font/devps/generate/textmap: Add `integral'. + * font/devps/S: Regenerated. + + * tmac/dvi.tmac: Define `is'. + + * src/roff/troff/glyphuni.cc (glyph_to_unicode_list): Add `integral'. + + * src/preproc/tbl/main.cc (process_format): Fix error message. + +2003-01-02 Werner LEMBERG + + * font/devhtml/R.proto, font/devutf8/R.proto: Add `ne' and `nc'. + * font/devps/textmap: Fix entries for `ne' and `nc'. + * font/devps/symbolmap: Regenerated. + + * src/roff/troff/glyphuni.cc (glyph_to_unicode_list), + src/roff/troff/uniglyph.cc (unicode_to_glyph_list): Add `18', + `38', `58', `78', `-+', `|=', `nc', `ne'. + + * tmac/dvi.tmac: Add `nm', `ne', `nc'. + Use `schar' for `aq'. + * tmac/ps.tmac, tmac/X.tmac: Add `nc' and `ne'. + * tmac/ec.tmac: Add `SC' to special fonts for `CW' and `CWI'. + * tmac/tty.tmac: Add `ne'. + + * src/roff/troff/node.cc (make_glyph_node): Test with `get_macro' + for fallback glyphs. + +2002-12-29 Werner LEMBERG + + Add glyph `|='. + + * font/devX*/*: Regenerated. + * font/devdvi/generate/ec.map: Remove `eq'. + * font/devdvi/generate/texsy.map: Make `~=' the same as `~~'. + Assign `|=' to position 39. + * font/devdvi/*EC, S: Regenerated. + * font/devhtml/R.proto, font/devutf8/R.proto: Add `|='. + * font/devlj4/generate/special.map: Make `~=' the same as `~~'. + Assign `|=' to position 549. + * font/devps/generate/textmap, font/devps/enerate/symbolmap: Remove + `equalmath'. + Add `uni2243' for `|='. + + * tmac/ec.tmac: Add `eq'. + * tmac/dvi.tmac: Add `=~'. + * tmac/tty-char.tmac, tmac/ps.tmac, tmac/X.tmac, tmac/lbp.tmac: Add + `|='. + +2002-12-21 Werner LEMBERG + + * font/devdvi/generate/tc.map: Remove `**'. + * font/devdvi/*TC: Regenerated. + * font/devhtml/R.proto, font/devutf8/R.proto: Add `18', `38', `58', + `78', `<<', `>>'. + * font/devutf8/NOTES: Updated. + + * src/roff/troff/charinfo.h (charinfo): Add `setx_macro' function. + Don't give default parameter to `set_macro'. + * src/roff/troff/input.cc (do_define_character): Use `setx_macro' + instead of `set_macro'. + (charinfo::setx_macro): Implement it. + (charinfo::set_macro): Don't change `mode'. + + * tmac/tty.tmac: Add `18', `38', `58', `78', `<<', `>>'. + * tmac/ps.tmac, tmac/X.tmac: Add `<<', `>>'. + * tmac/dvi.tmac: Define `!=' with `.schar'. + +2002-12-20 Werner LEMBERG + + * font/devX*/S: Regenerated. + * font/devdvi/generate/ec.map: Remove `pl'. + * font/devdvi/generate/tc.map: Remove `mi', `14', `12', `34'. + * font/devdvi/*{TC,EC}: Regenerated. + * font/devhtml/R.proto: Add `-+'. + Remove double entries for `rk', `lk', `lt', `rt', `rb', `lb'. + * font/devlbp/*: Remove `or'. + * font/devlj4/generate/special.map: Remove `or'. + * font/devlj4/S: Regenerated. + * font/devps/generate/textmap: Add `fiveeighths', `oneeighth', + `seveneighths', `threeeighths'. + Remove `plusmath'. + Replace `minusplus' with `uni2213'. + * font/devps/symbolmap: Regenerated. + * font/devutf8/R.proto: Replace `shc' with unnamed glyph. + Add `-+'. + + * src/roff/troff/charinfo.h (charinfo): Add `is_normal' inline + function. + * src/roff/troff/node.cc (troff_output_file::put_char_width): + Call glyph_color and fill_color even if tcommand_flag isn't set. + (make_node, node::add_char): Check not ci->is_fallback but + ci->is_normal. + + * tmac/lj4.tmac, tmac/lbp.tmac: Define `or'. + * tmac/ec.tmac: Add .rchar entry for `f/'. + Don't remove `12', `14', `34'. + Define `pl' to be always roman. + * tmac/ps.tmac (ps-frac, ps-frac-mono): New macros. + Define `18', `38', `58', `78'. + * tmac/tty.tmac: Add `-+'. + * tmac/dvi.tmac: Define `f/'. + (dvi-frac): Use `f/'. + * tmac/X.tmac (X-frac, X-frac-mono): New macros. + Define `18', `38', `58', `78'. + +2002-12-15 Colin Watson + + * contrib/pic2graph/pic2graph.sh: Add missing `;;'. + +2002-12-10 Werner LEMBERG + + Add glyph `tno', a textual variant of `no'. + + * font/devX*/*: Regenerated. + * font/{devcp1047,devlatin1,devutf8,devhtml}/R.proto: Add `tno'. + * font/devdvi/generate/{tc.map: Replace `no' with `tno'. + * font/devdvi/generated/{texsy,textex}.map: Add `tno'. + * font/devdvi/*: Regenerated. + * font/devlbp/*: Add `tno'. + * font/devlj4/generate/tex.map: Replace `no' with `tno'. + * font/devlj4/*: Regenerated. + * font/devps/generate/textmap: Replace `no' with `tno'. + * font/devps/generate/symbolchars: Add `no'. + * font/devps/*: Regenerated. + + * src/roff/troff/glyphuni.cc (glyph_to_unicode_list): Add `tno'. + + * tmac/cp1047.tmac, tmac/latin1.tmac: Replace `no' with `tno'. + * tmac/tty-char.tmac: Add entry for `tno' and `3d'. + + * NEWS: Updated. + + * tmac/dvi.tmac: Replace most `\\' with `\E'. + Add definition for `sd'. + * tmac/X.tmac, tmac/ps.tmac: Replace most `\\' with `\E'. + + * tmac/eqnrc : Use `integral' instead of `is' glyph. + +2002-12-08 Werner LEMBERG + + * tmac/an-old.tmac (TH): Use integer value for `IN' if in nroff + mode to avoid rounding errors. + (an-do-tag, an-do-tag-html, RS, RE): Remove redundant `.br'. + + * src/roff/groff/groff.man, src/roff/nroff/nroff.man, + src/roff/troff/troff.man: Improve documentation of -T. + +2002-12-07 Jeff Conrad + + * src/roff/groff/pipeline.c: Don't define `const' for _WIN32. + (run_pipeline) [_WIN32]: Provide working function without `fork'. + +2002-12-06 Werner LEMBERG + + * font/devps/generate/freeeuro.sfd: Make dimensions of Euro.symbol + glyphs compatible to Adobe's Euro fonts (scaling them down a bit). + Scaling Euro.sansserif glyphs down to have the same height as + digits. + Removed unnecessary points; added some extrema. + + * font/devps/EURO, font/devps/freeeuro.afm, font/devps/freeeuro.pfa: + Regenerated. + +2002-12-04 Werner LEMBERG + + * font/devps/generate/freeeuro.sfd: Add glyphs `Euro.symbol.slanted' + and `Euro.symbol.bold.slanted'. + Improve some glyph offsets and widths. + * font/devps/EURO, font/devps/freeeuro.afm, font/devps/freeeuro.pfa: + Regenerated. + * font/devps/generate/Makefile (freeeuro.afm freeeuro.pfa): Fix + typo. + * font/devps/generate/sfdtopfa.pe: Generate PFA in current + direcory. + + * tmac/europs.tmac: Updated to new glyph indices. + Use Euro.symbol for font familiy `A'. + + * doc/groff.texinfo: Minor improvements. + +2002-12-02 Werner LEMBERG + + * font/devdvi/generate.tc.map: s/%O/%0/. + * font/devdvi/*TC: Regenerated. + + * src/roff/troff/div.cc (init_div_requests): Sorted. + + * tmac/dvi.tmac: Remove `Ye'. + * tmac/ec.tmac: Remove `Ye'. + Add .rchar entry for `de'. + + * man/groff.man, man/groff_diff.man: Document register `.pe'. + * doc/groff.texinfo: Document registers `.pe', `.n', and `.w'. + * NEWS: Updated. + +2002-11-30 Werner LEMBERG + + Add PS font for various Euro glyphs. + + * font/devps/generate/freeeuro.sfd: New master font file for + pfaedit. + * font/devps/generate/sfdtopfa.pe: New conversion script for + pfaedit. + * font/devps/generate/Makefile (FONTS): Add `EURO'. + (EURO, freeeuro.afm, freeeuro.pfa): New rules. + * font/devps/freeeuro.pfa, font/devps/freeeuro.afm: Generated from + `freeeuro.sfd'. + * font/devps/EURO: Generated from `freeeuro.afm'. + * font/devps/download: Add `freeuro.pfa'. + * font/devps/Makefile.sub (NORMALFILES): Adde `EURO' and + `freeeuro.pfa'. + + * tmac/europs.tmac: New file. + * tmac/ps.tmac: Include `europs.tmac'. + * tmac/Makefile.sub (DISTFILES): Add `europs.tmac'. + +2002-11-29 Werner LEMBERG + + * font/devdvi/generate/texsy.map: Remove `lh' and `rh'. + * font/devdvi/S: Regenerated. + * font/devhtml/R.proto: Fix `CR' and `ci'. + Add `OK'. + * font/devps/generate/textmap: Fix `lh', `rh', and `sq'. + Remove `bs'. + * font/devps/symbolmap: Regenerated. + * font/devutf8/R.proto: Fix `CR' and `ci'. + Add `OK'. + * font/devutf8/NOTES: Updated. + + * src/roff/troff/uniglyph.cc (unicode_to_glyph_list): Fix `CR' and + `ci'. + Add `OK'. + * src/roff/troff/glyphuni.cc (glyph_to_unicode_list): Ditto. + + * tmac/dvi.tmac: Add `lh' and `rh'. + * tmac/Xps.tmac: Fix `lh' and `rh'. + * tmac/X.tmac: Add `OK'. + * tmac/lj4.tmac: Ditto. + +2002-11-24 Werner LEMBERG + + * font/devX*/S: Regenerated. + * font/devascii/R.proto, font/devcp1047/R.proto: Remove glyphs `lb', + `lc', `lf', `lk', `lt', `rb', `rc', `rf', `rk', and `rt'. + * font/devdvi/generate/texsy.map: Remove `or' glyph. + * font/devdvi/S: Regenerated. + * font/devhtml/R.proto, font/devutf8/R.proto: Add/fix glyphs + `parenlefttp', `parenleftex', `parenleftbt', `parenrighttp', + `parenrightex', `parenrightbt', `bracketlefttp', `bracketleftex', + `bracketleftbt', `bracketrighttp', `bracketrightex', + `bracketrightbt', `bracelefttp', `braceleftmid', `braceleftbt', + `braceex', `braceleftex', `bracerightex', `bracerighttp', + `bracerightmid', `bracerightbt', `lt', `lk', `lb', `rt', `rk', + `rb', and `bv'. + * src/roff/troff/glyphuni.cc, src/roff/troff/uniglyph.cc: Ditto. + * font/devutf8/NOTES: Updated. + * font/devlj4/generate/special.map: Add glyph `braceex'. + * font/devlj4/S: Regenerated. + + * tmac/tty-char.tmac: Add glyphs `lf', `rf', `lc', and `rc'. + +2002-11-14 Werner LEMBERG + + * src/roff/troff/uniglyph.cc (unicode_to_glyph_list): Add `va' + and `vA'. + Fix code for `an'. + * src/roff/troff/glyphuni.cc (glyph_to_unicode_list): Ditto. + + * doc/texinfo.tex: New version from texinfo 4.3. + * doc/groff.texinfo: Updated for texinfo 4.3. + Use @tie{} where appropriate. + * font/devdvi/generate/ec.map: Don't include `or' and `bv'. + * font/devdvi/generate/tc.map: Remove `rn'. + * font/devdvi/*TC, font/devdvi/*EC: Regenerated. + * font/devhtml/R.proto, font/devutf8/R.proto: Add `vA'. + Fix code for `an'. + * font/devX100/*, font/devX100-12/*, font/devX75/*, + font/devX75-12/*: Regenerated. + + * tmac/dvi.tmac: Add special fonts `SA' and `SB'. + Use .char (again) for `br', `ul', `rn', `or', and `ru'. + Improve definition of `an'. + * tmac/ps.tmac: Use .char (again) for `br', `ul', `rn', `or', and + `ru'. + * tmac/lj4.tmac: Use .char (again) for `br', `ul', `rn', and `ru'. + * tmac/X.tmac: Add definition for `or'. + * tmac/Xps.tmac: Undo change 2002-11-05. + * tmac/lbp.tmac: Add definitions for `br', `rn', `ul', and `ru'. + +2002-11-11 Werner LEMBERG + + * src/roff/troff/node.cc (troff_output_file::put_char): Always + call flush_tbuf. + +2002-11-10 Werner LEMBERG + + Added three new requests `schar', `fschar', and `rfschar'. `schar' + defines a glyph which is searched after the check for fonts declared + with `.special' (and before the check for all mounted special + fonts). `fschar' defines a glyph for a particular font which is + searched after the check for fonts declared with `.fspecial' (and + before the check for fonts declared with `.special'). `rfschar' + removes glyphs defined with `fschar'. + + * src/roff/troff/token.h (char_mode): New enum. + Declare do_define_character. + * src/roff/troff/charinfo.h (charinfo): Replace `fallback' with + `mode'. + (charinfo::is_fallback): Updated. + (charinfo::is_special): New method. + * src/roff/troff/input.cc (do_define_character): Add and use + optional second parameter used as a prefix for font-specific glyph + names. + (define_character, define_fallback_character): Updated. + (define_special_character): New function. + (init_input_requests): Add `schar'. + (charinfo::charinfo, charinfo::set_macro): Updated. + * src/roff/troff/node.cc: Include `stringclass.h'. + (make_glyph_node): Handle special glyphs defined with `.schar' and + `.fschar'. + (define_font_special_character, remove_font_special_character): New + functions. + (init_node_requests): Sorted. + Add `fschar' and `rfschar'. + * NEWS, man/groff_diff.man, man/groff.man, doc/groff.texinfo: + Document new requests. + + * font/devhtml/R.proto, font/devutf8/R.proto: Add `va'. + * tmac/dvi.tmac: Add `va' for CW and CWI (using `.fschar'). + +2002-11-08 Werner LEMBERG + + Added new font `SC' (cmtex10) to devdvi. + + * devdvi/generate/Makefile (FONTS): Add `SC'. + (SC): New rule. + * devdvi/generate/textex.map: New map file for cmtex. + * devdvi/SC: New. + * devdvi/Makefile.sub (DEVFILES): Updated. + * tmac/dvi.tmac: Add fspecial entries for SC. + Add `MI', `S' and `CW' to the `special' call. Otherwise, `SC' is + found before `S' since the font position of `SC' is lower due to the + gaps in DESC's `font' line. + * tmac/ec.tmac: Add a `special' call. + * NEWS: Updated. + + * font/devhtml/R.proto: Remove double entry for `ti'. + * tmac/tty.tmac: Add entries for `IJ', `ij', and `bq'. + * tmac/tty-char.tmac: Remove entry for `bq'. + * tmac/lbp.tmac: Add entries for `lq', `rq', `fo', `fc', and `em'. + * tmac/ec.tmac: Don't remove `aq' glyph. + * tmac/X.tmac: Fix entry for `em'. + Add entries for `fo' and `fc'. + * tmac/dvi.tmac: Add entries for `em', `en', `hy', `fo', and `fc'. + + * doc/groff.texinfo, man/groff.man, man/groff_diff.man: Fix + documentation of `special' and `fspecial' requests. + +2002-11-05 Werner LEMBERG + + * font/devascii/R.proto, font/devcp1047/R.proto, + font/devlatin1/R.proto: Remove entry for `.i'. + * font/devdvi/generate/textt.map: Add entry for `ad'. + * font/devdvi/generate/texr.map, font/devdvi/generate/texb.map, + font/devdvi/generate/texi.map: Add dummy glyph name `slash@for@l'. + We need this for getting kerning values to compose `/l' and `/L'. + * font/devdvi: Regenerated font definition files for CM fonts. + * font/devhtml/R.proto: Add entries for "'C", "'c", `IJ', and `ij'. + * font/devutf8/R.proto: Ditto. + Remove double entry for `ti'. + + * src/roff/troff/glyphuni.cc (glyph_to_unicode_list): Fix entries + for (groff) ligatures, `la', and `ra'. + Add "'C", "'c", `IJ', and `ij'. + Remove double entry for `ti'. + * src/roff/troff/uniglyph.cc (unicode_to_glyph_list): Remove all + double entries. + Add "'C", "'c", `IJ', and `ij'. + Fix entries for (groff) ligatures, `la', and `ra'. + + * tmac/ps.tmac (ps-achar): New macro. + Define "'c" and "'C". + * tmac/tty.tmac: Add entry for `.i'. + * tmac/X.tmac (X-achar): New macro. + Define "'c", "'C", and `:Y'. + Add entries for `IJ' and `ij'. + * tmac/Xps.tmac (Xps-achar): New macro. + Define "'c" and "'C". + Add entries for `IJ' and `ij'. + * tmac/lbp.tmac (lbp-achar): New macro. + Add fallback characters for all groff ligatures and many other + glyphs. + * tmac/dvi.tmac: Fix definitions of `_' and `ul'. + Add entries for `/l' and `/L'. + Define "'c" and "'C". + Add entries for `IJ' and `ij'. + +2002-11-02 Larry Kollar + + * PROBLEMS: Document how to solve Mac OS X compilation problems. + +2002-11-02 Werner LEMBERG + + Adding support for composite glyphs: \[xxx yyy ...] and the + `composite' request. + + * src/roff/troff/glyphuni.cc: New file for mapping groff glyph names + to Unicode-based glyph names. + * src/roff/troff/uniglyph.cc: New file for mapping Unicode-based + glyph names to groff glyph names. + * src/roff/troff/uniuni.cc: New file for canonically decomposing + Unicode-based glyph names. + * src/roff/troff/unicode.cc, src/roff/troff/unicode.h: New files + for handling Unicode glyph names. + * src/roff/troff/input.cc: Include unicode.h. + (composite_glyph_name): New function. + (token::next) <'['>: Handle Unicode glyph names and composite + glyphs. + (composite_dictionary): New dictionary for the `composite' request. + (composite_request): Implement `composite' request. + (init_input_requests): Add `composite'. + Alphabetically sorted. + * src/roff/troff/env.cc (tabs_save, tabs_restore): Removed (already + commented out). + (init_env_requests): Alphabetically sorted. + Removed `tas' and `tar' (already commented out). + * src/roff/troff/Makefile.sub: Updated. + +2002-10-31 Ruslan Ermilov + + * src/roff/nroff/nroff.man, src/roff/nroff/nroff.sh: Fix description + of options. + +2002-10-29 Werner LEMBERG + + Fix computation of .trunc register. Additionally, its value (and + the value of the .ne register) is now always set before entering the + trap. + + * src/roff/troff/div.cc (diversion::need): Set `truncated_space' and + `needed_space' before calling `space'. + (top_level_diversion::space): Remove special code for 'sp before the + first page. + Call `begin_page' with the discarded space as a parameter. + (top_level_diversion::begin_page): Add optional parameter to set + `truncated_space'. + * src/roff/troff/div.h: Updated. + + * doc/groff.texinfo: Improve documentation of .sp, \n[.trunc], and + \n[.ne]. + + * tmac/an-old.tmac (SH, SS, TP, IP, HP, TS): Undo change 2002-10-26. + (LP): Remove superfluous call to `br'. + * tmac/doc-common (doc-paragraph): Undo change 2002-10-26. + * tmac/doc.tmac (Bd, Bl, doc-set-vertical-and-indent): Ditto. + +2002-10-26 Werner LEMBERG + + * tmac/doc-ditroff: Remove useless switch/variable -rC. + (doc-setup-header): Don't set page register `%'. + * tmac/doc-nroff: Remove variable `C'. + (doc-setup-page-layout): Set doc-header-space to .5i unconditionally. + (doc-setup-header): Don't set page register `%'. + Don't call `bp'. + * tmac/doc-common (doc-header): Call `ns'. + (doc-paragraph): Protect .sp with .br so that it survives traps + possibly set by the user. + * tmac/doc.tmac (Bd, Bl, doc-set-vertical-and-indent): Ditto. + + * tmac/doc*: Replace ' with . for consistency if no effect. + +2002-10-26 Werner LEMBERG + + * tmac/an-old.tmac (SH, SS, TP, IP, HP, TS): Protect .sp with .br + so that it survives traps possibly set by the user. + + * src/roff/troff/node.cc: Fix the changes from 2002-10-23. + (troff_output_file::set_font): Call flush_tbuf if necessary. + (troff_output_file::fill_color, troff_output_file::glyph_color): Call + flush_tbuf and do_motion only if necessary. + (troff_output_file::start_special, + troff_output_file::put_char_width, troff_output_file::put_char, + troff_output_file::draw): Updated. + (word_space_node::tprint, space_node::tprint, hmotion_node::tprint, + vmotion_node::tprint): Undo change 2002-10-23. + +2002-10-25 Werner LEMBERG + + * tmac/www.tmac (DC): Fix case of overlapping images. + +2002-10-23 Werner LEMBERG + + * src/roff/troff/node.cc (troff_output_file::fill_color, + troff_output_file::glyph_color): Set current color before testing + color_flag. + (troff_output_file::put_char_width, troff_output_file::put_char, + troff_output_file::draw): Don't call flush_tbuf and/or do_motion + before glyph_color. + (troff_output_file::file_color, troff_output_file::glyph_color): + Call do_motion. + (word_space_node::tprint, space_node::tprint, hmotion_node::tprint, + vmotion_node::tprint): Move first, then call fill_color. + +2002-10-20 Werner LEMBERG + + * doc/groff.texinfo, man/groff_tmac.man: Document that it is not + possible to use multiple main macro packages. + +2002-10-19 Werner LEMBERG + + * src/devices/grops/ps.cc (cmyk_flag): New global variable. + (ps_printer::set_color): Set `cmyk_flag' for CMY and CMYK colors. + (ps_printer::~ps_printer): Emit `%%Extensions: CMYK' if `cmyk_flag' + is set. + * font/devps/prologue.ps (Fk, Ck): Enclose definitions with a + `where' construction since `cmyksetcolor' is a PS Level 2 operator. + +2002-10-16 Werner LEMBERG + + * NEWS, doc/webpage.ms: Updated. + +2002-10-14 Werner LEMBERG + + * src/roff/troff/node.cc (troff_output_file::put_char_width, + troff_output_file::put_char, troff_output_file::fill_color, + troff_output_file::glyph_color): Handle case where color pointer + is null. + +2002-10-13 Ruslan Ermilov + + Add the new -r option to grotty. It is similar to the -i option + except it tells grotty(1) to use the "reverse video" attribute to + render italic fonts. + + * src/devices/grotty/tty.cc (reverse_flag): New global variable. + (SGR_REVERSE, SGR_NO_REVERSE): New macros. + (tty_printer::make_underline, tty_printer::put_color, + tty_printer::end_page): Use it. + (main): Add -r switch. + (usage): Updated. + * src/devices/grotty/grotty.man: Document it. + +2002-10-11 Ruslan Ermilov + + * src/roff/troff/env.cc (hyphen_trie::read_patterns_file): Add + cast to `unsigned char' to properly read patterns with 8bit + characters. + +2002-10-08 Werner LEMBERG + + * REVISION: Increased to 2. + +Version 1.18.1 released +======================= + 2002-10-08 Werner LEMBERG * doc/webpage.ms, NEWS: Updated. @@ -394,7 +2119,7 @@ * src/roff/troff/node.cc (node::add_char): Call `freeze_space' for unbreakable space. -2002-08-08 Aaron Campbell +2002-08-08 Aaron Campbell * src/preproc/pic/object.cc (object_spec::make_move): Fix typo (&& -> &). @@ -681,7 +2406,7 @@ Version 1.18.0 released (init_input_requests): Updated. * src/roff/troff/request.h: Updated. -2002-07-08 Robert D. Goulding +2002-07-08 Robert D. Goulding * src/roff/grog/grog.sh: Fix typo. @@ -1971,7 +3696,7 @@ Version 1.18.0 released * NEWS, man/groff_char.man: Updated. -2002-02-21 Phil Lobbes +2002-02-21 Phil Lobbes * src/include/lib.h [HAVE_SNPRINTF]: Include stdarg.h. @@ -9403,7 +11128,7 @@ Mon Aug 10 11:17:53 1992 James Clark (jjc at jclark) * include/lib.h (illegal_input_char): Use table. * troff/input.cc (ESCAPE_RIGHT_PARENTHESIS): Renumber to 0206. * pic/lex.cc (ARG1): Renumber to 14. - * eqn/lex.cc (ARG1: Likewise. + * eqn/lex.cc (ARG1): Likewise. * troff/Makefile.sub (majorminor.cc): Handle 3 part versions (eg 1.05.90) correctly. diff --git a/contrib/groff/INSTALL b/contrib/groff/INSTALL index 0fb618e..c009b6d 100644 --- a/contrib/groff/INSTALL +++ b/contrib/groff/INSTALL @@ -6,7 +6,7 @@ This file contains information that supplements those instructions. MS-Windows, see the file arch/djgpp/README.) groff is written in C++, so you will need a C++ compiler. The C++ -source files use a suffix of `.cc', so your C++ compiler must be able +source files use a suffix of `.cpp', so your C++ compiler must be able to handle this. If you don't already have a C++ compiler, I suggest gcc 2.7.1 or later (gcc version 2 includes GNU C++ as well as GNU C). From gcc 2.5, it is no longer necessary to install libg++: the C++ @@ -44,7 +44,7 @@ subdirectory. To get a DVI, PDF, or HTML version of the groff texinfo manual, say `make groff.dvi', `make groff.pdf', or `make groff.html', respectively, in the `doc' subdirectory (after compiling the groff package). Note that you -need texinfo version 4.2 or newer as a prerequisite. +need texinfo version 4.3 or newer as a prerequisite. If you have problems, read the PROBLEMS file. If this doesn't help send a bug report using the form in the file BUG-REPORT. diff --git a/contrib/groff/MANIFEST b/contrib/groff/MANIFEST index b45c046..c0ce12e 100644 --- a/contrib/groff/MANIFEST +++ b/contrib/groff/MANIFEST @@ -1,10 +1,10 @@ MANIFEST -Last update: 21 Dec 2001 +Last update: 13 Apr 2003 This file is part of groff, the GNU roff type-setting system. -Copyright (C) 2001 Free Software Foundation, Inc. +Copyright (C) 2001, 2003 Free Software Foundation, Inc. written by Bernd Warken maintained by Werner Lemberg @@ -50,6 +50,8 @@ the groff source distribution. djgpp Data special for the 32-bit DOS compiler djgpp. ./contrib Part of groff, but maintained by other people. + eqn2graph Convert equations created with EQN into different + graphical formats. groffer A wrapper to conveniently view roff files. mm The groff mm macro package. mom The groff mom macro package. @@ -107,8 +109,6 @@ the groff source distribution. nroff Emulate classical nroff text formatter. troff Main roff formatter program. -./src/xditview A groff (pre)viewer for the X Window System. - ./src/utils Utility programs around groff. addftinfo Add information to old troff font files for use with groff. afmtodit Create font description files for the PostScript device. @@ -116,9 +116,11 @@ the groff source distribution. indxbib Make inverted index for bibliographic databases. lkbib Search bibliographic databases. lookbib Interactively search bibliographic databases. - pfbtops Translate a PostScript font in .pfb format to ASCII. + pfbtops Translate a PostScript font in PFB format to PFA. tfmtodit Create font description files for TeX DVI device. +./src/xditview A groff (pre)viewer for the X Window System. + ./tmac Macro files. @@ -141,12 +143,13 @@ The groff documentation is scattered upon several places. 4) The roff parser -The parsing of the roff language is done by troff. The input is -transformed into "nodes" by `src/roff/troff/node.cc'. From these, the -intermediate output is generated. +The parsing of the roff language is done by troff. The input is converted +to tokens in `src/roff/troff/input.cpp' and transformed into `nodes' by +`src/roff/troff/env.cpp' and `src/roff/troff/node.cpp'. From these, the +intermediate output is generated (also in `node.cpp'). 5) Postprocessing The parser for the intermediate output and the postprocessing is in -`src/libs/libdriver/input.cc'. This is used by all postprocessors. +`src/libs/libdriver/input.cpp'. This is used by all postprocessors. diff --git a/contrib/groff/Makefile.ccpg b/contrib/groff/Makefile.ccpg index b89fab1..ec46a94 100644 --- a/contrib/groff/Makefile.ccpg +++ b/contrib/groff/Makefile.ccpg @@ -9,7 +9,7 @@ MAKEFILEPARTS=\ all: $(PROG) $(MANPAGES) $(PROG): $(OBJS) $(XLIBS) - $(LINK.cc) -o $@ $(OBJS) $(XLIBS) $(LIBS) $(MLIB) + $(LINK.cpp) -o $@ $(OBJS) $(XLIBS) $(LIBS) $(MLIB) install_bin: install_prog install_prog: $(PROG) @@ -30,4 +30,4 @@ pure: $(PROG).pure $(PROG).pure: $(OBJS) $(XLIBS) $(PURIFY) $(PURIFYCCFLAGS) \ - $(LINK.cc) -o $@ $(OBJS) $(XLIBS) $(LIBS) $(MLIB) + $(LINK.cpp) -o $@ $(OBJS) $(XLIBS) $(LIBS) $(MLIB) diff --git a/contrib/groff/Makefile.comm b/contrib/groff/Makefile.comm index 6d246c5..fd27b8e 100644 --- a/contrib/groff/Makefile.comm +++ b/contrib/groff/Makefile.comm @@ -23,14 +23,14 @@ SHELL=/bin/sh INCLUDES=-I. -I$(srcdir) \ -I$(top_builddir)/src/include -I$(top_srcdir)/src/include ALL_CCFLAGS=$(INCLUDES) $(CCDEFINES) $(CCFLAGS) $(CPPFLAGS) -COMPILE.cc=$(CCC) $(ALL_CCFLAGS) -c +COMPILE.cpp=$(CCC) $(ALL_CCFLAGS) -c ALL_CFLAGS=$(INCLUDES) $(CDEFINES) $(CFLAGS) $(CPPFLAGS) COMPILE.c=$(CC) $(ALL_CFLAGS) -c -LINK.cc=$(CCC) $(CCFLAGS) $(LDFLAGS) +LINK.cpp=$(CCC) $(CCFLAGS) $(LDFLAGS) LINK.c=$(CC) $(CFLAGS) $(LDFLAGS) -LIBGROFF=$(top_builddir)/src/libs/libgroff/libgroff.a -LIBBIB=$(top_builddir)/src/libs/libbib/libbib.a -LIBDRIVER=$(top_builddir)/src/libs/libdriver/libdriver.a +LIBGROFF=$(top_builddir)/src/libs/libgroff/libgroff.$(LIBEXT) +LIBBIB=$(top_builddir)/src/libs/libbib/libbib.$(LIBEXT) +LIBDRIVER=$(top_builddir)/src/libs/libdriver/libdriver.$(LIBEXT) MLIB= XLIBS= YTABH= @@ -96,21 +96,21 @@ extraclean: distclean -rm -f \#* *~ =* core junk grot old temp tmp tem .SUFFIXES: -.SUFFIXES: .o .obj .cc .c .y .man .n +.SUFFIXES: .o .obj .cpp .c .y .man .n -.cc.o: - $(COMPILE.cc) $< +.cpp.o: + $(COMPILE.cpp) $< .c.o: $(COMPILE.c) $< -.cc.obj: - $(COMPILE.cc) $< +.cpp.obj: + $(COMPILE.cpp) $< .c.obj: $(COMPILE.c) $< -.y.cc: +.y.cpp: if test -n "$(YTABH)"; then \ $(YACC) $(YACCFLAGS) -d $<; \ else \ @@ -122,7 +122,7 @@ extraclean: distclean if test -n "$(YTABH)"; then mv y_tab.h $(YTABH); fi # The next rule is needed for make of Solaris 2.5.1 to override its -# built-in .y.o rule (which takes precedence over the .y.cc rule above). +# built-in .y.o rule (which takes precedence over the .y.cpp rule above). .y.o: if test -n "$(YTABH)"; then \ $(YACC) $(YACCFLAGS) -d $<; \ @@ -133,7 +133,7 @@ extraclean: distclean -test -f y.tab.c && mv y.tab.c y_tab.c mv y_tab.c $(YTABC) if test -n "$(YTABH)"; then mv y_tab.h $(YTABH); fi - $(COMPILE.cc) $(YTABC) + $(COMPILE.cpp) $(YTABC) .man.n: @echo Making $@ from $< @@ -246,10 +246,18 @@ install_dev: $(INSTALL_DATA) $(srcdir)/$$f $(fontsubdir)/$$f; \ fi; \ done + -for f in $(DEVSCRIPTS); do \ + rm -f $(fontsubdir)/$$f; \ + if test -f $$f; then \ + $(INSTALL_SCRIPT) $$f $(fontsubdir)/$$f; \ + else \ + $(INSTALL_SCRIPT) $(srcdir)/$$f $(fontsubdir)/$$f; \ + fi; \ + done .PHONY: uninstall_dev uninstall_dev: - -for f in $(DEVFILES); do rm -f $(fontsubdir)/$$f; done + -for f in $(DEVFILES) $(DEVSCRIPTS); do rm -f $(fontsubdir)/$$f; done -if test -d $(fontsubdir)/generate; then \ rmdir $(fontsubdir)/generate; \ fi @@ -261,8 +269,13 @@ depend_src: depend.temp depend.temp: FORCE > depend.temp; + if test -f "$(srcdir)/$(YTABC)"; then \ + ytabc="$(srcdir)/$(YTABC)"; \ + else \ + ytabc="$(YTABC)"; \ + fi; \ test -z "$(CCSRCS)$(YTABC)" \ - || $(CCC) $(ALL_CCFLAGS) -MM $(CCSRCS) $(YTABC) >>depend.temp + || $(CCC) $(ALL_CCFLAGS) -MM $(CCSRCS) $$ytabc >>depend.temp test -z "$(CSRCS)" \ || $(CC) $(ALL_CFLAGS) -MM $(CSRCS) >>depend.temp if test -n "$(YTABH)"; then \ diff --git a/contrib/groff/Makefile.dev b/contrib/groff/Makefile.dev index ae9a672..6c70fff 100644 --- a/contrib/groff/Makefile.dev +++ b/contrib/groff/Makefile.dev @@ -1,4 +1,4 @@ -all: $(DEVFILES) +all: $(DEVFILES) $(DEVSCRIPTS) install_data: install_dev uninstall_sub: uninstall_dev -install_dev: $(DEVFILES) +install_dev: $(DEVFILES) $(DEVSCRIPTS) diff --git a/contrib/groff/Makefile.in b/contrib/groff/Makefile.in index 411d8b9..765eee5 100644 --- a/contrib/groff/Makefile.in +++ b/contrib/groff/Makefile.in @@ -1,4 +1,4 @@ -# Copyright (C) 1989-2000, 2001, 2002 Free Software Foundation, Inc. +# Copyright (C) 1989-2000, 2001, 2002, 2003 Free Software Foundation, Inc. # Written by James Clark (jjc@jclark.com) # # This file is part of groff. @@ -21,6 +21,7 @@ srcdir=@srcdir@ top_srcdir=@top_srcdir@ VPATH=@srcdir@ top_builddir=@groff_top_builddir@ +SEP=@PATH_SEPARATOR@ version=`cat $(top_srcdir)/VERSION` # No additional number if revision is zero. @@ -120,7 +121,7 @@ localfontdir=$(dataprogramdir)/site-font legacyfontdir=/usr/lib/font # `fontpath' says where to look for dev*/*. -fontpath=$(localfontdir):$(fontdir):$(legacyfontdir) +fontpath=$(localfontdir)$(SEP)$(fontdir)$(SEP)$(legacyfontdir) # `tmacdir' says where to install macros. tmacdir=$(datasubdir)/tmac @@ -136,11 +137,16 @@ localtmacdir=$(dataprogramdir)/site-tmac # directory will be always added. # `troffrc' and `troffrc-end' (and `eqnrc') are searched neither in the # current nor in the home directory. -tmacpath=$(systemtmacdir):$(localtmacdir):$(tmacdir) +tmacpath=$(systemtmacdir)$(SEP)$(localtmacdir)$(SEP)$(tmacdir) # `sys_tmac_prefix' is prefix (if any) for system macro packages. sys_tmac_prefix=@sys_tmac_prefix@ +# `pnmtops_nosetpage' is the command to be run to generate an eps +# file. Some versions of pnmtops provide the -nosetpage option. +# We detect this and use it if present. +pnmtops_nosetpage=@pnmtops_nosetpage@ + # `tmac_wrap' is list of system macro packages that should be made # available to groff by creating a corresponding macro package # in the groff macro directory that references the system macro @@ -214,7 +220,7 @@ make_install_html=@make_install_html@ # -DHAVE_CC_LIMITS_H if you have a C++ # -DHAVE_MATH_H if you have # -DHAVE_CC_OSFCN_H if you have a C++ -# -DHAVE_STDINT_H if you have +# -DHAVE_CC_STDINT_H if you have a C++ # -DHAVE_STDLIB_H if you have # -DHAVE_STRING_H if you have # -DHAVE_STRINGS_H if you have @@ -230,6 +236,7 @@ make_install_html=@make_install_html@ # -DHAVE_MMAP if you have mmap() # -DHAVE_PUTENV if you have putenv() # -DHAVE_RENAME if you have rename() +# -DHAVE_SETLOCALE if you have setlocale() # -DHAVE_SNPRINTF if you have snprintf() # -DHAVE_STRCASECMP if you have strcasecmp() # -DHAVE_STRNCASECMP if you have strncasecmp() @@ -244,6 +251,9 @@ make_install_html=@make_install_html@ # -DNEED_DECLARATION_PCLOSE if your C++ doesn't declare pclose() # -DNEED_DECLARATION_POPEN if your C++ doesn't declare popen() # -DNEED_DECLARATION_PUTENV if your C++ doesn't declare putenv() +# -DNEED_DECLARATION_RAND if your C++ doesn't declare rand() +# -DNEED_DECLARATION_SNPRINTF if your C++ doesn't declare snprintf() +# -DNEED_DECLARATION_SRAND if your C++ doesn't declare srand() # -DNEED_DECLARATION_STRCASECMP if your C++ doesn't declare # strcasecmp() # -DNEED_DECLARATION_STRNCASECMP @@ -265,12 +275,13 @@ DEFINES=@DEFS@ # Include # -# {fmod,getcwd,mkstemp,putenv,snprintf,strerror,strtol}.$(OBJEXT) +# {fmod,getcwd,mkstemp,putenv,snprintf,strcasecmp, +# strerror,strncasecmp,strtol}.$(OBJEXT) # # in LIBOBJS if your C library is missing the corresponding function. LIBOBJS=@LIBOBJS@ -# `CCC' is the compiler for C++ (.cc) files. +# `CCC' is the compiler for C++ (.cpp) files. CCC=@CXX@ CC=@CC@ # CCDEFINES are definitions for C++ compilations. @@ -286,6 +297,8 @@ YACCFLAGS=-v EXEEXT=@EXEEXT@ OBJEXT=@OBJEXT@ +# a simple heuristic assumption +LIBEXT=`case $(OBJEXT) in obj) echo lib;; *) echo a;; esac` LIBS=@LIBS@ LIBM=@LIBM@ RANLIB=@RANLIB@ @@ -317,85 +330,88 @@ PURIFYCCFLAGS= # copy of $(MDEFINES) when making individual directories; this could # cause the argument list to become too long on some systems. MDEFINES= \ - "MAKEOVERRIDES=$(MAKEOVERRIDES)" \ - "PAGE=$(PAGE)" \ + "AR=$(AR)" \ "BROKEN_SPOOLER_FLAGS=$(BROKEN_SPOOLER_FLAGS)" \ + "CC=$(CC)" \ + "CCC=$(CCC)" \ + "CCDEFINES=$(CCDEFINES)" \ + "CCFLAGS=$(CCFLAGS)" \ + "CDEFINES=$(CDEFINES)" \ + "CFLAGS=$(CFLAGS)" \ "DEVICE=$(DEVICE)" \ - "TTYDEVDIRS=$(TTYDEVDIRS)" \ + "DVIPRINT=$(DVIPRINT)" \ + "ETAGS=$(ETAGS)" \ + "ETAGSCCFLAG=$(ETAGSCCFLAG)" \ + "ETAGSFLAGS=$(ETAGSFLAGS)" \ + "EXEEXT=$(EXEEXT)" \ + "INSTALL_DATA=$(INSTALL_DATA)" \ + "INSTALL_INFO=$(INSTALL_INFO)" \ + "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \ + "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \ + "LDFLAGS=$(LDFLAGS)" \ + "LIBEXT=$(LIBEXT)" \ + "LIBM=$(LIBM)" \ + "LIBOBJS=$(LIBOBJS)" \ + "LIBS=$(LIBS)" \ + "MAKEOVERRIDES=$(MAKEOVERRIDES)" \ + "OBJEXT=$(OBJEXT)" \ "OTHERDEVDIRS=$(OTHERDEVDIRS)" \ + "PAGE=$(PAGE)" \ + "PERLPATH=$(PERLPATH)" \ "PSPRINT=$(PSPRINT)" \ - "DVIPRINT=$(DVIPRINT)" \ - "version=$(version)" \ - "revision=$(revision)" \ - "top_srcdir=$(top_srcdir)" \ - "top_builddir=$(top_builddir)" \ - "prefix=$(prefix)" \ - "exec_prefix=$(exec_prefix)" \ - "g=$(g)" \ + "PURIFY=$(PURIFY)" \ + "PURIFYCCFLAGS=$(PURIFYCCFLAGS)" \ + "RANLIB=$(RANLIB)" \ + "SEP=$(SEP)" \ + "SH_SCRIPT_SED_CMD=$(SH_SCRIPT_SED_CMD)" \ + "TTYDEVDIRS=$(TTYDEVDIRS)" \ + "YACC=$(YACC)" \ + "YACCFLAGS=$(YACCFLAGS)" \ + "bindir=$(bindir)" \ + "common_words_file=$(common_words_file)" \ "datadir=$(datadir)" \ "dataprogramdir=$(dataprogramdir)" \ "datasubdir=$(datasubdir)" \ - "infodir=$(infodir)" \ "docdir=$(docdir)" \ "exampledir=$(exampledir)" \ + "exec_prefix=$(exec_prefix)" \ + "fontdir=$(fontdir)" \ + "fontpath=$(fontpath)" \ + "g=$(g)" \ "htmldocdir=$(htmldocdir)" \ + "indexdir=$(indexdir)" \ + "indexext=$(indexext)" \ + "indexname=$(indexname)" \ + "infodir=$(infodir)" \ + "legacyfontdir=$(legacyfontdir)" \ "libdir=$(libdir)" \ "libprogramdir=$(libprogramdir)" \ - "bindir=$(bindir)" \ - "fontdir=$(fontdir)" \ "localfontdir=$(localfontdir)" \ - "legacyfontdir=$(legacyfontdir)" \ - "fontpath=$(fontpath)" \ - "tmacdir=$(tmacdir)" \ - "systemtmacdir=$(systemtmacdir)" \ "localtmacdir=$(localtmacdir)" \ - "tmacpath=$(tmacpath)" \ - "indexext=$(indexext)" \ - "indexdir=$(indexdir)" \ - "indexname=$(indexname)" \ - "common_words_file=$(common_words_file)" \ - "manroot=$(manroot)" \ - "man1ext=$(man1ext)" \ + "make_html=$(make_html)" \ + "make_install_html=$(make_install_html)" \ "man1dir=$(man1dir)" \ - "man5ext=$(man5ext)" \ + "man1ext=$(man1ext)" \ "man5dir=$(man5dir)" \ - "man7ext=$(man7ext)" \ + "man5ext=$(man5ext)" \ "man7dir=$(man7dir)" \ - "make_html=$(make_html)" \ - "make_install_html=$(make_install_html)" \ + "man7ext=$(man7ext)" \ + "manroot=$(manroot)" \ "mkinstalldirs=$(mkinstalldirs)" \ - "tmac_wrap=$(tmac_wrap)" \ + "prefix=$(prefix)" \ + "revision=$(revision)" \ "sys_tmac_prefix=$(sys_tmac_prefix)" \ + "pnmtops_nosetpage=$(pnmtops_nosetpage)" \ + "systemtmacdir=$(systemtmacdir)" \ "tmac_an_prefix=$(tmac_an_prefix)" \ - "tmac_s_prefix=$(tmac_s_prefix)" \ "tmac_m_prefix=$(tmac_m_prefix)" \ - "EXEEXT=$(EXEEXT)" \ - "OBJEXT=$(OBJEXT)" \ - "CCC=$(CCC)" \ - "CC=$(CC)" \ - "CCDEFINES=$(CCDEFINES)" \ - "CDEFINES=$(CDEFINES)" \ - "CCFLAGS=$(CCFLAGS)" \ - "CFLAGS=$(CFLAGS)" \ - "LDFLAGS=$(LDFLAGS)" \ - "YACC=$(YACC)" \ - "YACCFLAGS=$(YACCFLAGS)" \ - "LIBM=$(LIBM)" \ - "LIBS=$(LIBS)" \ - "LIBOBJS=$(LIBOBJS)" \ - "RANLIB=$(RANLIB)" \ - "AR=$(AR)" \ - "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \ - "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \ - "INSTALL_DATA=$(INSTALL_DATA)" \ - "INSTALL_INFO=$(INSTALL_INFO)" \ - "ETAGS=$(ETAGS)" \ - "ETAGSFLAGS=$(ETAGSFLAGS)" \ - "ETAGSCCFLAG=$(ETAGSCCFLAG)" \ - "PERLPATH=$(PERLPATH)" \ - "SH_SCRIPT_SED_CMD=$(SH_SCRIPT_SED_CMD)" \ - "PURIFY=$(PURIFY)" \ - "PURIFYCCFLAGS=$(PURIFYCCFLAGS)" + "tmac_s_prefix=$(tmac_s_prefix)" \ + "tmac_wrap=$(tmac_wrap)" \ + "tmacdir=$(tmacdir)" \ + "tmacpath=$(tmacpath)" \ + "top_builddir=$(top_builddir)" \ + "top_srcdir=$(top_srcdir)" \ + "version=$(version)" SHELL=/bin/sh INCDIRS=src/include diff --git a/contrib/groff/Makefile.lib b/contrib/groff/Makefile.lib index 8861360..62a8222 100644 --- a/contrib/groff/Makefile.lib +++ b/contrib/groff/Makefile.lib @@ -1,4 +1,4 @@ -LIBCLEAN=lib$(LIB).a +LIBCLEAN=lib$(LIB).$(LIBEXT) MAKEFILEPARTS=\ $(top_srcdir)/Makefile.comm \ $(top_builddir)/Makefile.cfg \ @@ -6,9 +6,9 @@ MAKEFILEPARTS=\ $(top_srcdir)/Makefile.lib \ Makefile.dep -all: lib$(LIB).a +all: lib$(LIB).$(LIBEXT) -lib$(LIB).a: $(OBJS) +lib$(LIB).$(LIBEXT): $(OBJS) $(AR) r $@ $? $(RANLIB) $@ diff --git a/contrib/groff/Makefile.sub b/contrib/groff/Makefile.sub index 8dc3c71..689fd63 100644 --- a/contrib/groff/Makefile.sub +++ b/contrib/groff/Makefile.sub @@ -5,6 +5,7 @@ DISTCLEANFILES=\ stamp-h \ Makefile \ src/xditview/Imakefile \ + $(srcdir)/src/xditview/gxditview._man \ src/include/config.h CLEANADD=Makefile.cfg conftest* diff --git a/contrib/groff/NEWS b/contrib/groff/NEWS index f93d10c..d99f3a3 100644 --- a/contrib/groff/NEWS +++ b/contrib/groff/NEWS @@ -1,6 +1,227 @@ This file describes recent user-visible changes in groff. Bug fixes are not described. There are more details in the man and info pages. +VERSION 1.19 +============ + +Troff +----- + +o Input encoding files for latin-9 (a.k.a. latin-0 and ISO 8859-15) and + latin-2 (ISO 8859-2) have been added. Example use: + + groff -Tdvi -mlatin9 my_file > my_file.dvi + + You still need proper fonts with the necessary glyphs. Out of the box, + the groff package supports latin-9 only for -Tps, -Tdvi, and -Tutf8, + and latin-2 only for -Tdvi and -Tutf8. + +o Composite glyphs are now supported. To do this, a subset of the Adobe + Glyph List (AGL) Algorithm as described in + + http://partners.adobe.com/asn/developer/typeforum/unicodegn.html + + is used to construct glyph names based on Unicode character codes. The + existing groff glyph names are frozen; no glyph names which can't be + constructed algorithmically will be added in the future. + + The \[...] escape sequence has been extended to specify multiple glyph + components. Example: + + \[A ho] + + this accesses a glyph with the name `u0041_0328'. + + Some groff glyphs which are useful as composites map to `wrong' Unicode + code points. For example, `ho' maps to U+02DB which is a spacing + ogonek, whereas a non-spacing ogonek U+0328 is needed for composite + glyphs. The new request + + .composite from to + + will change the mapping while a composite glyph name is constructed. + To make \[A ho] yield the expected result, + + .composite ho u0328 + + is needed. [The new file `composite.tmac' loaded at start-up already + contains proper calls to `.composite'.] + + Please refer to the info pages of groff and to the groff_char man page + for more details. + +o A new request `fschar' has been added to define font-specific fallback + characters. They are searched after the list of fonts declared with the + `fspecial' request but before the list of fonts declared with `special'. + +o Fallback characters defined with `fschar' can be removed with the + new `rfschar' request. + +o A new request `schar' has been added to define global fallback + characters. They are searched after the list of fonts declared with the + `special' request but before the already mounted special fonts. + +o In groff versions 1.18 and 1.18.1, \D'f ...' didn't move the current + point horizontally. Despite of being silly, this change has been + reverted for backwards compatibility. Consequently, the intermediate + output command `Df' also moves the position horizontally again. + + \D'f ...' is deprecated since it depends on the horizontal resolution of + the output device (given with the `hor' parameter in the DESC file). + Use the new \D'Fg ...' escape instead. + +o For orthogonality, new \D subcommands to change the fill color are + available: + + \D'Fr ...' (rgb) + \D'Fc ...' (cmy) + \D'Fg ...' (gray) + \D'Fk ...' (cmyk) + \D'Fd' (default color) + + The arguments are the same as with the `defcolor' request. The current + position is *not* changed. + +o The values set with \H and \S are now available in number registers + \n[.height] and \n[.slant], respectively. + +o The `.pe' number register isn't new but hasn't been documented before. + It is set to 1 during a page ejection caused by the `bp' request. + +o The new glyph symbol `tno' is a textual variant of `no'. + +o The new glyph symbol `+e' represents U+03F5, GREEK LUNATE EPSILON SYMBOL. + (Well, it is not really new since it has been previously supported by + grolj4.) The mapping for both the dvi and lj4 symbol font has been + changed accordingly so that Greek small letter epsilon, `*e', has the + same glyph shape as with other devices. + +Grops +----- + +o The font `freeeuro.pfa' has been added to provide various default glyph + shapes for `eu' and `Eu'. + +o It is now possible to access all glyphs in a Type 1 font, not only 256 + (provided the font file created by afmtodit has proper entries). grops + constructs additional encoding vectors on the fly if necessary. + +o The paper size is now emitted via the %%DocumentMedia and PageSize + mechanisms so that it is no longer required to tell `gv' or `ps2pdf' + about the paper size. The `broken' flag value 16 omits this feature + (the used PostScript command `setpagedevice' is a LanguageLevel 2 + extension). Patch by Egil Kvaleberg . + +o Non-slanted PostScript metrics have been changed again; they no longer + contain negative left italic correction values. This assures correct + spacing with eqn. + +Grodvi +------ + +o The font cmtex10 has been added as the special font `SC' to the DVI fonts. + It is used as a font-specific special font for CW and CWI. + +o New options -l and -p to set landscape orientation and the paper size. + grodvi now emits a `papersize' special which is understood by DVI drivers + like dvips. + + Consequently, the DESC file should contain a `papersize' keyword. + +o The glyph shapes for \[*f] and \[*e] have been exchanged with \[+f] and + \[+e], respectively, to be in sync with all other devices. + +o Glyphs \[HE] and \[DI] have been replaced with \[u2662] and \[u2661], + respectively, since the former two glyphs have a black (filled) shape + which grodvi doesn't provide by default (it never has actually). + +Grolj4 +------ + +o The glyphs \[*e] and \[+e] have been exchanged to be in sync with + all other devices. + +o The glyph \[~=] is now called \[|=]. Similar to other devices, \[~=] + is now another name for glyph \[~~]. + +Grotty +------ + +o New option `-r'. It is similar to the -i option except it tells grotty to + use the `reverse video' attribute to render italic fonts. + +Pic +--- + +o New command `figname' to set the name of a picture's output box in TeX + mode. + +Refer +----- + +o The environment variable `REFER' to override the name of the default + database isn't new but hasn't been documented before. + +Soelim +------ + +o New option `-r' to avoid emission of `.lf' lines. + +o New option `-t' to emit TeX comment lines (giving current file and the + line number) instead of `.lf' lines. + +Afmtodit +-------- + +o Unencoded glyphs in an AFM file are output also (since grops can now emit + multiple encoding vectors for a single font). + +o New option `-m' to prevent negative left italic correction values. + +o The mapping and encoding file together with file `DESC' are now searched + in the default font directory also. Please refer to the man page of + afmtodit for more details. + +Macro Packages +-------------- + +o Larry Kollar and others made the man macros more + customizable. + + . New command line options -rFT, -rIN, and -rSN to set the vertical + location of the footer line, the body text indentation, and the + sub-subheading indentation. + + . New command line option -rHY (similar to the ms macros) to control + hyphenation. + + . New macros `.PT' and `.BT' to print the header and footer strings. + They can be replaced with a customized version in `man.local'. + + . The string `HF' now holds the typeface to print headings and + subheadings. + + . Similar to the ms macros, the LT register now defaults to LL if not + explicitly specified on the command line. + +o troff's start-up file `troffrc' now includes `papersize.tmac' to set + the paper size with the command line option `-dpaper='. + + Possible values for `' are the same as the predefined `papersize' + values in the DESC file (only lowercase; see the groff_font man page) + except a7-d7. An appended `l' (ell) character denotes landscape + orientation. Examples: `a4', `c3l', `letterl'. + + Most output drivers need additional command line switches `-p' and + `-l' to override the default paper length and orientation as set in + the driver specific DESC file. + + For example, use the following for PS output on A4 paper in landscape + orientation: + + groff -Tps -dpaper=a4l -P-pa4 -P-l -ms foo.ms > foo.ps + + VERSION 1.18.1 ============== @@ -8,11 +229,11 @@ Troff ----- o The non-slanted PostScript font definition files have been regenerated to - include left and right italic correction values. Applying those to a glyph - (this is, prepending the glyph with `\,' and appending `\/' to the glyph) - sets the glyph width to the real value given by the horizontal bounding - box values. Without those escapes, the advance width for the particular - glyph is used (which can differ considerably). + include left and right italic correction values. Applying those to a + glyph (this is, prepending the glyph with `\,' and appending `\/' to the + glyph) sets the glyph width to the real value given by the horizontal + bounding box values. Without those escapes, the advance width for the + particular glyph is used (which can differ considerably). Most users will neither need this feature nor notice a difference in existing documents (provided \, and \/ is used as advertised, namely for diff --git a/contrib/groff/PROBLEMS b/contrib/groff/PROBLEMS index e3e6a7b..f679c3a 100644 --- a/contrib/groff/PROBLEMS +++ b/contrib/groff/PROBLEMS @@ -38,10 +38,10 @@ or, if you want to be portable to older troff versions, as follows: * groff can't handle my troff document. It works fine with AT&T troff. -Read the section on incompatibilities in gtroff(1). Try using the -C -option. Alternatively there's the sed script `tmac/fixmacros.sed' -which will attempt to edit a file of macros so that it can be used -with groff without the -C flag. +Read the section on incompatibilities in groff_diff(7). Try using +the -C option. Alternatively there's the sed script +`tmac/fixmacros.sed' which will attempt to edit a file of macros so +that it can be used with groff without the -C flag. ---------------------------------------------------------------------- @@ -69,7 +69,7 @@ slow computers.) * Groff doesn't use the font names I'm used to. -Use the `ftr' request. See (g)troff(1). +Use the `ftr' request. See groff_diff(7). ---------------------------------------------------------------------- @@ -119,18 +119,8 @@ comments, you can do it like this: There seem to be many different styles of page header and footer produced by different versions of the -man macros. You will need to -modify tmac/an-old.tmac to suit your personal taste. For example, if -you want the center of the page header to say - - System Programmer's Manual - -you will need to change the line - - .el .ds an-extra3 \"System Programmer's Manual - -to - - .el .ds an-extra3 System Programmer's Manual +put modified macros from tmac/an-old.tmac into man.local. More +information is available in groff_man(7). ---------------------------------------------------------------------- @@ -335,18 +325,26 @@ are available in the devps directory. * I've configured groff for A4 paper, but gtroff still seems to think that the length of a page (as returned by `\n(.p') is 11 inches. -This is intentional. The PAGE option is used only by grops. For -compatibility with ditroff, the default page length in gtroff is -always 11 inches. The page length can be changed with the `pl' -request. +This is intentional. The PAGE option during configuration is used +only by grops. For compatibility with ditroff, the default page +length in gtroff is always 11 inches. The page length can be changed +with the `pl' request. + +A convenient way to set paper dimensions is to use the -dpaper option +of groff, together with proper -P options for the postprocessor +(overriding the default). For example, use the following for PS +output on A4 paper in landscape orientation: + + groff -Tps -dpaper=a4l -P-pa4 -P-l -ms foo.ms > foo.ps + +See groff_tmac(5) for more information. ---------------------------------------------------------------------- -* When I print the output groff -Tps, the output is always shifted up - by about 0.7 inches; I'm using 8.5x11 inch paper. +* When I print the output of groff -Tps, the output is always shifted + up by about 0.7 inches; I'm using 8.5x11 inch paper. -Make sure that PAGE is defined to be `letter' in the top-level -Makefile. +Make sure that the paper size is `letter'. See groff_tmac(5). ---------------------------------------------------------------------- @@ -421,12 +419,14 @@ You have at least 3 options: * Groff seems to generate level 3 Postscript, but my printer is only a level 1 or 2 PostScript printer. -In fact groff generates only level 1 PostScript. The `%!PS-Adobe-3.0' -comment at the beginning of PostScript output generated by groff -indicates that the file conforms to version 3.0 of the Adobe Document -Structuring Conventions. The output generated by groff should be -printable on any PostScript printer. Problems with groff output's not -printing are most often caused by the spooling system. +In fact groff generates only level 2 PostScript (or rather level 1 +with some extensions; see grops(1) for more information how to disable +them). The `%!PS-Adobe-3.0' comment at the beginning of PostScript +output generated by groff indicates that the file conforms to +version 3.0 of the Adobe Document Structuring Conventions. The output +generated by groff should be printable on any PostScript printer. +Problems with groff output's not printing are most often caused by the +spooling system. @@ -613,8 +613,12 @@ Compilation Problems y.tab.c: In function `int yyparse()': y.tab.c: `size_t' undeclared in namespace `std' -This is a bug in bison 1.32. Don't use this version. 1.28 or 1.33 works -fine. Alternatively, use yacc or byacc. +* bison reports conflicts (either on stderr or in the `pic.output' + file) while processing `pic.y', and the produced pic binary doesn't + work at all. + +You need bison version 1.875b or greater. Alternatively, use yacc or +byacc. ---------------------------------------------------------------------- @@ -783,3 +787,9 @@ patch is available. Use GCC 2.95.2 or later instead. Make sure -DCFRONT_ANSI_BUG is included in DEFINES in the top-level Makefile. If that doesn't solve the problem, define INT_MIN as -INT_MAX in libgroff/lib.h. + +---------------------------------------------------------------------- + +* When compiling on MacOS X, groff compiles but does not run well. + +Use ./configure CXX=g++2 then make as usual. diff --git a/contrib/groff/README.CVS b/contrib/groff/README.CVS new file mode 100644 index 0000000..ca284dc --- /dev/null +++ b/contrib/groff/README.CVS @@ -0,0 +1,6 @@ +You need the following tools to build groff directly from CVS: + + the netpbm package + texinfo >= 4.3 + bison >= 1.875b or byacc + ghostscript diff --git a/contrib/groff/REVISION b/contrib/groff/REVISION index d00491f..573541a 100644 --- a/contrib/groff/REVISION +++ b/contrib/groff/REVISION @@ -1 +1 @@ -1 +0 diff --git a/contrib/groff/VERSION b/contrib/groff/VERSION index adc97d8..bc44934 100644 --- a/contrib/groff/VERSION +++ b/contrib/groff/VERSION @@ -1 +1 @@ -1.18 +1.19 diff --git a/contrib/groff/aclocal.m4 b/contrib/groff/aclocal.m4 index c3e6b64..4b1b68e 100644 --- a/contrib/groff/aclocal.m4 +++ b/contrib/groff/aclocal.m4 @@ -63,25 +63,82 @@ dnl AC_DEFUN(GROFF_HTML_PROGRAMS, [make_html=html make_install_html=install_html +missing= AC_CHECK_PROG(pnmcut, pnmcut, found, missing) +if test $pnmcut = missing; then + missing="$missing pnmcut" +fi AC_CHECK_PROG(pnmcrop, pnmcrop, found, missing) +if test $pnmcrop = missing; then + missing="$missing pnmcrop" +fi AC_CHECK_PROG(pnmtopng, pnmtopng, found, missing) +if test $pnmtopng = missing; then + missing="$missing pnmtopng" +fi AC_CHECK_PROG(gs, gs gsos2, found, missing) +if test $gs = missing; then + missing="$missing gs" +fi AC_CHECK_PROG(psselect, psselect, found, missing) -case "x$pnmcut$pnmcrop$pnmtopng$gs$psselect" in -*missing*) +if test $psselect = missing; then + missing="$missing psselect" +fi +AC_CHECK_PROG(pnmtops, pnmtops, found, missing) +if test $pnmtops = missing; then + missing="$missing pnmtops" +fi +if test -n "$missing"; then + cnt=0 + for i in $missing + do + cnt=`expr $cnt + 1` + eval "prog$cnt=$i" + done + plural="s" + case $cnt in + 1) + plural="" + progs="\`$prog1'" ;; + 2) + progs="\`$prog1' and \`$prog2'" ;; + 3) + progs="\`$prog1', \`$prog2', and \`$prog3'" ;; + 4) + progs="\`$prog1', \`$prog2', \`$prog3', and \`$prog4'" ;; + 5) + progs="\`$prog1', \`$prog2', \`$prog3', \`$prog4', and \`$prog5'" ;; + 6) + progs="\`$prog1', \`$prog2', \`$prog3', \`$prog4', \`$prog5', and \`$prog6'" ;; + esac make_html= make_install_html= AC_MSG_WARN([ - Since one or more of the above five programs can't be found in the path, - the HTML backend of groff (grohtml) won't work properly. Consequently, - no documentation in HTML format is built and installed. -]) ;; -esac + The program$plural + $progs + can't be found in the path, thus the HTML backend of groff (grohtml) + won't work properly. Consequently, no documentation in HTML format + is built and installed. +]) +fi AC_SUBST(make_html) AC_SUBST(make_install_html)])dnl dnl +dnl check to see whether pnmtops can handle the -nosetpage option +dnl +AC_DEFUN(GROFF_PNMTOPS_NOSETPAGE, +[AC_MSG_CHECKING([whether pnmtops can handle the -nosetpage option]) +if echo P2 2 2 255 0 1 2 0 | pnmtops -nosetpage > /dev/null 2>&1 ; then + AC_MSG_RESULT(yes) + pnmtops_nosetpage="pnmtops -nosetpage" +else + AC_MSG_RESULT(no) + pnmtops_nosetpage="pnmtops" +fi +AC_SUBST(pnmtops_nosetpage) +])dnl +dnl dnl dnl GROFF_CSH_HACK(if hack present, if not present) dnl @@ -188,6 +245,17 @@ AC_MSG_RESULT(no)) AC_LANG_POP(C++)])dnl dnl dnl +AC_DEFUN(GROFF_STDINT_H, +[AC_LANG_PUSH(C++) +AC_MSG_CHECKING([C++ ]) +AC_TRY_COMPILE([#include ], +[uint32_t x; int32_t y;], +AC_MSG_RESULT(yes);AC_DEFINE(HAVE_CC_STDINT_H, 1, + [Define if you have a C++ .]), +AC_MSG_RESULT(no)) +AC_LANG_POP(C++)])dnl +dnl +dnl AC_DEFUN(GROFF_TIME_T, [AC_LANG_PUSH(C++) AC_MSG_CHECKING([for declaration of time_t]) @@ -545,12 +613,12 @@ fi AC_LANG_POP(C++)])dnl dnl dnl -dnl If mkstemp() isn't available, use our own mkstemp.cc file. +dnl If mkstemp() isn't available, use our own mkstemp.cpp file. dnl AC_DEFUN(GROFF_MKSTEMP, [AC_MSG_CHECKING([for mkstemp]) AC_LANG_PUSH(C++) -AC_LIBSOURCE(mkstemp.cc) +AC_LIBSOURCE(mkstemp.cpp) AC_TRY_LINK([#include #include int (*f) (char *);], diff --git a/contrib/groff/configure b/contrib/groff/configure index fc28d84..b6ad057 100755 --- a/contrib/groff/configure +++ b/contrib/groff/configure @@ -267,7 +267,7 @@ PACKAGE_VERSION= PACKAGE_STRING= PACKAGE_BUGREPORT= -ac_unique_file="src/roff/groff/groff.cc" +ac_unique_file="src/roff/groff/groff.cpp" # Factoring default headers for most tests. ac_includes_default="\ #include @@ -305,7 +305,7 @@ ac_includes_default="\ # include #endif" -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS groff_top_builddir CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX TTYDEVDIRS OTHERDEVDIRS LPR LP LPQ PSPRINT DVIPRINT PERLPATH YACC RANLIB ac_ct_RANLIB INSTALL_INFO INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S SH_SCRIPT_SED_CMD CPP EGREP LIBM LIBOBJS BROKEN_SPOOLER_FLAGS PAGE g sys_tmac_prefix tmac_wrap pnmcut pnmcrop pnmtopng gs psselect make_html make_install_html LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS groff_top_builddir CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CXX CXXFLAGS ac_ct_CXX TTYDEVDIRS OTHERDEVDIRS LPR LP LPQ PSPRINT DVIPRINT PERLPATH YACC RANLIB ac_ct_RANLIB INSTALL_INFO INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN_S SH_SCRIPT_SED_CMD CPP EGREP LIBM LIBOBJS BROKEN_SPOOLER_FLAGS PAGE g sys_tmac_prefix tmac_wrap pnmcut pnmcrop pnmtopng gs psselect pnmtops make_html make_install_html pnmtops_nosetpage LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -3459,9 +3459,8 @@ done - for ac_header in stdlib.h unistd.h dirent.h limits.h sys/dir.h \ - string.h strings.h math.h stdint.h sys/time.h + string.h strings.h math.h sys/time.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if eval "test \"\${$as_ac_Header+set}\" = set"; then @@ -4093,6 +4092,246 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu +echo "$as_me:$LINENO: checking whether rand must be declared" >&5 +echo $ECHO_N "checking whether rand must be declared... $ECHO_C" >&6 +ac_ext=cc +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +if test "${groff_cv_decl_needed_rand+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +#include +#ifdef HAVE_STRING_H +#include +#endif +#ifdef HAVE_STRINGS_H +#include +#endif +#ifdef HAVE_STDLIB_H +#include +#endif +#ifdef HAVE_SYS_TIME_H +#include +#endif +#ifdef HAVE_UNISTD_H +#include +#endif +#ifdef HAVE_MATH_H +#include +#endif +int +main () +{ +#ifndef rand + char *p = (char *) rand; +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + groff_cv_decl_needed_rand=no +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +groff_cv_decl_needed_rand=yes +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi + +echo "$as_me:$LINENO: result: $groff_cv_decl_needed_rand" >&5 +echo "${ECHO_T}$groff_cv_decl_needed_rand" >&6 +if test $groff_cv_decl_needed_rand = yes; then + +cat >>confdefs.h <<\_ACEOF +#define NEED_DECLARATION_RAND 1 +_ACEOF + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +echo "$as_me:$LINENO: checking whether snprintf must be declared" >&5 +echo $ECHO_N "checking whether snprintf must be declared... $ECHO_C" >&6 +ac_ext=cc +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +if test "${groff_cv_decl_needed_snprintf+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +#include +#ifdef HAVE_STRING_H +#include +#endif +#ifdef HAVE_STRINGS_H +#include +#endif +#ifdef HAVE_STDLIB_H +#include +#endif +#ifdef HAVE_SYS_TIME_H +#include +#endif +#ifdef HAVE_UNISTD_H +#include +#endif +#ifdef HAVE_MATH_H +#include +#endif +int +main () +{ +#ifndef snprintf + char *p = (char *) snprintf; +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + groff_cv_decl_needed_snprintf=no +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +groff_cv_decl_needed_snprintf=yes +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi + +echo "$as_me:$LINENO: result: $groff_cv_decl_needed_snprintf" >&5 +echo "${ECHO_T}$groff_cv_decl_needed_snprintf" >&6 +if test $groff_cv_decl_needed_snprintf = yes; then + +cat >>confdefs.h <<\_ACEOF +#define NEED_DECLARATION_SNPRINTF 1 +_ACEOF + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +echo "$as_me:$LINENO: checking whether srand must be declared" >&5 +echo $ECHO_N "checking whether srand must be declared... $ECHO_C" >&6 +ac_ext=cc +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + +if test "${groff_cv_decl_needed_srand+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" + +#include +#ifdef HAVE_STRING_H +#include +#endif +#ifdef HAVE_STRINGS_H +#include +#endif +#ifdef HAVE_STDLIB_H +#include +#endif +#ifdef HAVE_SYS_TIME_H +#include +#endif +#ifdef HAVE_UNISTD_H +#include +#endif +#ifdef HAVE_MATH_H +#include +#endif +int +main () +{ +#ifndef srand + char *p = (char *) srand; +#endif + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + groff_cv_decl_needed_srand=no +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +groff_cv_decl_needed_srand=yes +fi +rm -f conftest.$ac_objext conftest.$ac_ext +fi + +echo "$as_me:$LINENO: result: $groff_cv_decl_needed_srand" >&5 +echo "${ECHO_T}$groff_cv_decl_needed_srand" >&6 +if test $groff_cv_decl_needed_srand = yes; then + +cat >>confdefs.h <<\_ACEOF +#define NEED_DECLARATION_SRAND 1 +_ACEOF + +fi +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + echo "$as_me:$LINENO: checking whether strcasecmp must be declared" >&5 echo $ECHO_N "checking whether strcasecmp must be declared... $ECHO_C" >&6 ac_ext=cc @@ -4453,6 +4692,57 @@ ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +echo "$as_me:$LINENO: checking C++ " >&5 +echo $ECHO_N "checking C++ ... $ECHO_C" >&6 +cat >conftest.$ac_ext <<_ACEOF +#line $LINENO "configure" +#include "confdefs.h" +#include +int +main () +{ +uint32_t x; int32_t y; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + echo "$as_me:$LINENO: result: yes" >&5 +echo "${ECHO_T}yes" >&6; +cat >>confdefs.h <<\_ACEOF +#define HAVE_CC_STDINT_H 1 +_ACEOF + +else + echo "$as_me: failed program was:" >&5 +cat conftest.$ac_ext >&5 +echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi +rm -f conftest.$ac_objext conftest.$ac_ext +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + +ac_ext=cc +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + echo "$as_me:$LINENO: checking for inttypes.h" >&5 echo $ECHO_N "checking for inttypes.h... $ECHO_C" >&6 cat >conftest.$ac_ext <<_ACEOF @@ -5118,7 +5408,10 @@ LIBS="$LIBS -lc $LIBM" -for ac_func in fmod getcwd putenv snprintf strerror strtol + + +for ac_func in fmod getcwd putenv snprintf strcasecmp \ + strerror strncasecmp strtol do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` echo "$as_me:$LINENO: checking for $ac_func" >&5 @@ -5196,8 +5489,7 @@ LIBS="$saved_libs" - -for ac_func in gettimeofday isatty rename strcasecmp strncasecmp strsep +for ac_func in gettimeofday isatty rename setlocale strsep do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` echo "$as_me:$LINENO: checking for $ac_func" >&5 @@ -5660,6 +5952,7 @@ echo "${ECHO_T}$tmac_wrap" >&6 make_html=html make_install_html=install_html +missing= # Extract the first word of "pnmcut", so it can be a program name with args. set dummy pnmcut; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 @@ -5696,6 +5989,9 @@ else echo "${ECHO_T}no" >&6 fi +if test $pnmcut = missing; then + missing="$missing pnmcut" +fi # Extract the first word of "pnmcrop", so it can be a program name with args. set dummy pnmcrop; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 @@ -5732,6 +6028,9 @@ else echo "${ECHO_T}no" >&6 fi +if test $pnmcrop = missing; then + missing="$missing pnmcrop" +fi # Extract the first word of "pnmtopng", so it can be a program name with args. set dummy pnmtopng; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 @@ -5768,6 +6067,9 @@ else echo "${ECHO_T}no" >&6 fi +if test $pnmtopng = missing; then + missing="$missing pnmtopng" +fi # Extract the first word of "gs gsos2", so it can be a program name with args. set dummy gs gsos2; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 @@ -5804,6 +6106,9 @@ else echo "${ECHO_T}no" >&6 fi +if test $gs = missing; then + missing="$missing gs" +fi # Extract the first word of "psselect", so it can be a program name with args. set dummy psselect; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 @@ -5840,23 +6145,103 @@ else echo "${ECHO_T}no" >&6 fi -case "x$pnmcut$pnmcrop$pnmtopng$gs$psselect" in -*missing*) +if test $psselect = missing; then + missing="$missing psselect" +fi +# Extract the first word of "pnmtops", so it can be a program name with args. +set dummy pnmtops; ac_word=$2 +echo "$as_me:$LINENO: checking for $ac_word" >&5 +echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +if test "${ac_cv_prog_pnmtops+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +else + if test -n "$pnmtops"; then + ac_cv_prog_pnmtops="$pnmtops" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_pnmtops="found" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done + + test -z "$ac_cv_prog_pnmtops" && ac_cv_prog_pnmtops="missing" +fi +fi +pnmtops=$ac_cv_prog_pnmtops +if test -n "$pnmtops"; then + echo "$as_me:$LINENO: result: $pnmtops" >&5 +echo "${ECHO_T}$pnmtops" >&6 +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 +fi + +if test $pnmtops = missing; then + missing="$missing pnmtops" +fi +if test -n "$missing"; then + cnt=0 + for i in $missing + do + cnt=`expr $cnt + 1` + eval "prog$cnt=$i" + done + plural="s" + case $cnt in + 1) + plural="" + progs="\`$prog1'" ;; + 2) + progs="\`$prog1' and \`$prog2'" ;; + 3) + progs="\`$prog1', \`$prog2', and \`$prog3'" ;; + 4) + progs="\`$prog1', \`$prog2', \`$prog3', and \`$prog4'" ;; + 5) + progs="\`$prog1', \`$prog2', \`$prog3', \`$prog4', and \`$prog5'" ;; + 6) + progs="\`$prog1', \`$prog2', \`$prog3', \`$prog4', \`$prog5', and \`$prog6'" ;; + esac make_html= make_install_html= { echo "$as_me:$LINENO: WARNING: - Since one or more of the above five programs can't be found in the path, - the HTML backend of groff (grohtml) won't work properly. Consequently, - no documentation in HTML format is built and installed. + The program$plural + $progs + can't be found in the path, thus the HTML backend of groff (grohtml) + won't work properly. Consequently, no documentation in HTML format + is built and installed. " >&5 echo "$as_me: WARNING: - Since one or more of the above five programs can't be found in the path, - the HTML backend of groff (grohtml) won't work properly. Consequently, - no documentation in HTML format is built and installed. -" >&2;} ;; -esac + The program$plural + $progs + can't be found in the path, thus the HTML backend of groff (grohtml) + won't work properly. Consequently, no documentation in HTML format + is built and installed. +" >&2;} +fi + + +echo "$as_me:$LINENO: checking whether pnmtops can handle the -nosetpage option" >&5 +echo $ECHO_N "checking whether pnmtops can handle the -nosetpage option... $ECHO_C" >&6 +if echo P2 2 2 255 0 1 2 0 | pnmtops -nosetpage > /dev/null 2>&1 ; then + echo "$as_me:$LINENO: result: yes" >&5 +echo "${ECHO_T}yes" >&6 + pnmtops_nosetpage="pnmtops -nosetpage" +else + echo "$as_me:$LINENO: result: no" >&5 +echo "${ECHO_T}no" >&6 + pnmtops_nosetpage="pnmtops" +fi ac_config_files="$ac_config_files stamp-h" @@ -6495,8 +6880,10 @@ s,@pnmcrop@,$pnmcrop,;t t s,@pnmtopng@,$pnmtopng,;t t s,@gs@,$gs,;t t s,@psselect@,$psselect,;t t +s,@pnmtops@,$pnmtops,;t t s,@make_html@,$make_html,;t t s,@make_install_html@,$make_install_html,;t t +s,@pnmtops_nosetpage@,$pnmtops_nosetpage,;t t s,@LTLIBOBJS@,$LTLIBOBJS,;t t CEOF diff --git a/contrib/groff/configure.ac b/contrib/groff/configure.ac index 75c4799..c507963 100644 --- a/contrib/groff/configure.ac +++ b/contrib/groff/configure.ac @@ -1,7 +1,7 @@ dnl Process this file with autoconf to produce a configure script. AC_INIT AC_CONFIG_HEADERS(src/include/config.h:src/include/config.hin) -AC_CONFIG_SRCDIR([src/roff/groff/groff.cc]) +AC_CONFIG_SRCDIR([src/roff/groff/groff.cpp]) dnl checks for programs GROFF_SRCDIR GROFF_BUILDDIR @@ -24,7 +24,7 @@ GROFF_CSH_HACK(SH_SCRIPT_SED_CMD='1s/.*/:/', SH_SCRIPT_SED_CMD='1s/a/a/') AC_SUBST(SH_SCRIPT_SED_CMD) dnl checks for headers AC_CHECK_HEADERS(stdlib.h unistd.h dirent.h limits.h sys/dir.h \ - string.h strings.h math.h stdint.h sys/time.h) + string.h strings.h math.h sys/time.h) GROFF_ISC_SYSV3 GROFF_POSIX GROFF_SRAND @@ -33,12 +33,16 @@ GROFF_NEED_DECLARATION(hypot) GROFF_NEED_DECLARATION(popen) GROFF_NEED_DECLARATION(pclose) GROFF_NEED_DECLARATION(putenv) +GROFF_NEED_DECLARATION(rand) +GROFF_NEED_DECLARATION(snprintf) +GROFF_NEED_DECLARATION(srand) GROFF_NEED_DECLARATION(strcasecmp) GROFF_NEED_DECLARATION(strncasecmp) GROFF_SYS_NERR GROFF_SYS_ERRLIST GROFF_OSFCN_H GROFF_LIMITS_H +GROFF_STDINT_H GROFF_INTTYPES_H dnl checks for typedefs GROFF_UNSIGNED_LONG_LONG @@ -52,9 +56,10 @@ dnl checks for functions AC_FUNC_MMAP saved_libs="$LIBS" LIBS="$LIBS -lc $LIBM" -AC_REPLACE_FUNCS(fmod getcwd putenv snprintf strerror strtol) +AC_REPLACE_FUNCS(fmod getcwd putenv snprintf strcasecmp \ + strerror strncasecmp strtol) LIBS="$saved_libs" -AC_CHECK_FUNCS(gettimeofday isatty rename strcasecmp strncasecmp strsep) +AC_CHECK_FUNCS(gettimeofday isatty rename setlocale strsep) GROFF_MKSTEMP AC_DECL_SYS_SIGLIST dnl checks for compiler characteristics @@ -68,6 +73,7 @@ GROFF_PAGE GROFF_G GROFF_TMAC GROFF_HTML_PROGRAMS +GROFF_PNMTOPS_NOSETPAGE AC_CONFIG_FILES(stamp-h, [echo timestamp > stamp-h]) AC_CONFIG_FILES([Makefile doc/Makefile src/xditview/Imakefile]) AC_OUTPUT diff --git a/contrib/groff/contrib/groffer/ChangeLog b/contrib/groff/contrib/groffer/ChangeLog index 263dbcd..f706907 100644 --- a/contrib/groff/contrib/groffer/ChangeLog +++ b/contrib/groff/contrib/groffer/ChangeLog @@ -1,3 +1,100 @@ +2003-01-22 Bernd Warken + ________________________________________________________________ + * release of groffer 0.9.4 + + * groffer.sh: corrections for some restrictive shells + - Possible exit codes in actual `ash' are between 0 and 63. To + handle even deeper restrictions, use 7 as maximal code instead + of 255 as replacement for error -1. + - Remove variables $_BAD2 and $_BAD3. + - Replace `trap' argument `EXIT' by 0 and write new fuctions + `trap_clean' and `trap_set' to handle the restrictions of `trap' + for some shells. + - Correct wrong $MANPATH to $_MAN_PATH in function + `man_do_filespec'. + - Test existence of directory before deleting it in the + `clean_up' definitions. + - Correct help output in `usage' (called by `--help'). + + * TODO: + Remove mention of `shoop' and `apropos'. + +2002-10-21 Bernd Warken + ________________________________________________________________ + * release of groffer 0.9.3 + + * groffer.sh: new temporary subdirectory + - Generate temporary subdirectory for storing temporary files + with better names in future groffer versions (name: + "groffer$$" in usual temporary directory). + - Use `umask 000' for temporary files to allow cleaning up + for everyone after a system break. + - Change both clean_up() functions (for normal shell and + for main_display() subshell) to handle the new subdirectory. + - clean_up_secondary() and $_TMP_PREFIX are unnecessary now, so + they were removed. + + * Makefile.sub: `sed' commands for "groffer:" + - Remove "@g@" entry (not used in "groffer.sh"). + - Add global replace for "@BINDIR@" and "@VERSION@" for future + usage. + + * TODO: think about... + - writing part of groffer in C/C++. + - handling several files with different macro packages. + +2002-10-17 Bernd Warken + ________________________________________________________________ + * fixes of groffer 0.9.2 + + * groffer.sh: + Terminate main_parse_MANOPT() if $MANOPT is empty or consists + of space characters only. + + * groffer.man: some fixes in "GROFFER OPTIONS" + - New macro ".Header_CB" for CB font in .TP headers; used for + definition of variables in option --mode. + - Fix some option references to refer to long options. + + * README: + New file for general information on the groffer source; it is + not installed. + +2002-10-14 Bernd Warken + + * Makefile.sub: + add replacement "@BINDIR@" to "$(bindir)" for "groffer:" + + * groffer.sh: + Define $_this as "@BINDIR@/${_PROGRAM_NAME}" to save the right + installation position of groffer for the special shell calling. + + * groffer.man: + Remove double definition of filespec parameters. + +2002-10-13 Bernd Warken + ________________________________________________________________ + * release of groffer 0.9.2 + + * groffer.sh: fixes + - Fix some 'sed' functions: two in func_stack_dump(), one in + base_name(), add 'sed' command in list_from_cmdline(). + - Finish main_parse_MANOPT() if $MANOPT is empty. + - Sort $_OPTS_GROFF_SHORT_NA like groff short options (but + unchanged). + - Fix some comments. + + * groffer.man: make it more readable (but no additions) + - A shortened section "SYNOPSIS" is followed by a simplified + section "DESCRIPTION". + - The options from "SYNOPSIS" go to new section "OPTION + OVERVIEW" with all groffer options in a single subsection. + - The details of all groffer options are described in section + "GROFFER OPTIONS". + - New macro for file names ".File_name". + - "Option Parsing" is moved to section "COMPATIBILITY". + - Fix some "EXAMPLES". + 2002-09-30 Bernd Warken ________________________________________________________________ * release of groffer 0.9.1 diff --git a/contrib/groff/contrib/groffer/Makefile.sub b/contrib/groff/contrib/groffer/Makefile.sub index 4be6846..333dedb 100644 --- a/contrib/groff/contrib/groffer/Makefile.sub +++ b/contrib/groff/contrib/groffer/Makefile.sub @@ -2,7 +2,7 @@ # File position: /contrib/groffer/Makefile.sub -# Last update: 23 June 2002 +# Last update: 21 October 2002 # Copyright (C) 2001,2002 Free Software Foundation, Inc. # Written by Werner Lemberg @@ -33,8 +33,8 @@ all: groffer groffer: groffer.sh rm -f $@; \ - sed -e "s|@g@|$(g)|g" \ - -e "s|@VERSION@|$(version)$(revision)|" \ + sed -e "s|@BINDIR@|$(bindir)|g" \ + -e "s|@VERSION@|$(version)$(revision)|g" \ -e $(SH_SCRIPT_SED_CMD) $(srcdir)/groffer.sh >$@; \ chmod +x $@ diff --git a/contrib/groff/contrib/groffer/README b/contrib/groff/contrib/groffer/README new file mode 100644 index 0000000..413f49f --- /dev/null +++ b/contrib/groff/contrib/groffer/README @@ -0,0 +1,23 @@ +The `groffer' program is the easiest way to read `groff' documents. +All input is sent to `grog' and then to `groff' such that no special +`groff' arguments must be determined. + +`groffer' also has many built-in `man' functionalities to find and +read the manual pages on UNIX and similar operating systems. It +accepts the information from an installed `man' program, but tries to +find a man path by itself if there isn't any. + +So far, `groffer' is a shell script. It should run on any POSIX or +Bourne style shell, but it runs the fastest if the `ash' shell is +installed on the system. This shell is found out and started +automatically. There are efforts to port part of the shell script to +C/C++ to increase the speed independent of the shell. + +For reporting bugs of `groffer', groff's free mailing list + can be used. For a general discussion, the + is more useful; see the `README' file in the top +directory of the `groff' source package for more details on this +mailing list. + +`groffer' is a `groff contrib' project that was written by Bernd +Warken . diff --git a/contrib/groff/contrib/groffer/TODO b/contrib/groff/contrib/groffer/TODO index 6ff8f65..3aadb19 100644 --- a/contrib/groff/contrib/groffer/TODO +++ b/contrib/groff/contrib/groffer/TODO @@ -2,9 +2,9 @@ # File position: /contrib/groffer/TODO -# Last update: 30 Sep 2002 +# Last update: 22 Jan 2003 -# Copyright (C) 2001,2002 Free Software Foundation, Inc. +# Copyright (C) 2001,2002,2003 Free Software Foundation, Inc. # Written by Bernd Warken # This file is part of groff. @@ -32,9 +32,10 @@ Optimization: - Optimize man path determination in manpath_add_lang_sys() for speed by building-up the man path only by and by as far as necessary (not trivial). +- To increase the running speed write part of the groffer shell script + in C/C++. Features: -- Consider using the `shoop' package (OOP for `sh'). - Revise option handling of `grog'. - `gxditview' needs a complete shower. @@ -42,9 +43,11 @@ Revision: - Should there be a native implementation for `--apropos'? - Revise the `--all' feature to better reflect GNU man. - The debug function stack is buggy (no effect on normal operation). +- The actual `groff' and `grog' do not support file arguments each +of which has a different macro package (except `man' and `doc'). So +`roffer' should create several display files for such arguments. Documentation: -- Write a README file. - Improve the documentation of the search algorithm for man pages in both the groffer script and the man page `groffer.man'. - In `groff.man', add more documentation for parts that were taken over diff --git a/contrib/groff/contrib/groffer/groffer.man b/contrib/groff/contrib/groffer/groffer.man index fd72504..da6a532 100644 --- a/contrib/groff/contrib/groffer/groffer.man +++ b/contrib/groff/contrib/groffer/groffer.man @@ -15,8 +15,8 @@ groffer.1 - man page for groffer (section 1). Source file position: /contrib/groffer/groffer.man Installed position: $prefix/share/man/man1/groffer.1 -Version : groffer 0.9.1 -Last update : 30 Sep 2002 +Version : groffer 0.9.2 +Last update : 13 Oct 2002 This file is part of groff, the GNU roff type-setting system. @@ -59,7 +59,7 @@ FDL in the main directory of the groff source package. .ds @i- "\f[CI]-\f[]\"" .ds @i-- "\f[CI]--\f[]\"" . -.ds Ellipsis .\|.\|.\" +.ds Ellipsis ".\|.\|.\"" . .\" -------------------------------------------------------------------- .\" setup for the macro definitions below @@ -160,6 +160,24 @@ FDL in the main directory of the groff source package. . hy .. .c -------------------------------------------------------------------- +.c .File_name () +.c +.c Display a file or directory name in CB font. +.c +.de File_name +. Header_CB \\$@ +.. +.c -------------------------------------------------------------------- +.c .Header_CB () +.c +.c Display a line in CB font, for example after .TP +.c +.de Header_CB +. nh +. Text \f[CB]\\$1\f[]\\$2 +. hy +.. +.c -------------------------------------------------------------------- .c .Opt_- ([]) .c .c Print `-' (minus sign); optional punctuation. @@ -611,8 +629,7 @@ FDL in the main directory of the groff source package. . .ad l .Synopsis groffer -.RI [ viewing_options ] -.RI [ man_options ] +.RI [ groffer_options ] .RI [ groff_options ] .Opt_[--] .RI [ "filespec" "\*[Ellipsis]]" @@ -627,16 +644,81 @@ FDL in the main directory of the groff source package. ./Synopsis . . +.\" -------------------------------------------------------------------- +.SH DESCRIPTION +.\" -------------------------------------------------------------------- +. +The +.I groffer +program is the easiest way to use +.BR groff (@MAN1EXT@). +It can display arbitrary documents written in the +.BR groff (@MAN7EXT@) +language or other +.BR roff (@MAN7EXT@) +languages that are compatible to the original troff language. +. +The +.I groffer +program also includes many of the features for finding and displaying +the UNIX manual pages +.RI ( man\~pages ), +such that it can be used as a replacement for a +.BR man (1) +program. +. +Moreover, compressed files that can be handled by +.BR gzip (1) +or +.BR bzip2 (1) +are decompressed on-the-fly. +. +. +.P +The normal usage is quite simple by supplying a file name or name of a +man\~page without further options. +. +But the option handling has many possibilities for creating special +behaviors. +. +These can be stored in a configuration file. +. +. +.P +The output can be generated and viewed in several different ways +available for +.IR groff . +. +This includes the groff native X viewer +.BR gxditview (@MAN1EXT@), +each Postcript or dvi display program, a web browser by generating +html in www-mode, or several text modes in text terminals. +. +. +.P +Most options that must be named when running +.I groff +are determined automatically because +.I groffer +internally calls the +.BR grog (@MAN1EXT@) +program. +. +But all parts can be controlled manually by supplying options. +. +. +.\" -------------------------------------------------------------------- +.SH "OPTION OVERVIEW" +.\" -------------------------------------------------------------------- +. .TP -.I viewing_options -These options determine and configure the display mode. +.I groffer_options +The following options determine and configure the display mode. . They were synchronized with the options of both .BR groff (@MAN1EXT@) and GNU .BR man (1). -As groff uses almost any letter in its option set, only long option -names are available for most features. . If none of these options is used groffer tries to find a suitable display mode automatically. @@ -670,7 +752,10 @@ display mode automatically. . .P The following long options were adapted from the corresponding X -Toolkit options with a single leading minus; see +Toolkit options. +. +Their single leading minus in X Toolkit was changed to a double minus +for long options; see .BR X (1). . . @@ -687,6 +772,50 @@ Toolkit options with a single leading minus; see .Opt_[alt] -- title string .Opt_[alt] -- xrm X_resource . +. +.P +The following long options regulate whether and how +.I man\~pages +(UNIX manual pages) are searched. +. +They were constructed for +.IR groffer , +but they are compatible with the long options of the +.I GNU man +program. +. +. +.P +.Opt_[alt] -- all +.Opt_[alt] -- ascii +.Opt_[alt] -- apropos +.Opt_[alt] -- ditroff +.Opt_[alt] -- extension suffix +.Opt_[alt] -- locale language +.Opt_[alt] -- local-file +.Opt_[alt] -- man +.Opt_[alt] -- manpath dir1:dir2:\*[Ellipsis] +.Opt_[alt] -- no-location +.Opt_[alt] -- no-man +.Opt_[alt] -- sections sec1:sec2:\*[Ellipsis] +.Opt_[alt] -- systems sys1,sys2,\*[Ellipsis] +.Opt_[alt] -- troff-device device +.Opt_[alt] -- whatis +. +. +.P +The GNU +.I man +long options that are not mentioned are recognized, but they are just +ignored because of alternative implementations. +. +The full set of long and short options of the GNU man program can be +passed via the environment variable +.Env_var $MANOPT ; +see +.BR man (1) +if your system has GNU man installed. +. .RE . . @@ -731,302 +860,85 @@ and . . .TP -.I man_options -These options regulate whether and how man pages are searched. -. -They are compatible with the long options of the -.I GNU man -program. -. -. -.RS -. -.P -.Opt_[alt] -- all -.Opt_[alt] -- ascii -.Opt_[alt] -- apropos -.Opt_[alt] -- ditroff -.Opt_[alt] -- extension suffix -.Opt_[alt] -- locale language -.Opt_[alt] -- local-file -.Opt_[alt] -- man -.Opt_[alt] -- manpath dir1:dir2:\*[Ellipsis] -.Opt_[alt] -- no-location -.Opt_[alt] -- no-man -.Opt_[alt] -- sections sec1:sec2:\*[Ellipsis] -.Opt_[alt] -- systems sys1,sys2,\*[Ellipsis] -.Opt_[alt] -- troff-device device -.Opt_[alt] -- whatis -. -. -.P -The GNU -.I man -long options that are not mentioned are recognized, but they are just -ignored because of alternative implementations. -. -The full set of long and short options of the GNU man program can be -passed via the environment variable -.Env_var $MANOPT ; -see -.BR man (1) -if your system has GNU man installed. -. -.RE -. -. -.TP .I filespec -is a sequence of file names or templates for searching +is one or more file names or templates for searching man\~pages, see .BR man (1). -A +Each .I filespec can have one of the following forms. . . .RS . -.TP 10m -.I filename -the path name of an existing file. +.P +No +.I filespec +parameters means standard input. . . -.TP +.TP 10m .Opt_short stands for standard input (can occur several times). . . .TP -.BI man: name ( section ) -search the man\~page -.I name -in section\~\c -.IR section . +.I filename +the path name of an existing file. . . .TP -.BI man: name . section -search the man\~page .I name -in section\~\c -.IR section . +if +.I name +is not an existing file search for the man\~page called in the lowest +man\~section that has a document for this name. . . .TP .BI man: name -search the man\~page -.I name -in the lowest available section. +search for a man\~page in the lowest man\~section that has a document +called +.IR name . . . .TP +.BI man: name . section +.TP+ +.BI man: name ( section ) +.TP+ .IB name ( section ) -search the man\~page -.I name -in section\~\c -.IR section . -. -. -.TP +.TP+ .IB name . section -search the man\~page +each of these search the man\~page .I name -in section\~\c +in man\~section\~\c .IR section . . . .TP -.I standard_section -if this is `1', \*[Ellipsis], `9', `o', or `n' try to retrieve the -next argument as a man\~page in this section. -. -. -.TP -.I name -search for the man\~page +.I "std_section name" +two arguments like in the +.BR man (1) +program to find man\~page .I name -in the lowest available section. +in man\~section +.IR std_section . . +In +.IR groffer , +the argument +.I std_section +is a standard section name for man\~pages; these are a digit `1', +\&\*[Ellipsis], `9', or the single letters `o' or `n'. . -.P -No -.I filespec -parameters means standard input. +This should be used only with care. . .RE . . -.P -For details on the options, see section -.BR OPTIONS . -. -. -.\" -------------------------------------------------------------------- -.SH DESCRIPTION -.\" -------------------------------------------------------------------- -. -The -.I groffer -program is part of -.BR groff (@MAN7EXT@). -It can be used to display arbitrary documents written in the -.BR roff (@MAN7EXT@) -formatting language in several different ways, in an X window viewer -program or in a text terminal. -. -The viewer programs can be chosen as the groff native viewer -.BR gxditview (@MAN1EXT@), -a Postcript or dvi display program, or a web browser. -. -. -.P -A search facility for manual pages ( -.IR man\~pages ) -is provided. -. -Almost the whole functionality of the -.I GNU man -program was provided or suitably adapted. -. -This makes the groffer program a valuable tool on systems with a poor -.I man -system. -. -. -.P -The program always concatenates all input specified by the non-option -parameters of the calling command line or standard input. -. -Compressed standard input or files are decompressed on-the-fly. -. -. -.P -Normally, the input is run through the -.BR groff (@MAN1EXT@) -text processor before being displayed. -. -By using the option -.Opt_short Q , -the roff source code is displayed without formatting. -. -. -.P -The formatting process can be regulated by all options that are -available groff. -. -By using the -.Opt_short T -option, groffer can be switched to behave exactly like groff without -using its viewer facilities, but additionally with the search and -decompression features. -. -. -.P -All necessary options can be determined automatically. -. -For example, the groffer program internally uses the -.BR grog (@MAN1EXT@) -program to determine from the unformatted document which preprocessors -should be run and which macro files should be included. -. -But all parts of the program can be controlled manually by suitable -options. -. -. -.\" -------------------------------------------------------------------- -.SH OPTIONS -.\" -------------------------------------------------------------------- -. -The groffer program provides its own parser for command line options -that is compatible to both POSIX -.BR getopts (1) -and GNU -.BR getopt (1). -The command line behaves as usually. -. -For completeness, the details are provided here. -. -. -.\" -------------------------------------------------------------------- -.SS "Option Parsing" -.\" -------------------------------------------------------------------- -. -The following types of options are supported, equally on all systems -that are able to run the groffer program: -. -. -.Topic -single character options are always preceded by a single minus -character, for example, -.Opt_short c . -. -. -.Topic -the argument for a single character option is the next command line -argument, for example, -.Opt_alt - o\~ arg , -or can be appended to the option character within the same argument -.Opt_alt - o arg . -. -. -.Topic -clusters of such single character options without an argument, -eventually terminated by a single character option with an argument; -for example, -.Opt_alt - abo arg -is equivalent to -.Opt_short a\~\c -.Opt_short b\~\c -.Opt_short o\~\c -.I arg . -. -. -.Topic -Long options, that means option with names longer than one character -are always prededed by a double minus; an option argument can either -go to the next command line argument or be appended with an equal sign -to the argument; for example, -.Opt_alt -- long= arg -is equivalent to -.Opt_alt -- long\~ arg . -. -. -.Topic -An argument of -.Opt_-- -ends option parsing; all further command line arguments are -interpreted as filespec arguments. -. -. -.Topic -By default, all command line arguments that are neither options nor -option arguments are interpreted as filespec parameters and stored -until option parsing has finished. -. -For example, the command line -.Shell_cmd "groffer file1 -a -o arg file 2" -is, by default, equivalent to -.Shell_cmd "groffer -a -o arg -- file1 file 2" -. -. -.Topic -This behavior can be changed by setting the environment variable -.Env_var $POSIXLY_CORRECT -to a non-empty value; in this case, option processing is stopped as -soon as the first non-option argument is found. -. -For example, in posixly correct mode, the command line -.Shell_cmd "groffer file1 -a -o arg file 2" -is equivalent to -.Shell_cmd "groffer -- file1 -a -o arg file 2" -As this leads to unwanted behavior in most cases, most people do not -want to set -.Env_var $POSIXLY_CORRECT . -. -. .\" -------------------------------------------------------------------- -.SS "Compatibility with Options from other Programs" +.SH "GROFFER OPTIONS" .\" -------------------------------------------------------------------- . All short options of @@ -1067,10 +979,6 @@ These options are documented in the following; the other options are recognized, but ignored. . . -.\" -------------------------------------------------------------------- -.SS "Native groffer Options" -.\" -------------------------------------------------------------------- -. .Opt_def - h Print usage message to standard error and exit. . @@ -1084,13 +992,10 @@ This is the equivalent . .Opt_def - T devname Switch to -.Opt_long mode\~device , -. -thus disabling the -.I groffer -viewing. +.Opt_long mode +.IR devname . . -Instead, the input is formatted and postprocessed using plain +The input is formatted and postprocessed using plain .I groff with .I devname @@ -1271,14 +1176,14 @@ Originates from GNU . .Opt_def -- foreground color This is equivalent to -.Opt_short fg . +.Opt_long fg . . . .Opt_def -- fg color Set the foreground color of the viewer window. . This is an adaption of the X Toolkit option -.Opt_short bg . +.Opt_long bg . . The argument is an X color name, see .BR (1) @@ -1287,7 +1192,7 @@ for details. . .Opt_def -- font font_name This is equivalent to -.Opt_short ft . +.Opt_long ft . . . .Opt_def -- ft font_name @@ -1367,7 +1272,7 @@ The following mode values are recognized: . . .TP -.B auto +.Header_CB auto Display in the default manner; this actually means to try the modes .IR ps , .IR x , @@ -1381,40 +1286,41 @@ with . . .TP -.B dvi +.Header_CB dvi Display formatted input in a dvi viewer program; equivalent to .Opt_long dvi . . . .TP -.B pdf +.Header_CB pdf Display formatted input in a PDF (Portable Document Format) viewer program; equivalent to .Opt_long pdf . . . .TP -.B ps +.Header_CB ps Display formatted input in a Postscript viewer program; equivalent to .Opt_long ps . . . .TP -.B tty +.Header_CB tty Display formatted input in a text terminal; equivalent to .Opt_long tty . . . .TP -.B www +.Header_CB www Display formatted input in a internet browser program; equivalent to .Opt_long www . . . .TP -.B x +.Header_CB x Display formatted input in a native roff viewer such as -.BR gxditview (@MAN1EXT@); equivalent to +.BR gxditview (@MAN1EXT@); +equivalent to .Opt_long x . . . @@ -1427,7 +1333,7 @@ They are only interesting for advanced applications. . . .TP -.B groff +.Header_CB groff Generate device output with plain .I groff without using the special viewing features of @@ -1442,7 +1348,7 @@ is assumed. . . .TP -.B source +.Header_CB source Display source code; same as .Opt_short Q . . @@ -1772,7 +1678,7 @@ This mode testing sequence for .B default mode can be changed by specifying a comma separated list of modes with the option -.Opt_long default-modes. +.Opt_long default\-modes. . . .P @@ -1840,11 +1746,11 @@ PDF format, so it was not chosen as the major mode. You can change this by the options .Opt_long pdf and -.Opt_long auto-modes . +.Opt_long auto\-modes . . . .\" -------------------------------------------------------------------- -.SS "Displaying on a tty" +.SS "Text mode" .\" -------------------------------------------------------------------- . If the variable @@ -1868,7 +1774,7 @@ This can be changed by specifying option .P The pager to be used can be specified by option .Opt_long pager -by the environment variable +or by the environment variable .Env_var $PAGER . If this is not set or empty the .BR less (1) @@ -1924,22 +1830,14 @@ for customization), and . . .\" -------------------------------------------------------------------- -.SH "FILE PARAMETERS" -.\" -------------------------------------------------------------------- -. -The non-option command line parameters determine which files should be -displayed. -. -. -.\" -------------------------------------------------------------------- -.SS "Filespecs" +.SH "MAN\~PAGE\~SEARCHING" .\" -------------------------------------------------------------------- . -The default behavior of groffer is to first test whether the file -parameter is represents a local file; if not, it is assumed to -represent a filespec for searching one or more man\~page. +The default behavior of groffer is to first test whether a file +parameter represents a local file; if it is not an existing file name, +it is assumed to represent a name of a man\~page. . -This behavior can be modified by options. +This behavior can be modified by the following options. . . .TP @@ -1948,111 +1846,51 @@ forces to interpret all file parameters as filespecs for searching man\~pages. . .TP -.Opt_long no-man +.Opt_long no\-man .TP+ -.Opt_long local-file +.Opt_long local\-file disable the man searching; so only local files are displayed. . . .P -The following parameter formats are recognized to represent a wanted -man\~page. -. -. -.TP -.BI man: name ( section ) -the quasi-URL notation used in many Desktop systems to -represent the man\~page -.I name -in -.IR section . -. -. -.TP -.BI man: name -search the man\~page -.I name -in the lowest section. -The corresponding command with the man program would be -.Shell_cmd man\~ name -. -. -.TP -.IB name . section -the man\~page -.I name -in -.IR section . -The corresponding command with the man program would be -.Shell_cmd man\~ section\~name -. -. -.TP -.I name -if -.I name -is not an existing file search for the man\~page -.I name -in the lowest section just like -.Shell_cmd man\~ name -. -. -.TP -.I section name -Even this curious construct known from the various -.I man -programs is handled. -. -For example, -.Shell_cmd "groffer 7 groff" -was modelled according to -.Shell_cmd "man 7 groff" -retrieves the man\~page named -.I groff -in section 7. -. -Only a few standard section names are accepted, being actually the -number sections -.I 1, 2, 3, 4, 5, 6, 7, 8, -and -.IR 9, -and the lower case letters -.I `o' -and -.IR `n' . -. -. -.P If neither a local file nor a man\~page was retrieved for some file parameter a warning is issued on standard error, but processing is continued. . . -.\" -------------------------------------------------------------------- -.SS "Man\~Page Searching" -.\" -------------------------------------------------------------------- -. -The groffer program provides a search facility for system manual pages -(man\~pages). +.P +The groffer program provides a search facility for man\~pages. . All long options, all environment variables, and most of the functionality of the GNU .BR man (1) program were implemented. . +This inludes the extended file names of man\~pages, for example, +the man\~page of +.I groff +in man\~section 7 may be stored under +.File_name /usr/share/man/man7/groff.7.gz , +where +.File_name /usr/share/man/ +is part of the man\~path, the subdirectory +.I man7 +and the file extension +.I .7 +refer to the man\~section 7; +.I .gz +shows the compression of the file. +. . .P -Preformatted man\~pages (cat\~pages) are intentionally excluded from -the search because groffer is a roff program that wants to format by -its own, not spit out stuff that was digested previously by someone -else. +The +.I cat\~pages +(preformatted man\~pages) are intentionally excluded from the search +because groffer is a roff program that wants to format by its own. . With the excellent performance of the actual computers, the preformatted man\~pages aren't necessary any longer. . -Due to their inflexible nature, they tend to provoke some trouble with -changing line lengths and different environments in networks. -. . .P The algorithm for retrieving man\~pages uses five search methods. @@ -2189,8 +2027,8 @@ language and system specific directories is used. The search can further be restricted by limiting it to certain sections. . -A single section can be specified within a filespec, several sections -as a colon-separated list in command line option +A single section can be specified within each filespec argument, +several sections as a colon-separated list in command line option .Opt_long sections or environment variable .Env_var $MANSECT . @@ -2216,7 +2054,7 @@ For further details on man\~page searching, see . . .\" -------------------------------------------------------------------- -.SS Decompression +.SH DECOMPRESSION .\" -------------------------------------------------------------------- . The program has a decompression facility. @@ -2372,7 +2210,7 @@ Usually, you do not want to set this environment variable. The groffer program internally calls groff, so all environment variables documented in .BR groff (@MAN1EXT@) -are internally used within groffer as well; see there for details. +are internally used within groffer as well. . The following variables have a direct meaning for the groffer program. . @@ -2386,7 +2224,7 @@ groffer uses it for storing its temporary files, just as groff does. .SS "Man Variables" .\" -------------------------------------------------------------------- . -Parts of the functionality of the man program were implemented in +Parts of the functionality of the man\~program were implemented in groffer; support for all environment variables documented in .BR man (1) was added to groffer, but the meaning was slightly modified due to the @@ -2457,7 +2295,7 @@ determined automatically. . . .\" -------------------------------------------------------------------- -.SH "FILES" +.SH "CONFIGURATION FILES" .\" -------------------------------------------------------------------- . The groffer program can be preconfigured by two configuration files. @@ -2470,12 +2308,12 @@ syntax. . . .TP -.CB /etc/groff/groffer.conf +.File_name /etc/groff/groffer.conf System-wide configuration file for groffer. . . .TP -.CB $HOME/.groff/groffer.conf +.File_name $HOME/.groff/groffer.conf User-specific configuration file for groffer, where .Env_var $HOME denotes the user's home directory. @@ -2500,10 +2338,11 @@ prepending should be preferred to appending and setting in order not to delete the environment variable provided by the . .Topic -Write functions for calling viewer programs in a special way and feed -them into the -.Opt_long \f[I]*\f[]-viewer -options. +Write a function for calling a viewer program for a special +.I mode +and feed this name into its corresponding +.Opt_long \f[I]mode\f[]\-viewer +option. . Note that the name of such a function must coincide with some existing program in the system path @@ -2528,6 +2367,7 @@ gxditview() { /usr/local/bin/gxditview --fg DarkBlue "$@"; } +GROFF_OPT="--x-viewer gxditview $GROFF_OPT"; .fi .hy .ft @@ -2536,17 +2376,29 @@ gxditview() .P This has the following effects: .Topic -allows to start groffer in a graphical mode even from a text -terminal; +allows to start groffer in a graphical mode (here on first running X +display by +.IR localhost:0.0 ) +even from a text terminal (empty +.Env_var $DISPLAY ); .Topic -all graphical modes use a resolution of 100 dpi where applicable; +all graphical modes use a resolution of +.I 100 dpi +where applicable; .Topic the .BR gxditview (@MAN1EXT@) program is told to use .I DarkBlue -as the text color. +as the text color by defining a shell function with the program's name +.Topic +force +.I gxditview +to be used in X mode by option +.Opt_long x\­viewer . . +. +.P These configurations can be overridden by command line options and by environment variable .Env_var $GROFFER_OPT . @@ -2581,9 +2433,9 @@ pager program when not in X. The arguments that are not existing files are looked-up as the following man\~pages: .I groff -(in section\~7), +(in man\~section\~7), .I groff -(automatic search, should be found in section\~1), +(automatic search, should be found in man\~section\~1), .I troff (in section\~1), and @@ -2605,11 +2457,13 @@ The formatted files are concatenated and displayed in one piece. .TP .Shell_cmd "LANG=de\~groffer\~--man\~--www\~--www-viever=netscape\~ls" . -Retrieve the German man\~page for the +Retrieve the German man\~page (language +.IR de ) +for the .B ls -program (or the English one if there is a German version), decompress -it, format it into the html format and view the result in the default -web browser +program (the English version is used if there is no German version), +decompress it, format it into the html format (www mode) and view the +result in the default web browser .I netscape . The option .Opt_long man @@ -2621,27 +2475,35 @@ exists in the actual directory. .TP .Shell_cmd "groffer\~-Q\~'man:roff(7)'" . -Print the unformatted content of the man\~page called +Get the man\~page called .I roff -in section 7 on standard output. +in man\~section 7 and print its unformatted content (source code +because of option +.Opt_short Q ) +on standard output. . . .TP -.Shell_cmd "groffer\~-Z\~-mfoo" +.Shell_cmd "cat\~file.gz\~|\~groffer\~-Z\~-mfoo" . Decompress the standard input, switch to .I groff -mode, format the input with groff using the macro package foo, but do -not postprocess the result, thus producing the intermediate output. +using macro package +.I foo +(groff option +.Opt_short m ) in non-postprocessing mode (groff option +.Opt_short Z ); +this produces the groff intermediate output, see +.BR groff_out (@MAN7EXT@). . . .TP .Shell_cmd "echo\~'\[rs]f[CB]WOW!'\~|" .TP+ -.Shell_cmd+ "groffer --x --bg red --fg yellow --geometry 200x100" +.Shell_cmd+ "groffer --x --bg red --fg yellow --geometry 200x100 -" . -Display \f[CB]WOW!\f[] in a small window in constant-width bold font, -using color yellow on red background. +Display the word \f[CB]WOW!\f[] in a small window in constant-width +bold font, using color yellow on red background. . . .\" -------------------------------------------------------------------- @@ -2677,7 +2539,7 @@ implementations of the POSIX shell: .BR ash (1), .BR bash (1), .BR ksh (1), -and POSIX +POSIX .BR sh (1), and others. . @@ -2693,30 +2555,71 @@ shell; so groffer tries to run under .I ash whenever possible. . -The procedure to determine the shell to run groffer was programmed to -be as follows: +If not available the shell under which the script was started in the +first place is used instead. +. +This can be modified by the option +.Opt_long shell . +. +. +.P +The groffer program provides its own parser for command line arguments +that is compatible to both POSIX +.BR getopts (1) +and GNU +.BR getopt (1). +. +The following usual types of options are supported. . . .Topic -the argument of the command line option -.Opt_long shell ; -if not set +A single minus always refers to single character options, for example, +.Opt_short Qmfoo +is equivalent to +.Opt_short Q\~\-m\~foo. +. . .Topic -the argument of the option -.Opt_long shell -in the environment variable -.Env_var $GROFF_OPT ; -if not set +Long options that means option with names longer than one character +are always prededed by a double minus; an option argument can either +go to the next command line argument or be appended with an equal sign +to the argument; for example, +.Opt_alt -- long=arg +is equivalent to +.Opt_alt -- long\~arg . +. . .Topic -try -.IR ash ; -if not available +An argument of +.Opt_-- +ends option parsing; all further command line arguments are +interpreted as filespec arguments. +. . .Topic -continue with the shell under which the script was started in the -first place. +By default, all command line arguments that are neither options nor +option arguments are interpreted as filespec parameters and stored +until option parsing has finished. +. +For example, the command line +.Shell_cmd "groffer file1 -a -o arg file2" +is, by default, equivalent to +.Shell_cmd "groffer -a -o arg -- file1 file2" +. +. +.P +This behavior can be changed by setting the environment variable +.Env_var $POSIXLY_CORRECT +to a non-empty value; in this case, option processing is stopped as +soon as the first non-option argument is found. +. +For example, in posixly correct mode, the command line +.Shell_cmd "groffer file1 -a -o arg file 2" +is equivalent to +.Shell_cmd "groffer -- file1 -a -o arg file 2" +As this leads to unwanted behavior in most cases, most people do not +want to set +.Env_var $POSIXLY_CORRECT . . . .\" -------------------------------------------------------------------- diff --git a/contrib/groff/contrib/groffer/groffer.sh b/contrib/groff/contrib/groffer/groffer.sh index 6cabefa..4e7332c 100644 --- a/contrib/groff/contrib/groffer/groffer.sh +++ b/contrib/groff/contrib/groffer/groffer.sh @@ -2,9 +2,9 @@ # groffer - display groff files -# File position: /contrib/groffer/groffer +# Source file position: /contrib/groffer/groffer.sh -# Copyright (C) 2001,2002 Free Software Foundation, Inc. +# Copyright (C) 2001,2002,2003 Free Software Foundation, Inc. # Written by Bernd Warken # This file is part of groff. @@ -29,8 +29,10 @@ export _PROGRAM_VERSION; export _LAST_UPDATE; _PROGRAM_NAME='groffer'; -_PROGRAM_VERSION='0.9.1'; -_LAST_UPDATE='30 Sep 2002'; +_PROGRAM_VERSION='0.9.4'; +_LAST_UPDATE='22 Jan 2003'; + +# This program is installed with groff version @VERSION@. ######################################################################## # Determine the shell under which to run this script; @@ -44,9 +46,7 @@ if test "${_groffer_run}" != 'second'; then export _groffer_run; export _this; - - #_this="@BINDIR@/${_PROGRAM_NAME}"; - _this='groffer.sh'; + _this="@BINDIR@/${_PROGRAM_NAME}"; ########################### # _get_opt_shell ("$@") @@ -217,7 +217,6 @@ _DEBUG_LM='no'; # disable landmark messages # base_name (path) # catz () # clean_up () -# clean_up_secondary () # diag (text>*) # dirname_append ( []) # dirname_chop () @@ -271,6 +270,8 @@ _DEBUG_LM='no'; # disable landmark messages # tmp_cat () # tmp_create (?) # to_tmp () +# trap_clean () +# trap_set () # usage () # version () # warning () @@ -366,9 +367,8 @@ _SQUOTE="'"; _TAB=' '; # function return values; `0' means ok; other values are error codes +export _ALL_EXIT; export _BAD; -export _BAD2; -export _BAD3; export _ERROR; export _GOOD; export _NO; @@ -377,9 +377,9 @@ export _YES; _GOOD='0'; # return ok _BAD='1'; # return negatively, error code `1' -_BAD2='2'; # return negatively, error code `2' -_BAD3='3'; # return negatively, error code `3' -_ERROR='255'; # for syntax errors; no `-1' in `ash' +_ERROR='7'; # for syntax errors; no `-1' in `ash' + +_ALL_EXIT="${_GOOD} ${_BAD} ${_ERROR}"; # all exit codes (for `trap_set') _NO="${_BAD}"; _YES="${_GOOD}"; @@ -492,8 +492,8 @@ _OPTS_GROFFER_LONG_ARG="'background' 'bd' 'bg' 'bw' 'default-modes' \ ##### options inhereted from groff -_OPTS_GROFF_SHORT_NA="'a' 'b' 'c' 'e' 'g' 'i' 'l' 'p' 's' 't' 'z' \ -'C' 'E' 'G' 'N' 'R' 'S' 'U' 'V'"; +_OPTS_GROFF_SHORT_NA="'a' 'b' 'c' 'C' 'e' 'E' 'g' 'G' 'i' 'l' 'N' 'p' \ +'R' 's' 'S' 't' 'U' 'V' 'z'"; _OPTS_GROFF_SHORT_ARG="'d' 'f' 'F' 'I' 'L' 'm' 'M' 'n' 'o' 'P' 'r' \ 'w' 'W'"; _OPTS_GROFF_LONG_NA=""; @@ -614,9 +614,9 @@ export _OPT_X; # groff option -X. export _OPT_XRM; # specify X resource. export _OPT_Z; # groff option -Z. # _TMP_* temporary files -export _TMP_DIR; # directory for temporary files +export _TMP_DIR; # groff directory for temporary files +export _TMP_DIR_SUB; # groffer directory for temporary files export _TMP_CAT; # stores concatenation of everything -export _TMP_PREFIX; # dir and base name for temporary files export _TMP_STDIN; # stores stdin, if any # these variables are preset in section `Preset' after the rudim. test @@ -674,8 +674,8 @@ _HAS_OPTS_POSIX=''; # _TMP_* temporary files _TMP_DIR=''; +_TMP_DIR_SUB=''; _TMP_CAT=''; -_TMP_PREFIX=''; _TMP_STDIN=''; @@ -790,19 +790,10 @@ landmark "1: debugging functions"; # clean_up() { - clean_up_secondary; - rm -f "${_TMP_CAT}"; -} - - -############## -# clean_up_secondary () -# -# Clean up temporary files without $_TMP_CAT. -# -clean_up_secondary() -{ - rm -f "${_TMP_STDIN}"; + if test -d "${_TMP_DIR}"; then + rm -f "${_TMP_DIR}"/*; + rmdir "${_TMP_DIR}"; + fi; } @@ -1044,9 +1035,9 @@ func_stack_dump() _rest="${_FUNC_STACK}"; while test "${_rest}" != ''; do # get part before the first bang `!'. - diag "$(echo -n "${_rest}" | sed -e 's/^\([^!]*\)!.*$/\1/')"; - # delete part up to the first bang `!'. - _rest="$(echo -n "${_rest}" | sed -e 's/^!*[^!]*!*//')"; + diag "$(echo -n "${_rest}" | sed -e 's/!.*$//')"; + # delete part before and including the first bang `!'. + _rest="$(echo -n "${_rest}" | sed -e 's/^[^!]*!//')"; done; ;; *) @@ -1219,8 +1210,8 @@ base_name() do_nothing; ;; */*) - # delete everything up to last slash `/'. - echo -n "$1" | sed -e '\|^.*/*\([^/]*\)$|s||\1|'; + # delete everything before and including the last slash `/'. + echo -n "$1" | sed -e '\|^.*//*\([^/]*\)$|s||\1|'; ;; *) echo -n "$1"; @@ -1280,14 +1271,6 @@ fi; ######################################################################## -# clean_up_secondary () -# -# Do the second but final cleaning up. -# -# defined above - - -######################################################################## # diag (*) # # Print marked message to standard error; useful for debugging. @@ -1926,7 +1909,7 @@ list_from_args() ######################################################################## -# list_from_cmdline ( [...]) +# list_from_cmdline ( [...]) # # Transform command line arguments into a normalized form. # @@ -2033,20 +2016,20 @@ list_from_cmdline() # get next short option from cluster (first char of $_rest) _optchar="$(echo -n "${_rest}" | sed -e 's/^\(.\).*$/\1/')"; # remove first character from ${_rest}; - _rest="$(echo -n "${_rest}" | 's/^.//')"; + _rest="$(echo -n "${_rest}" | sed -e 's/^.//')"; if list_has "${_short_n}" "${_optchar}"; then _result="$(list_append "${_result}" "-${_optchar}")"; continue; elif list_has "${_short_a}" "${_optchar}"; then # remove leading character case "${_optchar}" in - /) # cannot use normal `sed' separator + /) _rest="$(echo -n "${_rest}" | sed -e '\|^.|s|||')"; ;; ?) _rest="$(echo -n "${_rest}" | sed -e 's/^.//')"; ;; - *) + ??*) error "${_fn} several chars parsed for short option." ;; esac; @@ -2283,7 +2266,7 @@ man_do_filespec() local _spec; local _string; local s; - if is_empty "${MANPATH}"; then + if is_empty "${_MAN_PATH}"; then eval "${return_bad}"; fi; if is_empty "$1"; then @@ -2915,7 +2898,7 @@ if test "${_HAS_COMPRESSION}" = 'yes'; then { local _f; func_check save_stdin = 0 "$@"; - _f="$(tmp_create)"; + _f="${_TMP_DIR}"/INPUT; cat >"${_f}"; catz "${_f}" >"${_TMP_STDIN}"; rm -f "${_f}"; @@ -3007,9 +2990,9 @@ tmp_create() { func_check tmp_create '<=' 1 "$@"; local _tmp; - _tmp="${_TMP_PREFIX}${_PROCESS_ID}$1"; + _tmp="${_TMP_DIR}/$1"; echo -n >"${_tmp}"; - echo -n "${_tmp}"; + echo -n "${_tmp}"; # output file name eval "${return_ok}"; } @@ -3039,6 +3022,44 @@ to_tmp() ######################################################################## +# trap_clean () +# +# disable trap on all exit codes ($_ALL_EXIT) +# +# Arguments: 0 +# Globals: $_ALL_EXIT +# +trap_clean() +{ + func_check trap_clean = 0 "$@"; + local i; + for i in ${_ALL_EXIT}; do + trap "" "$i" 2>/dev/null || true; + done; + eval "${return_ok}"; +} + + +######################################################################## +# trap_set () +# +# call function on all exit codes ($_ALL_EXIT) +# +# Arguments: 1 (name of a shell function) +# Globals: $_ALL_EXIT +# +trap_set() +{ + func_check trap_set = 1 "$@"; + local i; + for i in ${_ALL_EXIT}; do + trap "$1" "$i" 2>/dev/null || true; + done; + eval "${return_ok}"; +} + + +######################################################################## # usage () # # print usage information to stderr @@ -3054,18 +3075,18 @@ This is free software licensed under the GNU General Public License. EOF - echo2 "Usage: ${_PROGRAM_NAME} ${_header} [option]... [filespec]..."; + echo2 "Usage: ${_PROGRAM_NAME} [option]... [filespec]..."; cat >&2 </dev/null || true; + trap_set clean_up; for f in ${_CONFFILES}; do if is_file "$f"; then @@ -3288,24 +3309,39 @@ main_init() done; # determine temporary directory + umask 000; + _TMP_DIR=''; for d in "${GROFF_TMPDIR}" "${TMPDIR}" "${TMP}" "${TEMP}" \ "${TEMPDIR}" "${HOME}"'/tmp' '/tmp' "${HOME}" '.'; do if test "$d" != ""; then if test -d "$d" && test -r "$d" && test -w "$d"; then - _TMP_DIR="$d"; - break; + _TMP_DIR="${d}/${_PROGRAM_NAME}${_PROCESS_ID}"; + if test -d "${_TMP_DIR}"; then + rm -f "${_TMP_DIR}"/*; + break; + else + mkdir "${_TMP_DIR}"; + if test ! -d "${_TMP_DIR}"; then + _TMP_DIR=''; + continue; + fi; + break; + fi; + fi; + if test ! -w "${_TMP_DIR}"; then + _TMP_DIR=''; + continue; fi; fi; done; unset d; - if test "${_TMP_DIR}" = ""; then - error "Couldn't find a directory for storing temorary files."; + if test "${_TMP_DIR}" = ''; then + error "Couldn't create a directory for storing temporary files."; fi; - _TMP_PREFIX="${_TMP_DIR}/${_PROGRAM_NAME}"; - _TMP_CAT="$(tmp_create)"; - _TMP_STDIN="$(tmp_create i)"; + _TMP_CAT="$(tmp_create groffer_cat)"; + _TMP_STDIN="$(tmp_create groffer_input)"; eval "${return_ok}"; } # main_init() @@ -3313,7 +3349,8 @@ main_init() ######################################################################## # main_parse_MANOPT () # -# Parse $MANOPT; this clobbered by the command line. +# Parse $MANOPT to retrieve man options, but only if it is a non-empty +# string; found man arguments can be overwritten by the command line. # # Globals: # in: $MANOPT, $_OPTS_MAN_* @@ -3327,7 +3364,14 @@ main_parse_MANOPT() local _opt; local _list; _list=''; - # feed in $MANOPT + if test "${MANOPT}" != ''; then + MANOPT="$(echo -n "${MANOPT}" | \ + sed -e 's/^'"${_SPACE}${_SPACE}"'*//')"; + fi; + if test "${MANOPT}" = ''; then + eval "${return_ok}"; + fi; + # add arguments in $MANOPT by mapping them to groffer options eval set -- "$(list_from_cmdline \ "${_OPTS_MAN_SHORT_NA}" "${_OPTS_MAN_SHORT_ARG}" \ "${_OPTS_MAN_LONG_NA}" "${_OPTS_MAN_LONG_ARG}" \ @@ -4042,7 +4086,7 @@ main_do_fileargs() _exitcode="${_GOOD}"; fi; done; - clean_up_secondary; + rm -f "${_TMP_STDIN}"; if is_equal "${_exitcode}" "${_BAD}"; then eval "${return_bad}"; fi; @@ -4185,7 +4229,7 @@ main_set_resources() # Globals: # in: $_DISPLAY_MODE, $_OPT_DEVICE, # $_ADDOPTS_GROFF, $_ADDOPTS_POST, $_ADDOPTS_X, -# $_REGISTERED_TITLE, $_TMP_PREFIX, $_TMP_CAT, +# $_REGISTERED_TITLE, $_TMP_CAT, # $_OPT_PAGER $PAGER $_MANOPT_PAGER # landmark '19: main_display()'; @@ -4218,7 +4262,7 @@ main_display() _ADDOPTS_GROFF="${_ADDOPTS_GROFF} -T${_OPT_DEVICE}"; fi; _groggy="$(tmp_cat | eval grog "${_options}")"; - trap "" EXIT 2>/dev/null || true; + trap_clean; # start a new shell program to get another process ID. sh -c ' set -e; @@ -4233,7 +4277,7 @@ main_display() { rm -f "${_modefile}"; } - trap clean_up EXIT 2>/dev/null || true; + trap clean_up 0 2>/dev/null || true; eval "${_groggy}" "${_ADDOPTS_GROFF}"; ) &' ;; @@ -4293,7 +4337,7 @@ main_display() ;; esac; _groggy="$(tmp_cat | grog -Tps)"; - trap "" EXIT 2>/dev/null || true; + trap_clean; # start a new shell program to get another process ID. sh -c ' set -e; @@ -4313,7 +4357,7 @@ main_display() { rm -f "${_modefile}"; } - trap clean_up EXIT 2>/dev/null || true; + trap clean_up 0 2>/dev/null || true; eval "${_DISPLAY_PROG}" ${_DISPLAY_ARGS} "${_modefile}"; ) &' ;; @@ -4370,8 +4414,9 @@ main_display() _do_display() { - trap "" EXIT 2>/dev/null || true; - # start a new shell program to get another process ID. + trap_clean; + # start a new shell program for another process ID and better + # cleaning-up of the temporary files. sh -c ' set -e; _PROCESS_ID="$$"; @@ -4383,9 +4428,12 @@ _do_display() ( clean_up() { - rm -f "${_modefile}"; + if test -d "${_TMP_DIR}"; then + rm -f "${_TMP_DIR}"/*; + rmdir "${_TMP_DIR}"; + fi; } - trap clean_up EXIT 2>/dev/null || true; + trap clean_up 0 2>/dev/null || true; eval "${_DISPLAY_PROG}" ${_DISPLAY_ARGS} "${_modefile}"; ) &' } diff --git a/contrib/groff/contrib/mm/ChangeLog b/contrib/groff/contrib/mm/ChangeLog index 3033a1f..d678fe8 100644 --- a/contrib/groff/contrib/mm/ChangeLog +++ b/contrib/groff/contrib/mm/ChangeLog @@ -1,3 +1,33 @@ +Wed Apr 06:42:35 2003 Joergen Haegg + + * the footer was not adjusted by VM due to a missing + pg*extra-footer-size in the calculation of pg*last-pos + +Wed Apr 06:04:58 2003 Joergen Haegg + + * space adjustments in 4.MT to make it more like + the original + +Sun Mar 21:45:10 2003 Joergen Haegg + + * removed error check i 4.MT, .AF is not mandatory anymore + +Sat Mar 21:56:57 2003 Joergen Haegg + + * cov*firm now defined only if arg to AF is non-empty + That will also enable cov*default-firm from the mm locale-file + to work. + +Sat Mar 21:05:29 2003 Joergen Haegg + + * added .ll in pg@set-env to initialize the + header environment properly + +Wed Mar 19 23:02:16 2003 Werner LEMBERG + + * groff_mm.man: Some fixes from Robert D. Goulding + . + Wed Sep 09:53:06 2002 Joergen Haegg * added implicit -mm to mmroff, it's now possible diff --git a/contrib/groff/contrib/mm/groff_mm.man b/contrib/groff/contrib/mm/groff_mm.man index 2bb9e10..8229f23 100644 --- a/contrib/groff/contrib/mm/groff_mm.man +++ b/contrib/groff/contrib/mm/groff_mm.man @@ -1,5 +1,5 @@ .\" -.\" $Id: groff_mm.man,v 2.8 2002/05/30 05:39:54 jhaegg Exp $ +.\" $Id: groff_mm.man,v 2.9 2003/03/19 22:05:11 wlemb Exp $ .\" .de T2 .if t .ne 2v @@ -1654,8 +1654,8 @@ Floating displays does not generate line break. A string containing the word "APPENDIX". .TP .B Apptxt -.TP The current appendix text. +.TP .B "EM" Em dash string .TP @@ -1673,11 +1673,11 @@ Normally "0 0 0 0 0 0 0" which is the same as "10 10 10 10 10 10 10". .TP .B Index -.TP Contains \fIINDEX\fP. -.B Indcmd .TP +.B Indcmd Contains the index command, \fIsort\ -t\et\fP. +.TP .B Lifg String containing \fIFigure\fP. .TP @@ -1845,10 +1845,10 @@ Append a dot after the level one heading number if >\ 0. Default is\ 1. .TP .B H1h -.TP Copy of number register \fBH1\fP, but it is incremented just before the page break. Useful in user defined header macros. +.TP .B Hb Heading break level [0:7], default\ 2. .TP @@ -1866,7 +1866,7 @@ Heading temporary indent [0:2], default\ 1. 2\ ->\ indent to line up with text part of preceding heading .TP .B Hps -Numbervariable with the heading pre-space level. +Number variable with the heading pre-space level. If the heading-level is less than or equal to \fBHps\fP, then two lines will precede the section heading instead of one. diff --git a/contrib/groff/contrib/mm/m.tmac b/contrib/groff/contrib/mm/m.tmac index 143867d..f785191 100644 --- a/contrib/groff/contrib/mm/m.tmac +++ b/contrib/groff/contrib/mm/m.tmac @@ -3,8 +3,8 @@ .ds RE \\$2 .. .\" -.\" $Id: m.tmac,v 2.15 2002/08/07 23:23:34 wlemb Exp $ -.@revision $Revision: 2.15 $ +.\" $Id: m.tmac,v 2.18 2003/04/02 04:44:59 jhaegg Exp $ +.@revision $Revision: 2.18 $ .ig Copyright (C) 1991-2000 Free Software Foundation, Inc. @@ -1130,8 +1130,8 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .\" .\" last-pos points to the position of the footer and bottom .\" block below foot-notes. -.nr pg*last-pos \\n[@pl]u-(\\n[pg*block-size]u+\\n[pg*foot-margin]u+\\n[pg*footer-size]u) -.if \\n[D]>2 .tm pg*last-pos \\n[@pl]u-(\\n[pg*block-size]u+\\n[pg*foot-margin]u+\\n[pg*footer-size]u) = \\n[pg*last-pos] +.nr pg*last-pos \\n[@pl]u-(\\n[pg*block-size]u+\\n[pg*foot-margin]u+\\n[pg*footer-size]u+\\n[pg*extra-footer-size]u) +.if \\n[D]>2 .tm pg*last-pos \\n[@pl]u-(\\n[pg*block-size]u+\\n[pg*foot-margin]u+\\n[pg*footer-size]u+\\n[pg*extra-footer-size]u) = \\n[pg*last-pos] .. .de pg@enable-trap .wh \\n[pg*foot-trap]u pg@footer @@ -1246,7 +1246,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .\" FOOTER .de pg@footer .ec -.if \\n[D]>2 .tm Footer# \\n[%] (\\n[.F]:\\n[c.]) +.if \\n[D]>2 .tm Footer# \\n[%] (\\n[.F]:\\n[c.]) nl=\\n[nl] .pg@disable-trap .\".debug footer .tbl@bottom-hook @@ -1254,7 +1254,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .\" move to the exact start of footer. 'sp |\\n[pg*foot-trap]u+1v .\" -.if \\n[D]>3 .tm FOOTER after .sp +.if \\n[D]>3 .tm FOOTER after .sp, nl=\\n[nl] .\" print footnotes .if d ft*div .ft@print .\" @@ -1269,6 +1269,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .de pg@print-footer .\" jump to the position just below the foot-notes. 'sp |\\n[pg*last-pos]u+1v +.if \\n[D]>3 .tm print-footer nl=\\n[nl] .\" check if there are any bottom block .if d pg*block-div .pg@block .\" @@ -1311,6 +1312,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] . vs \\n[pg*vs]u .\} .lt \\n[@ll]u +.ll \\n[@ll]u .. .\"------------------------- .de PH @@ -2959,7 +2961,7 @@ in=\\n[.i] fi=\\n[.u] .d=\\n[.d] nl=\\n[nl] pg=\\n[%] .\"------------------- .de AF .cov@title-end -.ds cov*firm \\$1 +.if !''\\$1' .ds cov*firm \\$1 .. .de AST .ds cov*abs-name \\$1 diff --git a/contrib/groff/contrib/mm/mm/4.MT b/contrib/groff/contrib/mm/mm/4.MT index c8b6f37..78c7766 100644 --- a/contrib/groff/contrib/mm/mm/4.MT +++ b/contrib/groff/contrib/mm/mm/4.MT @@ -1,11 +1,11 @@ .\"------------ -.\" $Id: 4.MT,v 2.0 2000/09/14 03:40:25 jhaegg Exp $ +.\" $Id: 4.MT,v 2.2 2003/04/02 04:06:40 jhaegg Exp $ .\" Cover sheet. Memorandum type 4 .\"------------ .de cov@print-title .if !d cov*title .@error title (.TL) not defined! -.MOVE 2.4c -.S +4 +.MOVE 2.8c +.S +2 .ad c .fi .B @@ -14,27 +14,28 @@ .S .R .ad b -.PGFORM .. .\"------------ .de cov@print-authors .SP 0.5 .I +.S +1 .nr cov*i 0 1 .while \\n+[cov*i]<=\\n[cov*au] \{\ .ce \\*[cov*au!\\n[cov*i]!1] .br .\} +.S .R -.PGFORM .. .\"------------ .de cov@print-firm -.if !d cov*firm .@error firm (.AF) not defined! -.SP 0.5 -.ce +.if d cov*firm \{\ +. SP 0.5 +. ce \\*[cov*firm] +.\} .. .\"------------ .de cov@print-abstract @@ -64,7 +65,7 @@ . if d cov*abstract \{\ . if !\n[cov*abs-arg] .cov@print-abstract . \} -. SP 3 +. SP 2 . nr hd*cur-bline \n[nl] . ds cov*mt-printed . pg@enable-top-trap diff --git a/contrib/groff/contrib/mom/BUGS b/contrib/groff/contrib/mom/BUGS index 92d4b47..a96c061 100644 --- a/contrib/groff/contrib/mom/BUGS +++ b/contrib/groff/contrib/mom/BUGS @@ -11,9 +11,27 @@ questions and suggestions, or contact me directly at: ======================================================================== -Version 1.1.3c -============== +Version 1.1.5 +============= + +Draft and revision not appearing in page headers. +---Fixed--- + +\*[RULE] not working properly with indents and justified copy. +---Fixed--- + +Post-epigraph spacing in TYPEWRITE causing some first pages to run too +deep. +---Fixed--- + +Spacing of docheaders in TYPEWRITE not always consistent. +---Fixed--- +Version 1.1.4 +============= + +Blockquotes that span pages running too deep. +---Fixed--- Version 1.1.3 ============= diff --git a/contrib/groff/contrib/mom/ChangeLog b/contrib/groff/contrib/mom/ChangeLog index d1e0fd1..ce93092 100644 --- a/contrib/groff/contrib/mom/ChangeLog +++ b/contrib/groff/contrib/mom/ChangeLog @@ -1,3 +1,43 @@ +*Sun Feb 16 2003 + +o Added James Ramsey's proposed CHAPTER_TITLE macro, along with his + rewritten START macro and his utility macros to make START easier + to read. + +o Expanded handling of CHAPTER_TITLE to encompass TYPEWRITE, as well as + plugging it into the docheaders. Made CHAPTER_TITLE backwardly + compatible so that pre-1.1.5 docs using CHAPTER_STRING to create a + chapter title remain unaffected when groffed with 1.1.5. + +o Created control macros for CHAPTER_TITLE FAMILY, FONT and SIZE. + Added defaults for handling of CHAPTER title to DEFAULTS. Documented + CHAPTER_TITLE and everything that goes along with it. + +o Fixed broken draft and revision in headers/footers. + +o Fixed \*[RULE] so that it behaves properly with indents and justified + copy. + +o Fixed/tweaked handling of epigraph spacing in TYPEWRITE. + +o Fixed broken spacing of docheaders in TYPEWRITE. + +*Mon Feb 3 2003 + +o Fixed an oversight in CLOSING for DOCTYPE LETTER (closing wasn't + being set flush left) + +*Sun Sep 29 2002 + +o Changed .ne in .HEAD when PRINTSTYLE TYPESET from 5 to 4. With 5, + heads required at least 2 lines of text underneath or they'd be + defered to the next page, which created too much whitespace at the + end of the page. Heads will now be processed on the same page if the + head plus at least one line of text underneath fits. I figure it's + easier for the user to break to a new page manually if this behaviour + is unsatisfactory than to massage the page to fix the excess + whitespace. + *Sun Aug 25 2002 o Changed .IX to .IQ. The older form still works, but emits a message diff --git a/contrib/groff/contrib/mom/Makefile.sub b/contrib/groff/contrib/mom/Makefile.sub index 881c052..f066153 100644 --- a/contrib/groff/contrib/mom/Makefile.sub +++ b/contrib/groff/contrib/mom/Makefile.sub @@ -1,4 +1,4 @@ -# Copyright (C) 2002 Free Software Foundation, Inc. +# Copyright (C) 2002, 2003 Free Software Foundation, Inc. # Written by Werner Lemberg (wl@gnu.org) # # This file is part of groff. @@ -17,20 +17,23 @@ # with groff; see the file COPYING. If not, write to the Free Software # Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +# These may be overridden if cross-compiling. +GROFFBIN=$(top_builddir)/src/roff/groff/groff +GROFF_BIN_PATH=`echo $(groff_bin_dirs) | sed -e 's| *|:|g'` + groff_bin_dirs=\ $(top_builddir)/src/roff/groff \ $(top_builddir)/src/roff/troff \ $(top_builddir)/src/devices/grops -groff_bin_path=`echo $(groff_bin_dirs) | sed -e 's| *|:|g'` FFLAG=-F$(top_builddir)/font -F$(top_srcdir)/font TFLAG=-M$(top_builddir)/tmac -M$(top_srcdir)/tmac -M$(srcdir) GROFF=GROFF_COMMAND_PREFIX=''; \ export GROFF_COMMAND_PREFIX; \ - GROFF_BIN_PATH=$(groff_bin_path); \ + GROFF_BIN_PATH=$(GROFF_BIN_PATH); \ export GROFF_BIN_PATH; \ - $(top_builddir)/src/roff/groff/groff $(FFLAG) $(TFLAG) + $(GROFFBIN) $(FFLAG) $(TFLAG) MAN7=\ groff_mom.n diff --git a/contrib/groff/contrib/mom/NEWS b/contrib/groff/contrib/mom/NEWS index 0572603..d4ca87f 100644 --- a/contrib/groff/contrib/mom/NEWS +++ b/contrib/groff/contrib/mom/NEWS @@ -1,3 +1,29 @@ +Release 1.1.5 +------------- + +***NEW*** + +Added James Ramsey's CHAPTER_TITLE macro as well as control macros to +go with it. Thanks James. Also from James came a patch to handle +START differenty which has been incorporated into om.tmac. Thanks +again, James. + +Some bits and pieces of the docs have been tweaked, but nothing +changed. Hopefully, the changes will make parts of the docs easier to +read and navigate. + +***FIXES*** + +o \*[RULE] + +o broken draft and revision in docheaders + +o post-epigraph spacing in TYPEWRITE + +o header spacing in TYPEWRITE + +------------------------------------------------------------------------ + Release 1.1.4 ------------- diff --git a/contrib/groff/contrib/mom/examples/elvis_syntax b/contrib/groff/contrib/mom/examples/elvis_syntax index 14f7049..02b91a4 100644 --- a/contrib/groff/contrib/mom/examples/elvis_syntax +++ b/contrib/groff/contrib/mom/examples/elvis_syntax @@ -7,8 +7,8 @@ keyword .ALD .ALIAS .ALWAYS_FULLSPACE_QUOTES .ATTRIBUTE_STRING keyword .AUTHOR .AUTHOR_FAMILY .AUTHOR_FONT .AUTHOR_SIZE .AUTOLEAD keyword .BLOCKQUOTE .BLOCKQUOTE_FAMILY .BLOCKQUOTE_FONT .BLOCKQUOTE_QUAD .BLOCKQUOTE_SIZE keyword .B_MARGIN .BR .BR_AT_LINE_KERN .BREAK_QUOTE -keyword .CAPS .CENTER .CENTRE .CHAPTER -keyword .CHAPTER_STRING .CITATION .CITE .CLOSING +keyword .CAPS .CENTER .CENTRE +keyword .CHAPTER .CHAPTER_TITLE CHAPTER_STRING .CITATION .CITE .CLOSING keyword .COLLATE .COL_BREAK .COL_BREAK .COL_NEXT .COLUMNS keyword .COMMENT .CONDENSE .COPYSTYLE keyword .DATE .DEFAULTS diff --git a/contrib/groff/contrib/mom/examples/typeset.mom b/contrib/groff/contrib/mom/examples/typeset.mom index 972acc5..98dd918 100644 --- a/contrib/groff/contrib/mom/examples/typeset.mom +++ b/contrib/groff/contrib/mom/examples/typeset.mom @@ -137,9 +137,10 @@ sit amet. Accusam et justo duo do\%lo\%res et ea rebum \# a collated document, but if the page trap has already deposited one \# there, COLLATE can't undo it. Hence, we turn the trap off \# (TRAP OFF), set the line, and put in an EL afterwards. +\# \# Normally, all this isn't necessary when collating documents, \# but if you ever have the problem of a page header printing at the -\# top of a collated document, this is how you get around it. +\# top of a collated document, now you know how to get around it. \# .TRAP OFF .RIGHT @@ -405,11 +406,11 @@ justo duo do\%lo\%res et ea rebum. Sanctus est lorem ipsum dolor sit amet, consetetur sadipscing. Elitr, sed diam nonumy eirmod tempor, invidunt ut labore et do\%lo\%re magna ali\%quyam. Erat sed diam voluptua, at vero eos et accusam et justo -duo do\%lo\%res et ea rebum amet. Consetetur sadipsc- +duo do\%lo\%res et ea rebum amet. Consetetur sadipsc\% +ing elitr sed diam nonumy eirmod tempor invidunt ut .BREAK_QUOTE \" Needed because blockquote crosses page AND contain footnotes -ing elitr sed diam nonumy eirmod tempor invidunt ut labore. -Et do\%lo\%re magna ali\%quyam erat, sed diam voluptua, at vero. -Eos et accusam et justo duo.\c +labore. Et do\%lo\%re magna ali\%quyam erat, sed diam voluptua, at +vero. Eos et accusam et justo duo.\c .FOOTNOTE Labore et do\%lo\%re magna ali\%quyam erat sed diam voluptua. .FOOTNOTE OFF diff --git a/contrib/groff/contrib/mom/momdoc/docelement.html b/contrib/groff/contrib/mom/momdoc/docelement.html index 2b9a535..e1db2ab 100644 --- a/contrib/groff/contrib/mom/momdoc/docelement.html +++ b/contrib/groff/contrib/mom/momdoc/docelement.html @@ -763,7 +763,9 @@ in the string(s) you pass to HEAD For example,

-	.HEAD "\[ALD3]Text of head
+	.HEAD "\[ALD3]Text of head"
+        or
+    .HEAD "\[DOWN 3p]Text of head"
 
will lower the baseline of the head by three points. Note that @@ -774,6 +776,8 @@ the escape in the string for each line, like this:

 	.HEAD "\[ALD3]First line" "\[ALD3]Next line" 
+        or
+    .HEAD "\[DOWN 3p]First line" "\[DOWN 3p]Next line" 
 
@@ -880,7 +884,7 @@ the next in ascending order (i.e. the last subhead number + 1), invoke Your next subhead will be numbered "4" and subsequent subheads will be numbered in ascending order from "4". -

Vertical inline escapes inside subheads

+

Vertical inline escapes inside subheads

See Vertical inline escapes inside heads. The information there applies equally to subheads. diff --git a/contrib/groff/contrib/mom/momdoc/docprocessing.html b/contrib/groff/contrib/mom/momdoc/docprocessing.html index 4c8b1f0..0447537 100644 --- a/contrib/groff/contrib/mom/momdoc/docprocessing.html +++ b/contrib/groff/contrib/mom/momdoc/docprocessing.html @@ -675,7 +675,8 @@ She also puts the same thing in the middle of

If you're not using DOCTYPE CHAPTER, the macro serves no purpose and mom ignores it. - +

+CHAPTER_STRING

If you're not writing in English, you can ask mom to use the word for chapter in your own language by telling @@ -688,8 +689,42 @@ like this: You can also use CHAPTER_STRING if you want "CHAPTER" instead of "Chapter" in the doc- and -page-headers. (See also the -Special Note on CHAPTER.) +page-headers. +
+ + + +


+

+ +Macro: CHAPTER_TITLE "<chapter title>" + +

+If, either in addition to or instead of "Chapter #" appearing +at the top of chapters, you want your chapter to have a title, use +CHAPTER_TITLE with your title enclosed in +double-quotes, like this: +

+

+	.CHAPTER_TITLE "The DMCA Nazis"
+
+ +If you've used +CHAPTER to give the chapter a number, +"Chapter #" and the title will appear at the top of the +chapter, like this: +

+

+                       Chapter 1
+                    The DMCA Nazis
+
+ +In such a case, by default, only the chapter's title will appear in the +page headers, not "Chapter #". +

+If you omit CHAPTER when setting up your reference +macros, only the title will appear, both at the top of page one and in +subsequent page headers.
@@ -710,13 +745,16 @@ default), mom ignores DRAFT. Mom prints the draft number beside the word "Draft" in the middle part of page headers. +

+DRAFT STRING +

If you're not writing in English, you can ask mom to use the word for draft in your own language by telling her what it is with the DRAFT_STRING macro, like this:

-	.DRAFT_STRING "Ébauche"
+	.DRAFT_STRING "Jet"
 
@@ -738,6 +776,9 @@ accepts a Mom prints the revision number beside the shortform "Rev." in the middle part of page headers. +

+REVISION STRING +

If you're not writing in English, you can ask mom to use the word for revision, or a shortform therof in your own language by telling her what it is with the REVISION_STRING @@ -807,24 +848,30 @@ for how mom's outputs each part of the page header.)

CHAPTER prints "Chapter #" in place of a docheader -(# is what you gave to -CHAPTER), -or, if you omit the CHAPTER macro and give the chapter -a title with -CHAPTER_STRING, -mom prints the chapter title. Page headers contain the -author, the title of the book (which you gave with +(# is what you gave to the +reference macro +CHAPTER). +If you give the chapter a title with +CHAPTER TITLE, +mom prints "Chapter #" and the title +underneath. If you omit the CHAPTER reference +macro but supply a +CHAPTER_TITLE, +mom prints only the chapter title. (*For +backward compatability with pre-1.1.5 versions of +mom, you can also supply a chapter title by +ommitting the CHAPTER reference macro and +supplying a chapter title with +CHAPTER_STRING. +

+The page headers in DOCTYPE CHAPTER contain the author, +the title of the book (which you gave with TITLE), and "Chapter #" (or the chapter title). See Default Specs for Headers for mom's default type parameters for each part of the page header.

-*See the -Special Note on CHAPTER -below for how you can make DOCTYPE CHAPTER print something -other than "Chapter #" as its docheader. -

NAMED takes an additional argument: a name for this particular kind of document (e.g. outline, synopsis, abstract, memorandum), enclosed in double-quotes. @@ -841,35 +888,6 @@ for how mom's outputs each part of the page header.) the section Writing Letters for instructions on using mom to format letters. - -

Special Note on CHAPTER

-In novels, new chapters are generally (but not always) -introduced by "Chapter #". Other types of documents -(reports and so on) often require specific titles for chapters. -If your document is of this latter type, use DOCTYPE -CHAPTER in the following way: -
-
    -
  1. Omit the - reference macro - CHAPTER -
  2. Invoke - .CHAPTER_STRING - with the title you'd like the chapter to have (enclosed - in double-quotes, of course). -
-

-Here's a recipe for setting up a chapter entitled "The DMCA -Nazis". -

-	.AUTHOR "Outraged Hacker"
-	.TITLE  "Limiting Copyright"
-	\#
-	.DOCTYPE    CHAPTER
-	.PRINTSTYLE TYPESET
-	\#
-	.CHAPTER_STRING "The DMCA Nazis"
-

@@ -1123,7 +1141,7 @@ adjusted to fill pages fully to the bottom margin.
-

Using typesetting macros prior to START

+

Using the typesetting macros prior to START

When used before the START @@ -1306,6 +1324,15 @@ compensate: (Document type) bold italic, underscored, 3 points larger than running text +If the +DOCTYPE +is CHAPTER, +
+	   Chapter #       bold, 4 points larger than running text
+	 Chapter Title     bold italic, 4 points larger than running text
+
+ +

The family is the prevailing family of the whole document. @@ -1313,7 +1340,7 @@ is the prevailing family of the whole document.

The docheader macros to:

  1. Change the starting position -
  2. Adjust the leading +
  3. Adjust the docheader leading
  4. Change the family of docheader elements
  5. Change the font of docheader elements
  6. Adjust the size of docheader elements @@ -1357,9 +1384,14 @@ to place them where you want.

    2. Adjust the leading

    The leading of -docheaders is the same as running text. If you'd like a -different leading, say, 2 points more than the lead of running -text, use: +docheaders is the same as running text (except when +DOCTYPE +is CHAPTER and both a chapter number and a +chapter title have been supplied, in which case the default is 4 points +more than running text.) +

    +If you'd like your docheaders to have a different leading, say, 2 +points more than the lead of running text, use:

     	.DOCHEADER_LEAD +2p
    @@ -1378,6 +1410,7 @@ of each docheader element separately:
     

    • TITLE_FAMILY <family> +
    • CHAPTER_TITLE_FAMILY <family>
    • SUBTITLE_FAMILY <family>
    • AUTHOR_FAMILY <family>
    • DOCTYPE_FAMILY <family> (if @@ -1393,6 +1426,7 @@ of each docheader element separately:

      • TITLE_FONT R | B | I | BI +
      • CHAPTER_TITLE_FONT R | B | I | BI
      • SUBTITLE_FONT R | B | I | BI
      • AUTHOR_FONT R | B | I | BI
      • DOCTYPE_FONT R | B | I | BI (if @@ -1410,8 +1444,8 @@ The following macros let you adjust the point size of each docheader element separately.

        Mom calculates the point size -of docheader elements from the point size of paragraphs, so you -must prepend a + or - sign to the argument. Points is +of docheader elements from the point size of paragraphs in running +text, so you must prepend a + or - sign to the argument. Points is assumed as the unit of measure, so there's no need to append a unit to the argument. Fractional point @@ -1421,6 +1455,9 @@ sizes are allowed.

      • TITLE_SIZE <+/-points>
        default = +3.5 (+4 if docheader title is "Chapter #") +
      • CHAPTER_TITLE_SIZE <+/-points> +
        +default = +4
      • SUBTITLE_SIZE <+/-points>
        default = +0 @@ -1436,6 +1473,7 @@ default = +3 Simply pass the appropriate macro the size adjustment you want.

        6. Change the attribution string ("by")

        +

        If you're not writing in English, you can change what mom prints where "by" appears in docheaders. For example, @@ -1582,7 +1620,7 @@ or (god help us) an epigraph, you must do the following in order for -

        Initiate document processing

        +

        Start document processing

        In order to use mom's document element macros diff --git a/contrib/groff/contrib/mom/momdoc/goodies.html b/contrib/groff/contrib/mom/momdoc/goodies.html index c95e733..8876966 100644 --- a/contrib/groff/contrib/mom/momdoc/goodies.html +++ b/contrib/groff/contrib/mom/momdoc/goodies.html @@ -552,6 +552,7 @@ When the line is output, the space remaining on the line, after account, is split into four (because there are four # signs). One quarter of the space is inserted between Date and Signature, the remainder is inserted after Signature. +

        One rarely wants merely to insert space in a line; one usually wants to fill it with something, hence PAD is diff --git a/contrib/groff/contrib/mom/momdoc/inlines.html b/contrib/groff/contrib/mom/momdoc/inlines.html index 99cfaf7..2d8aa82 100644 --- a/contrib/groff/contrib/mom/momdoc/inlines.html +++ b/contrib/groff/contrib/mom/momdoc/inlines.html @@ -344,6 +344,22 @@ example:

    The above draws a rule the full measure of the 6-pica line length. +Please note that \*[$RULE] should appear on a line by +itself and that it draws the rule to the full measure, hence it +cannot be used to fill the remainder of a partial line with +a rule in this way: +

    +

    +	Signature__________________________________________
    +
    + +If you wish to accomplish this effect, you have to use +\*[RULE] in conjunction with the +PAD +macro and +string tabs. +(See the example provided with +.PAD.

    See groff's Horizontal line drawing function diff --git a/contrib/groff/contrib/mom/momdoc/intro.html b/contrib/groff/contrib/mom/momdoc/intro.html index e21fa3c..40c306d 100644 --- a/contrib/groff/contrib/mom/momdoc/intro.html +++ b/contrib/groff/contrib/mom/momdoc/intro.html @@ -179,7 +179,7 @@ text editor as they are on the printed page.

    Unfortunately, in computerland, "easy," "comprehensible," and "readable" often mean -"you're stuck with what you're get." No document formatting +"you're stuck with what you get." No document formatting system can give you exactly what you want all the time, every time. Documents, it seems, always need to be tweaked, either to satisfy a typographic whim or to clarify some aspect of their content. diff --git a/contrib/groff/contrib/mom/momdoc/reserved.html b/contrib/groff/contrib/mom/momdoc/reserved.html index 029556d..193b56d 100644 --- a/contrib/groff/contrib/mom/momdoc/reserved.html +++ b/contrib/groff/contrib/mom/momdoc/reserved.html @@ -212,6 +212,7 @@ p Output line horiz position at end of $PAD_STRING #Q_AT_TOP Does a quote start at the top of a new page? (toggle) #QUAD In autoquad mode? (toggle) #RESTORE_LEAD Lead value in effect prior to AUTOLEAD +#RESTORE_LINE_LENGTH Restores actual line length in RULE #RESTORE_PT_SIZE Stores current point size (in units) prior to underscore #R_INDENT Value of right indent #RLD RLD value @@ -242,6 +243,7 @@ u Horiz position of start of underscore +++STRINGS+++ $COND_PERCENT Percentage by which to pseudo-condense type +$CURRENT_QUAD Restores current quad value in RULE $CURRENT_TAB Current tab number $DC_ADJUST +|- # of points to subtract from dropcap $DC_FAM Drop cap family @@ -352,12 +354,13 @@ DOCUMENT PROCESSING Document info ------------- -AUTHOR Author -CHAPTER Chapter number -DRAFT Draft number -REVISION Revision number -SUBTITLE Doc subtitle -TITLE Doc title +AUTHOR Author +CHAPTER Chapter number +CHAPTER_TITLE Chapter title +DRAFT Draft number +REVISION Revision number +SUBTITLE Doc subtitle +TITLE Doc title Document style -------------- @@ -408,6 +411,9 @@ BLOCKQUOTE_FONT Font to use in blockquotes BLOCKQUOTE_QUAD How to quad blockquotes BLOCKQUOTE_SIZE How much to de/increase point size of bquotes CHAPTER_STRING What to print whenever the word "chapter" is required +CHAPTER_TITLE_FAMILY Family to use for chapter title in doc header +CHAPTER_TITLE_FONT Font to use for chapter title in doc header +CHAPTER_TITLE_SIZE ps in/decrease of chapter title (relative to size of running text) COLUMNS Print in columns DOC_FAMILY Overall doc family DOCHEADER_ADVANCE Start position of docheader (relative to top of page) @@ -608,7 +614,6 @@ TRAPS Sets hdrftr traps; optionally adjusts #DOC_LEAD to fill pag #CAP_HEIGHT_ADJUST Tallest cap height of strings LEFT, CENTER, and RIGHT in footers; used to place rule over footer #CAPS_WAS_ON In HDRFTR, to re-enable running text CAPS (toggle) #CENTER_CAP_HEIGHT Cap height of center string in headers/footers -#CHAPTER The chapter number #CLOSING Is there a closing (for letters)? 1=yes #COL_L_LENGTH Line length of columns #COL_NEXT Was COL_NEXT invoked? (toggle; used in FOOTER) @@ -801,12 +806,19 @@ $AUTHOR_1...9 Document author(s) $AUTHOR_FAM Family to use for author in doc header $AUTHOR_FT Font to use for author in doc header $AUTHOR_SIZE_CHANGE ps in/decrease of author in doc header* +$AUTHOR_PT_SIZE Absolute ps of authors $BQUOTE_FAM Family to use for blockquotes $BQUOTE_FT Font to use for blockquotes $BQUOTE_QUAD Quad value for blockquotes $BQUOTE_SIZE_CHANGE ps in/decrease of blockquotes* $CENTER_TITLE What to put in the middle of header title +$CHAPTER The chapter number $CHAPTER_STRING What to print whenever the word "chapter" is required +$CHAPTER_TITLE Chapter title (if there is one) +$CHAPTER_TITLE_FAM Family of chapter title +$CHAPTER_TITLE_FT Font of chapter title +$CHAPTER_TITLE_SIZE_CHANGE ps in/decrease of chapter title* +$CHAPTER_TITLE_PT_SIZE Absolute ps of chapter title $COPY_STYLE DRAFT or FINAL $DOC_FAM Predominant font family used in the document $DOC_QUAD Quad used for body text (justified or left) @@ -814,6 +826,7 @@ $DOC_TYPE Document type (default, chapter, named, letter) $DOCTYPE_FAM Family to use for DOCTYPE string in doc header $DOCTYPE_FT Font to use for DOCTYPE string in doc header $DOCTYPE_SIZE_CHANGE ps in/decrease of DOCTYPE string in doc header* +$DOCTYPE_PT_SIZE Absolute ps of DOCTYPE $DRAFT_STRING What to print whenever the word "draft" is required $EN_FAMILY Family for endnotes $EN_FT Font for endnotes @@ -880,11 +893,13 @@ $SH_SIZE_CHANGE ps in/decrease of subheads* $SUBTITLE Document subtitle $SUBTITLE_FAM Family to use for subtitle in doc header $SUBTITLE_FT Font to use for subtitle in doc header -$SUBTITLE_SIZE_CHANGE Font to use for subtitle in doc header +$SUBTITLE_SIZE_CHANGE ps in/decrease of subtitle* +$SUBTITLE_PT_SIZE Absolute ps of subtitle $SUITE The #SUITE number register $TITLE Document title $TITLE_FAM Family to use for title in doc header $TITLE_FT Font to use for title in doc header +$TITLE_PT_SIZE Absolute point size of title in docheader $TITLE_SIZE_CHANGE ps in/decrease of title in doc header* $USERDEF_HDRFTR_RECTO User defined header/footer recto string $USERDEF_HDRFTR_VERSO User defined header/footer verso string diff --git a/contrib/groff/contrib/mom/momdoc/toc.html b/contrib/groff/contrib/mom/momdoc/toc.html index e3dccf1..cd853e8 100644 --- a/contrib/groff/contrib/mom/momdoc/toc.html +++ b/contrib/groff/contrib/mom/momdoc/toc.html @@ -115,8 +115,9 @@

  7. 5.3.2.2 SUBTITLE
  8. 5.3.2.3 AUTHOR
  9. 5.3.2.4 CHAPTER -
  10. 5.3.2.5 DRAFT -
  11. 5.3.2.6 REVISION +
  12. 5.3.2.5 CHAPTER_TITLE +
  13. 5.3.2.6 DRAFT +
  14. 5.3.2.7 REVISION
  15. 5.3.3 The Docstyle Macros " . el \{\ . nr www-depth -\w'\\*[www-level\\n[www-level]]'u -. in \\n[www-depth] +. in \\n[www-depth]u . \} . www-pop-level .. -.\" +.\" -------------------------------------------------------------------- .\" LI .\" .\" Insert a list item. @@ -492,7 +727,7 @@ . nop \\*[www-level\\n[www-level]]\c . \} .. -.\" +.\" -------------------------------------------------------------------- .\" DC l text [color] .\" .\" L is the letter to be dropped and enlarged. @@ -513,9 +748,19 @@ . el \{\ . ie r ps4html \{\ . www-make-unique-name +. \" To avoid interferences with another DC macro call which is located +. \" very near to the current one, we draw the glyph on a separate page. +. \" Otherwise it could theoretically happen that the dropped capital +. \" glyphs overlap. +. bp +. ev www-DC +. vs 80p . nop \O[5i\\*[www-unique-name].png]\O[1] -. nop \m[\\*[www-dropcolor]]\s[40]\O[3]\\$1\O[4]\s0\m[] -. nop \O[2]\O[1] +. nop \m[\\*[www-dropcolor]]\s[40]\O[3]\\$1\O[4] +. nop \O[2]\O[0] +. br +. ev +. bp . \} . el \{\ . nr dummy \w'\\$1'u @@ -527,6 +772,8 @@ . \} . nop \\$2 .. +.\" -------------------------------------------------------------------- +.\" Setup around HTML-IMAGE and friends .\" .\" now set up TS, TE, EQ, EN default macros .\" @@ -537,9 +784,10 @@ .\" .\" supplementary macros used by other macro sets .\" -.\" here are some tags specially for -Tps or -Thtml when invoked by pre-html -.\" to generate png images from postscript. -.\" +.\" here are some tags specially for -Tps or -Thtml when invoked by +.\" pre-html to generate png images from postscript. +. +.\" -------------------------------------------------------------------- .\" HTML-DO-IMAGE - tells troff to issue an image marker which can be .\" read back by pre-html .\" @@ -549,7 +797,7 @@ . if \\n[www-html] \ . nop \O[5\\$2\\$1.png]\O[0]\O[3] .. -.\" +.\" -------------------------------------------------------------------- .\" HTML-IMAGE-END - terminates an image for html .\" .de HTML-IMAGE-END @@ -561,7 +809,7 @@ . .nr www-png-no 0 . -.\" +.\" -------------------------------------------------------------------- .\" www-make-unique-name - generates another unique name in string .\" `www-unique-name' .\" @@ -569,7 +817,7 @@ . nr www-png-no +1 . ds www-unique-name \\*[www-image-template]\\n[www-png-no] .. -.\" +.\" -------------------------------------------------------------------- .\" HTML-IMAGE and friends tell grohtml that this region of text needs .\" to be rendered as an image. .\" @@ -594,11 +842,42 @@ . HTML-DO-IMAGE \\*[www-unique-name] i .. . +.\" -------------------------------------------------------------------- +.\" Final Setup +.\" -------------------------------------------------------------------- +. .if \n[www-html] \{\ . nh . nr HY 0 .\} +. +.\" +.\" start of some code +.\" +. +.de CDS +.ft C +.nf +.. +.\" +.\" end of some code +.\" +. +.de CDE +.fi +.ft P +.. +. .if r ps4html .nop \O[0] .cp \n(_C . +.\" now set +. +.\" -------------------------------------------------------------------- +.\" Emacs settings +.\" -------------------------------------------------------------------- +. +.\" Local Variables: +.\" mode: nroff +.\" End: .\" EOF -- cgit v1.1