summaryrefslogtreecommitdiff
path: root/src/lib/text_content.h
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2018-08-22 21:04:56 +0100
committerCarl Hetherington <cth@carlh.net>2018-08-22 21:04:56 +0100
commit2571104b6a208fa00b2c98d50f97849c3e7fa6c9 (patch)
tree0e2db3a2bef44ce98066fd966c9a32be7af163f6 /src/lib/text_content.h
parentea9715cdfee4349ae9680b890032b0f9c61d5620 (diff)
Store a name with text content.
Diffstat (limited to 'src/lib/text_content.h')
-rw-r--r--src/lib/text_content.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/lib/text_content.h b/src/lib/text_content.h
index e5981acaf..0327d4a97 100644
--- a/src/lib/text_content.h
+++ b/src/lib/text_content.h
@@ -37,6 +37,7 @@ public:
static int const Y_SCALE;
static int const USE;
static int const BURN;
+ static int const NAME;
static int const LANGUAGE;
static int const FONTS;
static int const COLOUR;
@@ -73,6 +74,7 @@ public:
void set_y_offset (double);
void set_x_scale (double);
void set_y_scale (double);
+ void set_name (std::string name);
void set_language (std::string language);
void set_colour (dcp::Colour);
void unset_colour ();
@@ -123,6 +125,11 @@ public:
return _fonts;
}
+ std::string name () const {
+ boost::mutex::scoped_lock lm (_mutex);
+ return _name;
+ }
+
std::string language () const {
boost::mutex::scoped_lock lm (_mutex);
return _language;
@@ -176,6 +183,8 @@ public:
static std::list<boost::shared_ptr<TextContent> > from_xml (Content* parent, cxml::ConstNodePtr, int version);
protected:
+ /** Name (annotation text) for this subtitle */
+ std::string _name;
/** subtitle language (e.g. "German") or empty if it is not known */
std::string _language;