Back to index

tetex-bin  3.0
cmds.h
Go to the documentation of this file.
00001 /* cmds.h -- declarations for cmds.c.
00002    $Id: cmds.h,v 1.9 2004/11/26 00:48:35 karl Exp $
00003 
00004    Copyright (C) 1998, 1999, 2002, 2003, 2004 Free Software Foundation,
00005    Inc.
00006 
00007    This program is free software; you can redistribute it and/or modify
00008    it under the terms of the GNU General Public License as published by
00009    the Free Software Foundation; either version 2, or (at your option)
00010    any later version.
00011 
00012    This program is distributed in the hope that it will be useful,
00013    but WITHOUT ANY WARRANTY; without even the implied warranty of
00014    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015    GNU General Public License for more details.
00016 
00017    You should have received a copy of the GNU General Public License along
00018    with this program; if not, write to the Free Software Foundation, Inc.,
00019    59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
00020 
00021 #ifndef CMDS_H
00022 #define CMDS_H
00023 
00024 /* The three arguments a command can get are a flag saying whether it is
00025    before argument parsing (START) or after (END), the starting position
00026    of the arguments, and the ending position.  */
00027 typedef void COMMAND_FUNCTION (); /* So we can say COMMAND_FUNCTION *foo; */
00028 
00029 /* Each command has an associated function.  When the command is
00030    encountered in the text, the associated function is called with START
00031    as the argument.  If the function expects arguments in braces, it
00032    remembers itself on the stack.  When the corresponding close brace is
00033    encountered, the function is called with END as the argument. */
00034 #define START 0
00035 #define END 1
00036 
00037 /* Does the command expect braces?  */
00038 #define NO_BRACE_ARGS 0
00039 #define BRACE_ARGS 1
00040 #define MAYBE_BRACE_ARGS 2
00041 
00042 typedef struct
00043 {
00044   char *name;
00045   COMMAND_FUNCTION *proc;
00046   int argument_in_braces;
00047 } COMMAND;
00048 
00049 extern COMMAND command_table[];
00050 
00051 typedef struct acronym_desc
00052 {
00053   struct acronym_desc *next;
00054   char *acronym;
00055   char *description;
00056 } ACRONYM_DESC;
00057 
00058 /* Texinfo commands.  */
00059 extern void insert_self (int arg),
00060   insert_space (int arg),
00061   cm_ignore_line (void),
00062   cm_ignore_arg (int arg, int start_pos, int end_pos),
00063   cm_comment (void),
00064   cm_no_op (void);
00065 
00066 /* Document structure and meta information.  */
00067 extern void cm_setfilename (void),
00068   cm_settitle (void),
00069   cm_documentdescription (void),
00070   cm_node (void),
00071   cm_menu (void),
00072   cm_detailmenu (void),
00073   cm_dircategory (void),
00074   cm_direntry (void),
00075   cm_bye (void);
00076 
00077 /* File inclusion.  */
00078 extern void cm_include (void),
00079   cm_verbatiminclude (void);
00080 
00081 /* Cross referencing commands.  */
00082 extern void cm_anchor (int arg),
00083   cm_xref (int arg),
00084   cm_pxref (int arg),
00085   cm_ref (int arg),
00086   cm_inforef (int arg),
00087   cm_uref (int arg);
00088 
00089 /* Special insertions.  */
00090 extern void cm_LaTeX (int arg),
00091   cm_TeX (int arg),
00092   cm_bullet (int arg),
00093   cm_colon (void),
00094   cm_comma (int arg),
00095   cm_copyright (int arg),
00096   cm_dots (int arg),
00097   cm_enddots (int arg),
00098   cm_equiv (int arg),
00099   cm_error (int arg),
00100   cm_expansion (int arg),
00101   cm_image (int arg),
00102   cm_insert_copying (void),
00103   cm_minus (int arg),
00104   cm_point (int arg),
00105   cm_print (int arg),
00106   cm_punct (int arg),
00107   cm_registeredsymbol (int arg),
00108   cm_result (int arg);
00109 
00110 /* Emphasis and markup.  */
00111 extern void cm_acronym (int arg),
00112   cm_abbr (int arg),
00113   cm_b (int arg),
00114   cm_cite (int arg, int position),
00115   cm_code (int arg),
00116   cm_dfn (int arg, int position),
00117   cm_dmn (int arg),
00118   cm_email (int arg),
00119   cm_emph (int arg),
00120   cm_i (int arg),
00121   cm_kbd (int arg),
00122   cm_key (int arg),
00123   cm_math (int arg),
00124   cm_not_fixed_width (int arg, int start, int end),
00125   cm_r (int arg),
00126   cm_sansserif (int arg),
00127   cm_sc (int arg, int start_pos, int end_pos),
00128   cm_slanted (int arg),
00129   cm_strong (int arg, int start_pos, int end_pos),
00130   cm_tt (int arg),
00131   cm_indicate_url (int arg, int start, int end),
00132   cm_var (int arg, int start_pos, int end_pos),
00133   cm_verb (int arg);
00134 
00135 /* Block environments.  */
00136 extern void cm_cartouche (void),
00137   cm_group (void),
00138   cm_display (void),
00139   cm_smalldisplay (void),
00140   cm_example (void),
00141   cm_smallexample (void),
00142   cm_smalllisp (void),
00143   cm_lisp (void),
00144   cm_format (void),
00145   cm_smallformat (void),
00146   cm_quotation (void),
00147   cm_copying (void),
00148   cm_flushleft (void),
00149   cm_flushright (void),
00150   cm_verbatim (void),
00151   cm_end (void);
00152 
00153 /* Tables, lists, enumerations.  */
00154 extern void cm_table (void),
00155   cm_ftable (void),
00156   cm_vtable (void),
00157   cm_itemize (void),
00158   cm_enumerate (void),
00159   cm_multitable (void),
00160   cm_headitem (void),
00161   cm_item (void),
00162   cm_itemx (void),
00163   cm_tab (void);
00164 
00165 extern void cm_center (void),
00166   cm_exdent (void),
00167   cm_indent (void),
00168   cm_noindent (void),
00169   cm_noindent_cmd (void);
00170 
00171 /* Line and page breaks.  */
00172 extern void cm_asterisk (void),
00173   cm_sp (void),
00174   cm_page (void);
00175 
00176 /* Non breaking words.  */
00177 extern void cm_tie (int arg),
00178   cm_w (int arg);
00179 
00180 /* Title page creation.  */
00181 extern void cm_titlepage (void),
00182   cm_author (void),
00183   cm_titlepage_cmds (void),
00184   cm_titlefont (int arg),
00185   cm_today (int arg);
00186 
00187 /* Floats.  */
00188 extern void cm_float (void),
00189   cm_caption (int arg),
00190   cm_shortcaption (void),
00191   cm_listoffloats (void);
00192 
00193 /* Indices.  */
00194 extern void cm_kindex (void),
00195   cm_cindex (void),
00196   cm_findex (void),
00197   cm_pindex (void),
00198   cm_vindex (void),
00199   cm_tindex (void),
00200   cm_defindex (void),
00201   cm_defcodeindex (void),
00202   cm_synindex (void),
00203   cm_printindex (void);
00204 
00205 /* Conditionals. */
00206 extern void cm_set (void),
00207   cm_clear (void),
00208   cm_ifset (void),
00209   cm_ifclear (void),
00210   cm_ifeq (void),
00211   cm_value (int arg, int start_pos, int end_pos);
00212 
00213 #endif /* !CMDS_H */