Try to add basic decryption support to dcpdiff.
[libdcp.git] / src / subtitle_string.h
index e849bc60a5ff6b39f9a7b647f97f80b80f2a5770..0f066164e6ccbf2b8e81cd6da5636ee91bfe3fc7 100644 (file)
@@ -26,6 +26,7 @@
 
 #include "types.h"
 #include "dcp_time.h"
+#include <boost/optional.hpp>
 #include <string>
 
 namespace dcp {
@@ -37,9 +38,9 @@ class SubtitleString
 {
 public:
        SubtitleString (
-               std::string font,
+               boost::optional<std::string> font,
                bool italic,
-               Color color,
+               Colour colour,
                int size,
                Time in,
                Time out,
@@ -47,12 +48,13 @@ public:
                VAlign v_align,
                std::string text,
                Effect effect,
-               Color effect_color,
+               Colour effect_colour,
                Time fade_up_time,
                Time fade_down_time
                );
 
-       std::string font () const {
+       /** @return font ID */
+       boost::optional<std::string> font () const {
                return _font;
        }
 
@@ -60,8 +62,8 @@ public:
                return _italic;
        }
 
-       Color color () const {
-               return _color;
+       Colour colour () const {
+               return _colour;
        }
 
        Time in () const {
@@ -91,8 +93,8 @@ public:
                return _effect;
        }
 
-       Color effect_color () const {
-               return _effect_color;
+       Colour effect_colour () const {
+               return _effect_colour;
        }
 
        Time fade_up_time () const {
@@ -121,12 +123,12 @@ public:
        }
 
 private:
-       /** font name */
-       std::string _font;
+       /** font ID */
+       boost::optional<std::string> _font;
        /** true if the text is italic */
        bool _italic;
        /** text colour */
-       Color _color;
+       Colour _colour;
        /** Size in points as if the screen height is 11 inches, so a 72pt font
         *  would be 1/11th of the screen height.
         */ 
@@ -140,7 +142,7 @@ private:
        VAlign _v_align;
        std::string _text;
        Effect _effect;
-       Color _effect_color;
+       Colour _effect_colour;
        Time _fade_up_time;
        Time _fade_down_time;
 };