Mercurial > hg > xemacs-beta
comparison lib-src/digest-doc.c @ 5406:061f4f90f874
Convert lib-src/ to GPLv3.
author | Mike Sperber <sperber@deinprogramm.de> |
---|---|
date | Mon, 18 Oct 2010 14:02:19 +0200 |
parents | ed624ab64583 |
children |
comparison
equal
deleted
inserted
replaced
5405:2aa9cd456ae7 | 5406:061f4f90f874 |
---|---|
1 /* Give this program DOCSTR.mm.nn as standard input | 1 /* Give this program DOC-mm.nn.oo as standard input and it outputs to |
2 and it outputs to standard output | 2 standard output a file of nroff output containing the doc strings. |
3 a file of nroff output containing the doc strings. | |
4 | 3 |
5 See also sorted-doc.c, which produces similar output | 4 Copyright (C) 1987, 1994, 2001, 2002, 2003, 2004, 2005, 2006, 2007, |
6 but in texinfo format and sorted by function/variable name. */ | 5 2008, 2009, 2010 Free Software Foundation, Inc. |
7 | 6 |
8 #ifdef HAVE_CONFIG_H | 7 This file is part of XEmacs. |
9 #include <config.h> | 8 |
10 #endif | 9 XEmacs is free software: you can redistribute it and/or modify |
10 it under the terms of the GNU General Public License as published by | |
11 the Free Software Foundation, either version 3 of the License, or | |
12 (at your option) any later version. | |
13 | |
14 XEmacs is distributed in the hope that it will be useful, | |
15 but WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 GNU General Public License for more details. | |
18 | |
19 You should have received a copy of the GNU General Public License | |
20 along with XEmacs. If not, see <http://www.gnu.org/licenses/>. | |
21 | |
22 | |
23 See also sorted-doc.c, which produces similar output | |
24 but in texinfo format and sorted by function/variable name. */ | |
25 | |
11 #include <stdio.h> | 26 #include <stdio.h> |
12 | 27 |
28 #ifdef DOS_NT | |
29 #include <fcntl.h> /* for O_BINARY */ | |
30 #include <io.h> /* for setmode */ | |
31 #endif | |
32 | |
13 int | 33 int |
14 main (int argc, char **argv) | 34 main () |
15 { | 35 { |
16 register int ch; | 36 register int ch; |
17 register int notfirst = 0; | 37 register int notfirst = 0; |
38 | |
39 #ifdef DOS_NT | |
40 /* DOC is a binary file. */ | |
41 if (!isatty (fileno (stdin))) | |
42 setmode (fileno (stdin), O_BINARY); | |
43 #endif | |
18 | 44 |
19 printf (".TL\n"); | 45 printf (".TL\n"); |
20 printf ("Command Summary for XEmacs\n"); | 46 printf ("Command Summary for XEmacs\n"); |
21 printf (".AU\nThe XEmacs Advocacy Group\n"); | 47 printf (".AU\nThe XEmacs Advocacy Group\n"); |
22 while ((ch = getchar ()) != EOF) | 48 while ((ch = getchar ()) != EOF) |