00001 /*******************************************************/ 00002 /* "C" Language Integrated Production System */ 00003 /* */ 00004 /* CLIPS Version 6.20 01/31/02 */ 00005 /* */ 00006 /* PRETTY PRINT HEADER FILE */ 00007 /*******************************************************/ 00008 00009 /*************************************************************/ 00010 /* Purpose: Routines for processing the pretty print */ 00011 /* representation of constructs. */ 00012 /* */ 00013 /* Principal Programmer(s): */ 00014 /* Gary D. Riley */ 00015 /* */ 00016 /* Contributing Programmer(s): */ 00017 /* */ 00018 /* Revision History: */ 00019 /* */ 00020 /*************************************************************/ 00021 00022 #ifndef _H_pprint 00023 #define _H_pprint 00024 00025 #define PRETTY_PRINT_DATA 52 00026 00027 struct prettyPrintData 00028 { 00029 int PPBufferStatus; 00030 int PPBufferEnabled; 00031 int IndentationDepth; 00032 size_t PPBufferPos; 00033 size_t PPBufferMax; 00034 size_t PPBackupOnce; 00035 size_t PPBackupTwice; 00036 char *PrettyPrintBuffer; 00037 }; 00038 00039 #define PrettyPrintData(theEnv) ((struct prettyPrintData *) GetEnvironmentData(theEnv,PRETTY_PRINT_DATA)) 00040 00041 #ifdef LOCALE 00042 #undef LOCALE 00043 #endif 00044 00045 #ifdef _PPRINT_SOURCE_ 00046 #define LOCALE 00047 #else 00048 #define LOCALE extern 00049 #endif 00050 00051 LOCALE void InitializePrettyPrintData(void *); 00052 LOCALE void FlushPPBuffer(void *); 00053 LOCALE void DestroyPPBuffer(void *); 00054 LOCALE void SavePPBuffer(void *,char *); 00055 LOCALE void PPBackup(void *); 00056 LOCALE char *CopyPPBuffer(void *); 00057 LOCALE char *GetPPBuffer(void *); 00058 LOCALE void PPCRAndIndent(void *); 00059 LOCALE void IncrementIndentDepth(void *,int); 00060 LOCALE void DecrementIndentDepth(void *,int); 00061 LOCALE void SetIndentDepth(void *,int); 00062 LOCALE void SetPPBufferStatus(void *,int); 00063 LOCALE int GetPPBufferStatus(void *); 00064 LOCALE int SetPPBufferEnabled(void *,int); 00065 LOCALE int GetPPBufferEnabled(void *); 00066 00067 #endif 00068 00069 00070
1.5.6