/* Copyright (c) Xerox Corporation 1993. All rights reserved. */ /* tiogatxt.ch -- Text subclass that can read Tioga files. David Nichols December, 1990 */ struct tiogatxt_Run { long looks; /* bitmap of looks */ long start; /* start position */ long len; /* length */ }; struct tiogatxt_Env { struct environment *env; /* current environment */ struct environment *env2; /* wrapped around env, maybe */ long pos; /* where to start it */ int comment; /* is this node a comment? */ }; #define tiogatxt_NUMLOOKS 26 class tiogatxt: text { overrides: SetAttributes(struct attributes *atts); Read(FILE *file, long id) returns long; Write(FILE *file, long writeID, int level) returns long; ViewName() returns char *; data: char *reader; /* saved tread_Reader */ struct tiogatxt_Run *runs; /* saved runs during reading */ int nRuns; /* number of them */ int nAllocedRuns; /* space for them */ struct tiogatxt_Env *envs; /* stacked envs during reading */ int nEnvs; /* number of them */ int nAllocedEnvs; /* space for them */ struct style *topStyle; /* special top-level style */ struct style *lookTable[tiogatxt_NUMLOOKS]; /* cached looks for reading */ };