[BACK]Return to mdoc.h CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Diff for /mandoc/mdoc.h between version 1.44 and 1.56

version 1.44, 2009/03/09 13:17:49 version 1.56, 2009/04/12 19:45:26
Line 1 
Line 1 
 /* $Id$ */  /*      $Id$ */
 /*  /*
  * Copyright (c) 2008 Kristaps Dzonsons <kristaps@kth.se>   * Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@openbsd.org>
  *   *
  * Permission to use, copy, modify, and distribute this software for any   * Permission to use, copy, modify, and distribute this software for any
  * purpose with or without fee is hereby granted, provided that the   * purpose with or without fee is hereby granted, provided that the above
  * above copyright notice and this permission notice appear in all   * copyright notice and this permission notice appear in all copies.
  * copies.  
  *   *
  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL   * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED   * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE   * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL   * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR   * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER   * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR   * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  * PERFORMANCE OF THIS SOFTWARE.  
  */   */
 #ifndef MDOC_H  #ifndef MDOC_H
 #define MDOC_H  #define MDOC_H
Line 31 
Line 29 
   
 /* What follows is a list of ALL possible macros. */  /* What follows is a list of ALL possible macros. */
   
 /* TODO: Brq et al. */  
   
 #define MDOC___          0  #define MDOC___          0
 #define MDOC_Dd          1  #define MDOC_Dd          1
 #define MDOC_Dt          2  #define MDOC_Dt          2
Line 142 
Line 138 
 #define MDOC_Lb          106  #define MDOC_Lb          106
 #define MDOC_Ap          107  #define MDOC_Ap          107
 #define MDOC_Lp          108  #define MDOC_Lp          108
 #define MDOC_MAX         109  #define MDOC_Lk          109
   #define MDOC_Mt          110
   #define MDOC_Brq         111
   #define MDOC_Bro         112
   #define MDOC_Brc         113
   #define MDOC__C          114
   #define MDOC_Es          115
   #define MDOC_En          116
   #define MDOC_Dx          117
   #define MDOC__Q          118
   #define MDOC_MAX         119
   
 /* What follows is a list of ALL possible macro arguments. */  /* What follows is a list of ALL possible macro arguments. */
   
Line 171 
Line 177 
 #define MDOC_Words       22  #define MDOC_Words       22
 #define MDOC_Emphasis    23  #define MDOC_Emphasis    23
 #define MDOC_Symbolic    24  #define MDOC_Symbolic    24
 #define MDOC_ARG_MAX     25  #define MDOC_Nested      25
   #define MDOC_ARG_MAX     26
   
 /* Warnings are either syntax or groff-compatibility. */  /* Warnings are either syntax or groff-compatibility. */
 enum    mdoc_warn {  enum    mdoc_warn {
Line 267  struct mdoc_node {
Line 274  struct mdoc_node {
 #define MDOC_IGN_SCOPE   (1 << 0) /* Ignore scope violations. */  #define MDOC_IGN_SCOPE   (1 << 0) /* Ignore scope violations. */
 #define MDOC_IGN_ESCAPE  (1 << 1) /* Ignore bad escape sequences. */  #define MDOC_IGN_ESCAPE  (1 << 1) /* Ignore bad escape sequences. */
 #define MDOC_IGN_MACRO   (1 << 2) /* Ignore unknown macros. */  #define MDOC_IGN_MACRO   (1 << 2) /* Ignore unknown macros. */
   #define MDOC_IGN_CHARS   (1 << 3) /* Ignore disallowed chars. */
   
 /* Call-backs for parse messages. */  /* Call-backs for parse messages. */
 struct  mdoc_cb {  struct  mdoc_cb {
Line 292  void     mdoc_free(struct mdoc *);
Line 300  void     mdoc_free(struct mdoc *);
 /* Allocate a new parser instance. */  /* Allocate a new parser instance. */
 struct  mdoc     *mdoc_alloc(void *, int, const struct mdoc_cb *);  struct  mdoc     *mdoc_alloc(void *, int, const struct mdoc_cb *);
   
 /* Set parse options. */  /* Gets system ready for another parse. */
 void              mdoc_setflags(struct mdoc *, int);  int               mdoc_reset(struct mdoc *);
   
 /* Parse a single line in a stream (boolean retval). */  /* Parse a single line in a stream (boolean retval). */
 int               mdoc_parseln(struct mdoc *, int, char *buf);  int               mdoc_parseln(struct mdoc *, int, char *buf);
Line 312  int    mdoc_endparse(struct mdoc *);
Line 320  int    mdoc_endparse(struct mdoc *);
 const char       *mdoc_a2att(const char *);  const char       *mdoc_a2att(const char *);
 const char       *mdoc_a2lib(const char *);  const char       *mdoc_a2lib(const char *);
 const char       *mdoc_a2st(const char *);  const char       *mdoc_a2st(const char *);
   
 int               mdoc_isdelim(const char *);  
   
 __END_DECLS  __END_DECLS
   

Legend:
Removed from v.1.44  
changed lines
  Added in v.1.56

CVSweb