Add a couple of small bold tests.
authorCarl Hetherington <cth@carlh.net>
Mon, 4 Apr 2016 23:27:31 +0000 (00:27 +0100)
committerCarl Hetherington <cth@carlh.net>
Mon, 4 Apr 2016 23:27:31 +0000 (00:27 +0100)
test/data/subs1.xml
test/read_interop_subtitle_test.cc
test/write_subtitle_test.cc

index 515dd9f7b4b183cce5fb26d2a6e50f3275750037..f4a4ded810392e5563386a3a1c782976fd07cc8c 100644 (file)
     <Subtitle SpotNumber="3" TimeIn="00:00:11:094" TimeOut="00:00:13:063" FadeUpTime="1" FadeDownTime="1">
       <Text VAlign="bottom" VPosition="15.0">Once belonged to the Shah</Text>
     </Subtitle>
-    <Subtitle SpotNumber="4" TimeIn="00:00:13:104" TimeOut="00:00:15:177" FadeUpTime="1" FadeDownTime="1">
-      <Text VAlign="bottom" VPosition="15.0">And these are Roy Hattersley's jeans</Text>
-    </Subtitle>
+    <Font Weight="bold">
+      <Subtitle SpotNumber="4" TimeIn="00:00:13:104" TimeOut="00:00:15:177" FadeUpTime="1" FadeDownTime="1">
+       <Text VAlign="bottom" VPosition="15.0">And these are Roy Hattersley's jeans</Text>
+      </Subtitle>
+    </Font>
   </Font>
 </DCSubtitle>
index 7cbb5803c904a59fff390b927c5fcb45e8435e14..7822d47e9f8c015dc789829633853c68b266b6fa 100644 (file)
@@ -134,7 +134,7 @@ BOOST_AUTO_TEST_CASE (read_interop_subtitle_test1)
        BOOST_CHECK_EQUAL (s.back(), dcp::SubtitleString (
                                   string ("theFontId"),
                                   false,
-                                  false,
+                                  true,
                                   dcp::Colour (255, 255, 255),
                                   39,
                                   1.0,
index e407b81fa64e9ccfef11985a8ce57882c8af678e..67bfcd4ec87512a309ff804c1083af2e11a2ddc1 100644 (file)
@@ -60,7 +60,7 @@ BOOST_AUTO_TEST_CASE (write_subtitle_test)
                dcp::SubtitleString (
                        boost::optional<string> (),
                        true,
-                       false,
+                       true,
                        dcp::Colour (128, 0, 64),
                        91,
                        1.0,
@@ -92,7 +92,7 @@ BOOST_AUTO_TEST_CASE (write_subtitle_test)
                "      <Text VAlign=\"top\" VPosition=\"80\">Hello world</Text>\n"
                "    </Subtitle>\n"
                "  </Font>\n"
-               "  <Font Italic=\"yes\" Color=\"FF800040\" Size=\"91\" Effect=\"border\" EffectColor=\"FF010203\" Script=\"normal\" Underlined=\"no\" Weight=\"normal\">\n"
+               "  <Font Italic=\"yes\" Color=\"FF800040\" Size=\"91\" Effect=\"border\" EffectColor=\"FF010203\" Script=\"normal\" Underlined=\"no\" Weight=\"bold\">\n"
                "    <Subtitle SpotNumber=\"2\" TimeIn=\"05:41:00:218\" TimeOut=\"06:12:15:218\" FadeUpTime=\"930792\" FadeDownTime=\"4591834\">\n"
                "      <Text VAlign=\"bottom\" VPosition=\"40\">What's going on</Text>\n"
                "    </Subtitle>\n"