sectioning.h 2.9 KB

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