Home | History | Annotate | Line # | Download | only in makeinfo
      1 /*	$NetBSD: sectioning.h,v 1.4 2025/12/31 22:18:50 oster Exp $	*/
      2 
      3 /* sectioning.h -- all related stuff @chapter, @section... @contents
      4    Id: sectioning.h,v 1.5 2004/04/11 17:56:47 karl Exp
      5 
      6    Copyright (C) 1999, 2003 Free Software Foundation, Inc.
      7 
      8    This program is free software; you can redistribute it and/or modify
      9    it under the terms of the GNU General Public License as published by
     10    the Free Software Foundation; either version 2, or (at your option)
     11    any later version.
     12 
     13    This program is distributed in the hope that it will be useful,
     14    but WITHOUT ANY WARRANTY; without even the implied warranty of
     15    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     16    GNU General Public License for more details.
     17 
     18    You should have received a copy of the GNU General Public License
     19    along with this program; if not, write to the Free Software
     20    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
     21 
     22    Written by Karl Heinz Marbaise <kama (at) hippo.fido.de>.  */
     23 
     24 #ifndef SECTIONING_H
     25 #define SECTIONING_H
     26 
     27 /* Sectioning.  */
     28 
     29 /* Level 4.  */
     30 extern void cm_chapter (int arg, int arg2, int arg3),
     31   cm_unnumbered (int arg, int arg2, int arg3),
     32   cm_appendix (int arg, int arg2, int arg3),
     33   cm_top (int arg, int arg2, int arg3);
     34 
     35 /* Level 3.  */
     36 extern void cm_section (int arg, int arg2, int arg3),
     37   cm_unnumberedsec (int arg, int arg2, int arg3),
     38   cm_appendixsec (int arg, int arg2, int arg3);
     39 
     40 /* Level 2.  */
     41 extern void cm_subsection (int arg, int arg2, int arg3),
     42   cm_unnumberedsubsec (int arg, int arg2, int arg3),
     43   cm_appendixsubsec (int arg, int arg2, int arg3);
     44 
     45 /* Level 1.  */
     46 extern void cm_subsubsection (int arg, int arg2, int arg3),
     47   cm_unnumberedsubsubsec (int arg, int arg2, int arg3),
     48   cm_appendixsubsubsec (int arg, int arg2, int arg3);
     49 
     50 /* Headings.  */
     51 extern void cm_heading (int arg, int arg2, int arg3),
     52   cm_chapheading (int arg, int arg2, int arg3),
     53   cm_subheading (int arg, int arg2, int arg3),
     54   cm_subsubheading (int arg, int arg2, int arg3),
     55   cm_majorheading (int arg, int arg2, int arg3);
     56 
     57 extern void cm_raisesections (int arg, int arg2, int arg3),
     58   cm_lowersections (int arg, int arg2, int arg3),
     59   cm_ideprecated (int arg, int start, int end);
     60 
     61 extern void
     62   sectioning_underscore (char *cmd),
     63   insert_and_underscore (int level, char *cmd);
     64 
     65 /* needed in node.c */
     66 extern int set_top_section_level (int level);
     67 
     68 extern void sectioning_html (int level, char *cmd);
     69 extern int what_section (char *text, char **secname);
     70 extern char *current_chapter_number (void),
     71   *current_sectioning_number (void),
     72   *current_sectioning_name (void);
     73 
     74 /* The argument of @settitle, used for HTML. */
     75 extern char *title;
     76 
     77 
     78 /* Here is a structure which associates sectioning commands with
     79    an integer that reflects the depth of the current section. */
     80 typedef struct
     81 {
     82   char *name;
     83   int level; /* I can't replace the levels with defines
     84                 because it is changed during run */
     85   int num; /* ENUM_SECT_NO means no enumeration...
     86               ENUM_SECT_YES means enumerated version
     87               ENUM_SECT_APP appendix (Character enumerated
     88                             at first position */
     89   int toc; /* TOC_NO means do not enter in toc;
     90               TOC_YES means enter it in toc */
     91 } section_alist_type;
     92 
     93 extern section_alist_type section_alist[];
     94 
     95 /* enumerate sections */
     96 #define ENUM_SECT_NO  0
     97 #define ENUM_SECT_YES 1
     98 #define ENUM_SECT_APP 2
     99 
    100 /* make entries into toc no/yes */
    101 #define TOC_NO  0
    102 #define TOC_YES 1
    103 
    104 
    105 #endif /* not SECTIONING_H */
    106