/*========================================================================*\
 |  File: strstuff.h                                   Date: 20 Sep 1997  |
 *------------------------------------------------------------------------*
 |   Some string functions, similar to those from the standard library    |
 |                  in <string.h>, but more flexible.                     |
 |   You must call str_setup() before using any of these functions !!!    |
 |                                                                        |
\*========================================================================*/

typedef unsigned char UBYTE;

/* special return values for str_cmp() and strn_cmp() */
#define STR_LONGER   256   
#define STR_SHORTER -256

/* possible values for bordermode (treatment of word delimiters): */
#define BM_FUSSY       3  /* compare char by char */
#define BM_DONTCOUNT   2  /* number (and kind) of spaces doesn't matter */
#define BM_SPACEPUNCTS 1  /* treat punctuation like spaces */
#define BM_MERGE       0  /* merge all alphanumerics into one single word */

void   str_setup    ( int bordermode, int case_sense );
int    str_cmp      ( UBYTE *s, UBYTE *t );
int    strn_cmp     ( UBYTE *s, UBYTE *t, size_t n );
UBYTE *str_str      ( UBYTE *s, UBYTE *t );
void   print_strstat( void );

