STLL  0.0
Simple Text Layouting Library
layouterXHTML.h
Go to the documentation of this file.
1 /*
2  * STLL Simple Text Layouting Library
3  *
4  * STLL is the legal property of its developers, whose
5  * names are listed in the COPYRIGHT file, which is included
6  * within the source distribution.
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU Lesser General Public License
10  * as published by the Free Software Foundation; either version 2.1
11  * of the License, or (at your option) any later version.
12 
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17 
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, write to the Free Software
20  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21  */
22 #ifndef STLL_LAYOUTER_XHTML_H
23 #define STLL_LAYOUTER_XHTML_H
24 
29 #include "layouterCSS.h"
30 #include "layouter.h"
31 #include "internal/xmllibraries.h"
32 
33 #include <string>
34 
35 namespace STLL {
36 
42 #ifdef USE_PUGI_XML
43 TextLayout_c layoutXML(pugi::xml_node txt, const TextStyleSheet_c & rules, const Shape_c & shape);
44 #endif
45 #ifdef USE_LIBXML2
46 TextLayout_c layoutXML(const xmlNode * txt, const TextStyleSheet_c & rules, const Shape_c & shape);
47 #endif
48 
57 #ifdef USE_PUGI_XML
58 TextLayout_c layoutXHTMLPugi(const std::string & txt, const TextStyleSheet_c & rules, const Shape_c & shape);
59 #endif
60 #ifdef USE_LIBXML2
61 TextLayout_c layoutXHTMLLibXML2(const std::string & txt, const TextStyleSheet_c & rules, const Shape_c & shape);
62 #endif
63 
64 #define layoutXHTML2(lib, txt, rules, shape) layoutXHTML##lib(txt, rules, shape)
65 #define layoutXHTML(lib, txt, rules, shape) layoutXHTML2(lib, txt, rules, shape)
66 
67 }
68 
69 #endif
TextLayout_c layoutXML(pugi::xml_node txt, const TextStyleSheet_c &rules, const Shape_c &shape)
layout the given preparsed XML tree as an HTML dom tree
Module containing CSS functionality.
The namespace for the library. Every function and class is within this namespace. ...
Definition: color.h:31
TextLayout_c layoutXHTMLLibXML2(const std::string &txt, const TextStyleSheet_c &rules, const Shape_c &shape)
the paragraph layouter and its helpers
TextLayout_c layoutXHTMLPugi(const std::string &txt, const TextStyleSheet_c &rules, const Shape_c &shape)
layout the given XHTML code