The SWORD Project  1.9.0.svnversion
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
thmllatex.h
Go to the documentation of this file.
1 /******************************************************************************
2  *
3  * thmllatex.h - class ThMLLaTeX: a RenderFilter to render LaTeX from
4  * modules marked up in ThML
5  *
6  * $Id: thmllatex.h 3786 2020-08-30 11:35:14Z scribe $
7  *
8  * Copyright 2011-2014 CrossWire Bible Society (http://www.crosswire.org)
9  * CrossWire Bible Society
10  * P. O. Box 2528
11  * Tempe, AZ 85280-2528
12  *
13  * This program is free software; you can redistribute it and/or modify it
14  * under the terms of the GNU General Public License as published by the
15  * Free Software Foundation version 2.
16  *
17  * This program is distributed in the hope that it will be useful, but
18  * WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20  * General Public License for more details.
21  *
22  */
23 
24 #ifndef THMLLATEX_H
25 #define THMLLATEX_H
26 
27 #include <swbasicfilter.h>
28 #include <utilxml.h>
29 
31 
35 
36 private:
39 
40 protected:
42  public:
43  MyUserData(const SWModule *module, const SWKey *key);//: BasicFilterUserData(module, key) {}
45  bool inSecHead;
49  };
50 
51  virtual BasicFilterUserData *createUserData(const SWModule *module, const SWKey *key) {
52  return new MyUserData(module, key);
53  }
54 
55  virtual bool handleToken(SWBuf &buf, const char *token, BasicFilterUserData *userData);
56 
57 public:
58  ThMLLaTeX();
59  virtual const char *getImagePrefix() { return imgPrefix.c_str(); }
60  virtual void setImagePrefix(const char *newImgPrefix) { imgPrefix = newImgPrefix; }
61  virtual const char *getHeader() const;
62  void setRenderNoteNumbers(bool val = true) { renderNoteNumbers = val; }
63 };
64 
66 
67 #endif
#define SWORD_NAMESPACE_START
Definition: defs.h:39
virtual const char * getImagePrefix()
Definition: thmllatex.h:59
Definition: swbuf.h:47
#define SWDLLEXPORT
Definition: defs.h:171
virtual bool handleToken(SWBuf &buf, const char *token, BasicFilterUserData *userData)
SWText * module
Definition: osis2mod.cpp:105
Definition: utilxml.h:38
bool renderNoteNumbers
Definition: thmllatex.h:38
SWBuf imgPrefix
Definition: thmllatex.h:37
void setRenderNoteNumbers(bool val=true)
Definition: thmllatex.h:62
virtual BasicFilterUserData * createUserData(const SWModule *module, const SWKey *key)
Definition: thmllatex.h:51
virtual void setImagePrefix(const char *newImgPrefix)
Definition: thmllatex.h:60
virtual const char * getHeader() const
Definition: swfilter.h:62
#define SWORD_NAMESPACE_END
Definition: defs.h:40
Definition: swkey.h:77