/*->h.style */



#define CHANGEFONTSTYLE 0x1
#define CHANGEFONTNAME  0x2




extern os_error * remapvector(vector * v);
extern int        defltfont(void);
extern void       checkfont(xstylestr * d,int * changefont);


extern os_error * validfontstyle(xstylestr * s,int * fh);
extern os_error * getstylefbbox(xstylestr * s,filestr * file);
extern int        emsize(xstylestr * s);
extern int        readtrack(int track,xstylestr * s);
extern int        readtrackpc(int track,xstylestr * s);
extern int        writetrack(int ens,xstylestr * s);
extern int        writetrackpc(int ens,xstylestr * s);


extern os_error * findabsstylep(filestr * file,int n,absstylestr ** sp);
extern os_error * findabsstyle(filestr * file,int n,absstylestr * s);
extern os_error * findabsstylex(filestr * file,int n,xstylestr * s);



extern os_error * remabsstyle(filestr * file,int n);

extern os_error * addabsstyle(filestr * file,absstylestr * s1,int number);

extern os_error * dupabsstyle(filestr * file,int key);


extern os_error * findstylechainp(filestr * file,int key,int ** chainp,int *n);

extern os_error * findstylechain(filestr * file,int key,int * chain,int * n);
extern os_error * findstylechains(filestr * file,int key,int * chain,int * n);

extern os_error * remstylechain(filestr * file,int key,int number);
extern os_error * dupstylechain(filestr * file,int key);

extern os_error * addstylechain(filestr * file,int * chain,int new,
                  int * nkey,int number);

extern os_error * stylefontchange(int post,filestr * file);

extern os_error * stylefontload(filestr * file,int * load);


extern os_error * fillinstyle(absstylestr * d,filestr * file);

extern void       applystyle(xstylestr * rstyle,xstylestr * astyle);

extern os_error * styleop(xstylestr * style,int type,int scope);

extern void       stylesetall(xstylestr * style);
extern void       styleclrall(xstylestr * style);


extern void       styleclrbits(actionbits * result,actionbits * a1,actionbits * a2);


extern void       stylexorbits(actionbits * result,
                                     actionbits * a1,actionbits * a2);

extern void       styleandbits(actionbits * result,
                                     actionbits * a1,actionbits * a2);

extern void       styleorrbits(actionbits * result,
                                     actionbits * a1,actionbits * a2);

extern void       styleflipall(xstylestr * style);

extern void       styleclrxformat(xstylestr * style);


                   
extern void       stylediffbits(xstylestr * style,xstylestr * rstyle);

extern os_error * writedefltstyle(char * w,filestr * file);
extern os_error * newstylemap(filestr * file,int user);


extern void styleassignjust(xstylestr * d,xstylestr * s);
extern void styleassignbullet(xstylestr * d,xstylestr * s);
extern void styleassignhyph(xstylestr * d,xstylestr * s);
extern void styleassignuline(xstylestr * d,xstylestr * s);
extern void styleassignstrike(xstylestr * d,xstylestr * s);



extern os_error * clearchainchanges(filestr * file);
extern os_error * updatestylechains(filestr * file,int * changesp);
extern os_error * clearabschanges(filestr * file);
extern os_error * updateabsstyles(filestr * file,int * changesp,int clear);


