// -*- Mode: C++ -*-

#include "fuchlig.h"

char     errtxt[256];
int      entercounter= 0;
ofstream *cdebug= NULL;
int      debuglevel= 0;
preliginfo *prelig[MAXPRELIG];
int    anzprelig= 0;
preliginfo *replace[MAXREPLACE];
int    anzreplace= 0;
letter *table[MAXTABLE];
int    anztable= 0;
liginfo *lig[MAXLIG];
int    anzlig= 0;
char   *configfile= DEFCONFIGFILE;
array<const longchar *, longchar> combines(NONEXIST);
bool   vardeft= false;
int    varstart= 1;
int    varend= 0;
condition constr(NULL);
int    mindist= 6;
letter *fuchchar[MAXLONGCHAR];
FILE   *f= NULL,
       *fout= NULL;
int    extrachar= 0;
int    lx= 1, ly= 1;
int    outx= 0;
bool   nofuch= false;    // nach %!F+
char   mypath[200];
int    lline= 1;
longchar replacebuff[MAXWORDLEN],
         *prepl= replacebuff,
         *preplend= replacebuff+MAXWORDLEN-2;
longchar preligbuff[MAXWORDLEN],
         *prl= preligbuff,
         *prlend= preligbuff+MAXWORDLEN-2;
longchar hprelig[MAXWORDLEN];
longchar gluechar= NONEXIST;
longchar combinecharA= NONEXIST;
longchar combinecharZ= NONEXIST;
char     *wordbox=  "%s";
longchar *leftbox=  Longchar(5) << -1;
longchar *rightbox= Longchar(5) << -1;
longchar *bothbox=  Longchar(5) << -1;
char     *fuchon=   "\\fuch";
char     *fuchoff=  "\\nofuch";
ttranslate *translate[MAXLONGCHAR];

char fuchlettername[256];
char mainfilename[256];
char outfilename[256];

char com[MAXCOMMENT];

longchar combinebuff[MAXCOMBINE], *comb;
longchar combinecharcounter= 256;
int      combinecount= 0;
bool     empty= true;

const abst abstNULL= { 0, 0, 0, 0, 0, 0, 0 };

const longchar *dash[5]={NULL, NULL, lstrcpy(new longchar[1], "-"), NULL, NULL};

int xlo, xo, xb, xu, xlu, xU, xLU;
char     fuchpuff [MAXFUCH], *fc= fuchpuff;
longchar old;
longchar sonder;
int      oldform;
bool     show= 0;
int      maxreplace= DEFMAXREPLACE;
