*/
+/** @file src/font.h
+ * @brief Font class
+ */
+
#include "types.h"
#include "subtitle.h"
+#include <libcxml/cxml.h>
#include <boost/shared_ptr.hpp>
#include <boost/optional.hpp>
#include <list>
-namespace cxml {
- class Node;
-}
-
namespace dcp {
-
+
+/** @class Font
+ * @brief Helper class for parsing subtitle XML.
+ */
class Font
{
public:
: size (0)
{}
- Font (boost::shared_ptr<const cxml::Node> node);
+ Font (cxml::ConstNodePtr node, int tcr);
Font (std::list<boost::shared_ptr<Font> > const & font_nodes);
std::string text;
- std::string id;
+ boost::optional<std::string> id;
int size;
boost::optional<bool> italic;
- boost::optional<Color> color;
+ boost::optional<Colour> colour;
boost::optional<Effect> effect;
- boost::optional<Color> effect_color;
+ boost::optional<Colour> effect_colour;
std::list<boost::shared_ptr<Subtitle> > subtitle_nodes;
std::list<boost::shared_ptr<Font> > font_nodes;