In an earlier post, I mentioned the C function void RemoveMostTagsAndExtraWhiteSpace(char* buf)
I've uploaded a prototype of LcdBible that uses the "experimental" CanonVersifier class. This class and a cut-down RawVerse are the only sword-api classes needed for a "plug-in subset" that can access verses from ./modules/texts/rawtext. The specifics can be looked at: http://prdownloads.sourceforge.net/lcdbible/LcdBible_src_0_01c.zip The above contains void RawVerse::RemoveMostTagsAndExtraWhiteSpace(char* buf) (It can be thought of as an enhanced RawVerse::PrepText) It uses 4 "states" to check if it is: * within a simple "removable tag", * within a <RF>pseudo-comment<Rf> * within a <scripRef>some references</scripRef> * actual Bible text (also strips CrLf, leading spaces, multiple spaces, tabs, other non-printing chars) It seems to work 100% for the 8 uncompressed and compressed Bible texts I've used it with. (KJV, LITV, ISV, WEB, BBE, MKJV, GodsWord, BWE), but YMMV. I haven't used it with commentaries, dictionaries, etc. my 2 alt-155, Lynn Allan From: Paul Julian Gould <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] Subject: Re: [sword-devel] Re: Some questions re: a locked module (parsing/removing embedded tags without sword-api) Reply-To: [EMAIL PROTECTED] Lynn Allan wrote: >>>Sure will make life a lot less painful, I guarantee, as I've been >>>sitting here trying to write a parsing routiine to get rid of the >>>e-Sword-specific formatting codes in that humongous 64MB Access file. >>> >>> > >As an alternative to the thorough, but not-for-the-faint-hearted parsing >that the Sword-Api is capable of, I am aware of a 77 line C routine that >seems to remove 99.44% of the non-standard tags that are embedded in rawtext >and ztext Bible modules. (Note, I haven't used it on commentaries, >dictionaries, etc.) > >void RemoveMostTagsAndExtraWhiteSpace(char* buf) > >If the author of the routine is willing to waive copyright, and you think it >might be worth looking at, I can make it available at: >http://inverse.sourceforge.net/prototypes > >my 2 alt-155 > > >_______________________________________________ >sword-devel mailing list >[EMAIL PROTECTED] >http://www.crosswire.org/mailman/listinfo/sword-devel > > > I'd love to see it... my C skills are pretty rusty, but I can read someone else's code and modify it for my uses. Sounds useful, indeed! God Bless, Paul _______________________________________________ sword-devel mailing list [EMAIL PROTECTED] http://www.crosswire.org/mailman/listinfo/sword-devel