+SWFFONT* swf_ReadFont(char* filename)
+{
+ int f;
+ SWF swf;
+ if(!filename)
+ return 0;
+ f = open(filename,O_RDONLY);
+
+ if (f<0 || swf_ReadSWF(f,&swf)<0)
+ { fprintf(stderr,"%s is not a valid SWF font file or contains errors.\n",filename);
+ close(f);
+ return 0;
+ }
+ else
+ { SWFFONT*font;
+ close(f);
+ if(swf_FontExtract(&swf, WRITEFONTID, &font) < 0)
+ return 0;
+ swf_FreeTags(&swf);
+ return font;
+ }
+}
+
+void swf_WriteFont(SWFFONT*font, char* filename)