| 1 | /* $FreeBSD: src/usr.bin/gencat/gencat.h,v 1.4 2002/03/26 12:39:08 charnier Exp $ */
|
|---|
| 2 |
|
|---|
| 3 | #ifndef GENCAT_H
|
|---|
| 4 | #define GENCAT_H
|
|---|
| 5 |
|
|---|
| 6 | /***********************************************************
|
|---|
| 7 | Copyright 1990, by Alfalfa Software Incorporated, Cambridge, Massachusetts.
|
|---|
| 8 |
|
|---|
| 9 | All Rights Reserved
|
|---|
| 10 |
|
|---|
| 11 | Permission to use, copy, modify, and distribute this software and its
|
|---|
| 12 | documentation for any purpose and without fee is hereby granted,
|
|---|
| 13 | provided that the above copyright notice appear in all copies and that
|
|---|
| 14 | both that copyright notice and this permission notice appear in
|
|---|
| 15 | supporting documentation, and that Alfalfa's name not be used in
|
|---|
| 16 | advertising or publicity pertaining to distribution of the software
|
|---|
| 17 | without specific, written prior permission.
|
|---|
| 18 |
|
|---|
| 19 | ALPHALPHA DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
|
|---|
| 20 | ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
|
|---|
| 21 | ALPHALPHA BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
|
|---|
| 22 | ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
|---|
| 23 | WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
|
|---|
| 24 | ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
|
|---|
| 25 | SOFTWARE.
|
|---|
| 26 |
|
|---|
| 27 | If you make any modifications, bugfixes or other changes to this software
|
|---|
| 28 | we'd appreciate it if you could send a copy to us so we can keep things
|
|---|
| 29 | up-to-date. Many thanks.
|
|---|
| 30 | Kee Hinckley
|
|---|
| 31 | Alfalfa Software, Inc.
|
|---|
| 32 | 267 Allston St., #3
|
|---|
| 33 | Cambridge, MA 02139 USA
|
|---|
| 34 | nazgul@alfalfa.com
|
|---|
| 35 |
|
|---|
| 36 | ******************************************************************/
|
|---|
| 37 |
|
|---|
| 38 | /*
|
|---|
| 39 | * $set n comment
|
|---|
| 40 | * My extension: If the comment begins with # treat the next string
|
|---|
| 41 | * as a constant identifier.
|
|---|
| 42 | * $delset n comment
|
|---|
| 43 | * n goes from 1 to NL_SETMAX
|
|---|
| 44 | * Deletes a set from the MC
|
|---|
| 45 | * $ comment
|
|---|
| 46 | * My extension: If comment begins with # treat the next string as
|
|---|
| 47 | * a constant identifier for the next message.
|
|---|
| 48 | * m message-text
|
|---|
| 49 | * m goes from 1 to NL_MSGMAX
|
|---|
| 50 | * If message-text is empty, and a space or tab is present, put
|
|---|
| 51 | * empty string in catalog.
|
|---|
| 52 | * If message-text is empty, delete the message.
|
|---|
| 53 | * Length of text is 0 to NL_TEXTMAX
|
|---|
| 54 | * My extension: If '#' is used instead of a number, the number
|
|---|
| 55 | * is generated automatically. A # followed by anything is an empty message.
|
|---|
| 56 | * $quote c
|
|---|
| 57 | * Optional quote character which can surround message-text to
|
|---|
| 58 | * show where spaces are.
|
|---|
| 59 | *
|
|---|
| 60 | * Escape Characters
|
|---|
| 61 | * \n (newline), \t (horiz tab), \v (vert tab), \b (backspace),
|
|---|
| 62 | * \r (carriage return), \f (formfeed), \\ (backslash), \ddd (bitpattern
|
|---|
| 63 | * in octal).
|
|---|
| 64 | * Also, \ at end of line is a continuation.
|
|---|
| 65 | *
|
|---|
| 66 | */
|
|---|
| 67 |
|
|---|
| 68 | #define MCLangC 0
|
|---|
| 69 | #define MCLangCPlusPlus 1
|
|---|
| 70 | #define MCLangANSIC 2
|
|---|
| 71 |
|
|---|
| 72 | #define MAXTOKEN 1024
|
|---|
| 73 |
|
|---|
| 74 | #define TRUE 1
|
|---|
| 75 | #define FALSE 0
|
|---|
| 76 |
|
|---|
| 77 | extern void MCAddSet(int, char *);
|
|---|
| 78 | extern void MCDelSet(int);
|
|---|
| 79 | extern void MCAddMsg(int, const char *, char *);
|
|---|
| 80 | extern void MCDelMsg(int);
|
|---|
| 81 | extern void MCParse(int);
|
|---|
| 82 | extern void MCReadCat(int);
|
|---|
| 83 | extern void MCWriteConst(int, int, int);
|
|---|
| 84 | extern void MCWriteCat(int);
|
|---|
| 85 | extern long MCGetByteOrder(void);
|
|---|
| 86 |
|
|---|
| 87 | #endif /* GENCAT_H */
|
|---|