Reword again: Text -> Caption and Plain -> Text.
[dcpomatic.git] / src / lib / text_content.h
index 941184388850fcb11bd3fd67ae139b285fb1de6c..cca678ad22fb1de69a5c186f7608b5941931c4d4 100644 (file)
@@ -46,12 +46,13 @@ public:
        static int const FADE_IN;
        static int const FADE_OUT;
        static int const OUTLINE_WIDTH;
+       static int const TYPE;
 };
 
 /** @class TextContent
- *  @brief Description of how some subtitle content should be presented.
+ *  @brief Description of how some text content should be presented.
  *
- *  There are `image' subtitles (bitmaps) and `text' subtitles (plain text),
+ *  There are `bitmap' subtitles and `plain' subtitles (plain text),
  *  and not all of the settings in this class correspond to both types.
  */
 class TextContent : public ContentPart
@@ -85,6 +86,7 @@ public:
        void set_fade_out (ContentTime);
        void set_outline_width (int);
        void unset_fade_out ();
+       void set_type (TextType type);
 
        bool use () const {
                boost::mutex::scoped_lock lm (_mutex);
@@ -161,6 +163,11 @@ public:
                return _outline_width;
        }
 
+       TextType type () const {
+               boost::mutex::scoped_lock lm (_mutex);
+               return _type;
+       }
+
        static boost::shared_ptr<TextContent> from_xml (Content* parent, cxml::ConstNodePtr, int version);
 
 protected:
@@ -199,6 +206,7 @@ private:
        boost::optional<ContentTime> _fade_in;
        boost::optional<ContentTime> _fade_out;
        int _outline_width;
+       TextType _type;
 };
 
 #endif