The Battle for Wesnoth  1.19.5+dev
Classes | Namespaces | Functions | Variables
markup.hpp File Reference
#include "color.hpp"
#include "config.hpp"
#include "font/standard_colors.hpp"
#include "formatter.hpp"
#include "serialization/string_utils.hpp"
#include <string>
Include dependency graph for markup.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  markup::parse_error
 Thrown when the help system fails to parse something. More...
 

Namespaces

 markup
 

Functions

template<typename... Args>
std::string markup::tag (const std::string &tag_name, Args &&... contents)
 Returns the contents enclosed inside <tag_name> and </tag_name> More...
 
template<typename... Args>
std::string markup::tag_esc (const std::string &tag_name, Args &&... contents)
 Returns the contents enclosed inside <tag_name> and </tag_name> This version escapes single quotes and backslashes. More...
 
template<typename... Args>
std::string markup::span_color (const color_t &color, Args &&... data)
 Returns a Pango formatting string using the provided color_t object. More...
 
template<typename... Args>
std::string markup::span_color (const std::string &color, Args &&... data)
 Returns a Pango formatting string using the provided hex color string. More...
 
template<typename... Args>
std::string markup::span_size (const std::string &size, Args &&... data)
 Returns a Pango formatting string that set the font size of the enclosed data. More...
 
template<typename... Args>
std::string markup::bold (Args &&... s)
 Returns a Pango formatting string corresponding to bold formatting. More...
 
template<typename... Args>
std::string markup::italic (Args &&... s)
 Returns a Pango formatting string corresponding to italic formatting. More...
 
std::string markup::img (const std::string &src, const std::string &align, const bool floating)
 
std::string markup::make_link (const std::string &text, const std::string &dst)
 
config markup::parse_text (const std::string &text)
 Parse a xml style marked up text string. More...
 

Variables

static const std::string markup::br = "<br/>"