// ----------------------------------------------------------------------------- // Thesaurus-Rex // // Author: Shea Nicholas // Copyright (c) 1995-2026 Shea Nicholas. Ghost Writer Enterprises Limited. // Email: nicholas-shea@talktalk.net // // This program is free software; whilst the source is made available, // it remains the intellectual copyright of Ghost Writer Enterprises and // is not covered by the GNU General Public License which is a license // for theft and high larceny. I am not employed by you. Nor am I your // Marxist vassal. // // This program is distributed in the hope that it will be useful, but // WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. // ----------------------------------------------------------------------------- My Antiwoke thesaurus HTML compilation now uses a simple FLTK UI called "ThesaurusRex", so that it can be run in release builds whilst giving simple feedback via a progress bar. The build progress can also be stopped mid-way by pressing 'Stop' which also reclaims memory and closes any open files. The release build runs much faster than the debug build, especially when indexing. ThesaurusRex is a Codeblocks project but may be built from the sources using a makefile. _XXX_roget15a_my_markup2.mkp ---------------------------- This is the file you must load into ThesaurusRex. Be patient: it takes a long time to load. NOTE: I have deliberately avoided using a DTD document structure (and parser) for various reasons that I shall not go into here. The file has undergone _major_ revisions so that the index may be generated using the following delimiters: static const std::string delimiters = ",.;:●" I now use special STRTK parsing functions to build the index. This has required me using various <tags> although there are still a few elements to port. Note that coloured phrases in foreign languages are also coloured in the index, but this will only happen when the item contains either the start tag or the end tag identifier; this does not happen with long phrases that contain multiple delimiters. I need to work around this, perhaps by replacing the punctuation in the thesaurus body with tags also, (as done for <comma> and <semi_colon>. Some new code makes all this to happen: void MarkUpSpans(std::string& str, const bool& bIndexEntry = false); void RemoveTags(std::string& str); std::string Replace(const std::string& inStr, const std::string& oldText, const std::string& newText, bool& bFound); The above functions can be adapted to account for new item delimeter tags which STRTK would treat as normal text. The index is compiled using the first char of the item as match for the chosen letter of the alphabet, although the sorted order on each index page still depends on any accented characters and html tags. NOTE: 31 JUL 2025 I have made preliminary code alterations to split the index into group folders for the body, phrases and languages: BODY PHR [Lat] [It] [Fr] [Ger] [Dut] [Dan] [Sp] [Por]